Class AbstractLatestStrategy

java.lang.Object
org.apache.ivy.plugins.latest.AbstractLatestStrategy
All Implemented Interfaces:
LatestStrategy
Direct Known Subclasses:
ComparatorLatestStrategy, WorkspaceLatestStrategy

public abstract class AbstractLatestStrategy extends Object implements LatestStrategy
  • Constructor Details

    • AbstractLatestStrategy

      public AbstractLatestStrategy()
  • Method Details

    • getName

      public String getName()
      Specified by:
      getName in interface LatestStrategy
    • setName

      public void setName(String name)
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • findLatest

      public ArtifactInfo findLatest(ArtifactInfo[] infos, Date date)
      Description copied from interface: LatestStrategy
      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.
      Specified by:
      findLatest in interface LatestStrategy
      Parameters:
      infos - ArtifactInfo[]
      date - Date
      Returns:
      the latest artifact among the given ones.