Package org.apache.ivy.plugins.latest
Interface LatestStrategy
- All Known Implementing Classes:
AbstractLatestStrategy
,ComparatorLatestStrategy
,LatestLexicographicStrategy
,LatestRevisionStrategy
,LatestTimeStrategy
,OsgiLatestStrategy
,WorkspaceLatestStrategy
public interface LatestStrategy
-
Method Summary
Modifier and TypeMethodDescriptionfindLatest
(ArtifactInfo[] infos, Date date) Finds the latest artifact among the given artifacts info.getName()
sort
(ArtifactInfo[] infos) Sorts the given artifacts info from the oldest one to the latest one.
-
Method Details
-
findLatest
Finds the latest artifact among the given artifacts info. The definition of 'latest' depends on the strategy itself. Given artifacts info are all good candidate. If the given date is not null, then found artifact should not be later than this date.- Parameters:
infos
- ArtifactInfo[]date
- Date- Returns:
- the latest artifact among the given ones.
-
sort
Sorts the given artifacts info from the oldest one to the latest one. The definition of 'latest' depends on the strategy itself. Given artifacts info are all good candidate.- Parameters:
infos
- ArtifactInfo[]- Returns:
- List<ArtifactInfo>
-
getName
String getName()
-