Class ResolveOptions

java.lang.Object
org.apache.ivy.core.LogOptions
org.apache.ivy.core.resolve.ResolveOptions

public class ResolveOptions extends LogOptions
A set of options used during resolve related tasks
See Also:
  • Field Details

    • RESOLVEMODE_DEFAULT

      public static final String RESOLVEMODE_DEFAULT
      Default resolve mode, using default revision constraints in dependency descriptors.
      See Also:
    • RESOLVEMODE_DYNAMIC

      public static final String RESOLVEMODE_DYNAMIC
      Dynamic resolve mode, using dynamic revision constraints in dependency descriptors.
      See Also:
    • RESOLVEMODES

      public static final String[] RESOLVEMODES
      Array of all available resolve modes.
    • confs

      private String[] confs
      an array of configuration names to resolve - must not be null nor empty
    • revision

      private String revision
      the revision of the module for which dependencies should be resolved. This revision is considered as the resolved revision of the module, unless it is null. If it is null, then a default revision is given if necessary (no revision found in ivy file)
    • date

      private Date date
      the date for which the dependencies should be resolved. All obtained artifacts should have a publication date which is before or equal to the given date. The date can be null, in which case all artifacts will be considered
    • validate

      private boolean validate
      True if validation of module descriptors should done, false otherwise
    • useCacheOnly

      private boolean useCacheOnly
      True if only the cache should be used for resolve, false if a real resolve with dependency resolvers should be done
    • transitive

      private boolean transitive
      True if the dependencies should be resolved transitively, false if only direct dependencies should be resolved
    • download

      private boolean download
      True if the resolve should also download artifacts, false if only dependency resolution with module descriptors should be done
    • outputReport

      private boolean outputReport
      True if a report of the resolve process should be output at the end of the process, false otherwise
    • artifactFilter

      private Filter<Artifact> artifactFilter
      A filter to use to avoid downloading all artifacts.
    • resolveMode

      private String resolveMode
      The resolve mode to use. Should be one of RESOLVEMODES, or null to use settings configured resolve mode.
    • resolveId

      private String resolveId
      The id used to store the resolve information.
    • refresh

      private boolean refresh
    • checkIfChanged

      private boolean checkIfChanged
      True if the resolve should compare the new resolution against the previous report
  • Constructor Details

    • ResolveOptions

      public ResolveOptions()
    • ResolveOptions

      public ResolveOptions(ResolveOptions options)
  • Method Details

    • getArtifactFilter

      public Filter<Artifact> getArtifactFilter()
    • setArtifactFilter

      public ResolveOptions setArtifactFilter(Filter<Artifact> artifactFilter)
    • getResolveMode

      public String getResolveMode()
      Returns the resolve mode to use, or null to use settings configured resolve mode.
      Returns:
      the resolve mode to use.
    • setResolveMode

      public ResolveOptions setResolveMode(String resolveMode)
    • useSpecialConfs

      public boolean useSpecialConfs()
      Indicates if the configurations use a special configuration * , *(private) or *(public). When special configurations are used, you must have the module descriptor in order to get the list of configurations.
      Returns:
      boolean
      See Also:
    • getConfs

      public String[] getConfs()
      Returns:
      String[]
      See Also:
    • getConfs

      public String[] getConfs(ModuleDescriptor md)
      Get the asked confs. Special confs (like *) use the moduleDescriptor to find the values
      Parameters:
      md - Used to get the exact values for special confs.
      Returns:
      String[]
    • setConfs

      public ResolveOptions setConfs(String[] confs)
    • getDate

      public Date getDate()
    • setDate

      public ResolveOptions setDate(Date date)
    • isDownload

      public boolean isDownload()
    • setDownload

      public ResolveOptions setDownload(boolean download)
    • isOutputReport

      public boolean isOutputReport()
    • setOutputReport

      public ResolveOptions setOutputReport(boolean outputReport)
    • isTransitive

      public boolean isTransitive()
    • setTransitive

      public ResolveOptions setTransitive(boolean transitive)
    • isUseCacheOnly

      public boolean isUseCacheOnly()
    • setUseCacheOnly

      public ResolveOptions setUseCacheOnly(boolean useCacheOnly)
    • isValidate

      public boolean isValidate()
    • setValidate

      public ResolveOptions setValidate(boolean validate)
    • getRevision

      public String getRevision()
    • setRevision

      public ResolveOptions setRevision(String revision)
    • getResolveId

      public String getResolveId()
    • setResolveId

      public ResolveOptions setResolveId(String resolveId)
    • setRefresh

      public ResolveOptions setRefresh(boolean refresh)
    • isRefresh

      public boolean isRefresh()
    • setCheckIfChanged

      public ResolveOptions setCheckIfChanged(boolean checkIfChanged)
    • getCheckIfChanged

      public boolean getCheckIfChanged()
    • getDefaultResolveId

      public static String getDefaultResolveId(ModuleDescriptor md)
    • getDefaultResolveId

      public static String getDefaultResolveId(ModuleId moduleId)