Class Dependency

  • All Implemented Interfaces:
    java.io.Serializable, java.lang.Cloneable

    public class Dependency
    extends java.lang.Object
    implements java.io.Serializable, java.lang.Cloneable
    Description of dependency artifact.
    Version:
    $Revision$ $Date$
    See Also:
    Serialized Form
    • Field Summary

      Fields 
      Modifier and Type Field Description
      private java.lang.String artifactId
      Artifact ID of the dependency artifact.
      private java.lang.String classifier
      Classifier of the dependency artifact.
      private java.util.List<DependencyExclusion> exclusions
      Field exclusions.
      private java.lang.String extension
      Extension of the dependency artifact.
      private java.lang.String groupId
      Group ID of the dependency artifact.
      private java.lang.String namespace
      A namespace within which this artifact is stored.
      private java.lang.Boolean optional
      Specifies whether given dependency is optional or not.
      private java.lang.String requestedVersion
      Version of the dependency artifact as defined in the main artifact descriptor.
      private java.lang.String resolvedVersion
      Version of the dependency artifact, as resolved during build.
    • Constructor Summary

      Constructors 
      Constructor Description
      Dependency()  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void addExclusion​(DependencyExclusion dependencyExclusion)
      Method addExclusion.
      Dependency clone()
      Method clone.
      java.lang.String getArtifactId()
      Get artifact ID of the dependency artifact.
      java.lang.String getClassifier()
      Get classifier of the dependency artifact.
      java.util.List<DependencyExclusion> getExclusions()
      Method getExclusions.
      java.lang.String getExtension()
      Get extension of the dependency artifact.
      java.lang.String getGroupId()
      Get group ID of the dependency artifact.
      java.lang.String getNamespace()
      Get a namespace within which this artifact is stored.
      java.lang.String getRequestedVersion()
      Get version of the dependency artifact as defined in the main artifact descriptor.
      java.lang.String getResolvedVersion()
      Get version of the dependency artifact, as resolved during build.
      java.lang.Boolean isOptional()
      Get specifies whether given dependency is optional or not.
      void removeExclusion​(DependencyExclusion dependencyExclusion)
      Method removeExclusion.
      void setArtifactId​(java.lang.String artifactId)
      Set artifact ID of the dependency artifact.
      void setClassifier​(java.lang.String classifier)
      Set classifier of the dependency artifact.
      void setExclusions​(java.util.List<DependencyExclusion> exclusions)
      Set list of dependency exclusions.
      void setExtension​(java.lang.String extension)
      Set extension of the dependency artifact.
      void setGroupId​(java.lang.String groupId)
      Set group ID of the dependency artifact.
      void setNamespace​(java.lang.String namespace)
      Set a namespace within which this artifact is stored.
      void setOptional​(java.lang.Boolean optional)
      Set specifies whether given dependency is optional or not.
      void setRequestedVersion​(java.lang.String requestedVersion)
      Set version of the dependency artifact as defined in the main artifact descriptor.
      void setResolvedVersion​(java.lang.String resolvedVersion)
      Set version of the dependency artifact, as resolved during build.
      Artifact toArtifact()  
      java.lang.String toString()  
      • Methods inherited from class java.lang.Object

        equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Field Detail

      • groupId

        private java.lang.String groupId
        Group ID of the dependency artifact.
      • artifactId

        private java.lang.String artifactId
        Artifact ID of the dependency artifact.
      • extension

        private java.lang.String extension
        Extension of the dependency artifact.
      • classifier

        private java.lang.String classifier
        Classifier of the dependency artifact.
      • requestedVersion

        private java.lang.String requestedVersion
        Version of the dependency artifact as defined in the main artifact descriptor. This may be a version range as supported by Maven.
      • resolvedVersion

        private java.lang.String resolvedVersion
        Version of the dependency artifact, as resolved during build. Absence of this field indicates a dependency on default artifact version.
      • namespace

        private java.lang.String namespace
        A namespace within which this artifact is stored. This usually is an identifier of software collection.
      • optional

        private java.lang.Boolean optional
        Specifies whether given dependency is optional or not.
    • Constructor Detail

      • Dependency

        public Dependency()
    • Method Detail

      • addExclusion

        public void addExclusion​(DependencyExclusion dependencyExclusion)
        Method addExclusion.
        Parameters:
        dependencyExclusion -
      • clone

        public Dependency clone()
        Method clone.
        Overrides:
        clone in class java.lang.Object
        Returns:
        Dependency
      • getArtifactId

        public java.lang.String getArtifactId()
        Get artifact ID of the dependency artifact.
        Returns:
        String
      • getClassifier

        public java.lang.String getClassifier()
        Get classifier of the dependency artifact.
        Returns:
        String
      • getExclusions

        public java.util.List<DependencyExclusion> getExclusions()
        Method getExclusions.
        Returns:
        List
      • getExtension

        public java.lang.String getExtension()
        Get extension of the dependency artifact.
        Returns:
        String
      • getGroupId

        public java.lang.String getGroupId()
        Get group ID of the dependency artifact.
        Returns:
        String
      • getNamespace

        public java.lang.String getNamespace()
        Get a namespace within which this artifact is stored. This usually is an identifier of software collection.
        Returns:
        String
      • getRequestedVersion

        public java.lang.String getRequestedVersion()
        Get version of the dependency artifact as defined in the main artifact descriptor. This may be a version range as supported by Maven.
        Returns:
        String
      • getResolvedVersion

        public java.lang.String getResolvedVersion()
        Get version of the dependency artifact, as resolved during build. Absence of this field indicates a dependency on default artifact version.
        Returns:
        String
      • isOptional

        public java.lang.Boolean isOptional()
        Get specifies whether given dependency is optional or not.
        Returns:
        Boolean
      • removeExclusion

        public void removeExclusion​(DependencyExclusion dependencyExclusion)
        Method removeExclusion.
        Parameters:
        dependencyExclusion -
      • setArtifactId

        public void setArtifactId​(java.lang.String artifactId)
        Set artifact ID of the dependency artifact.
        Parameters:
        artifactId -
      • setClassifier

        public void setClassifier​(java.lang.String classifier)
        Set classifier of the dependency artifact.
        Parameters:
        classifier -
      • setExclusions

        public void setExclusions​(java.util.List<DependencyExclusion> exclusions)
        Set list of dependency exclusions.
        Parameters:
        exclusions -
      • setExtension

        public void setExtension​(java.lang.String extension)
        Set extension of the dependency artifact.
        Parameters:
        extension -
      • setGroupId

        public void setGroupId​(java.lang.String groupId)
        Set group ID of the dependency artifact.
        Parameters:
        groupId -
      • setNamespace

        public void setNamespace​(java.lang.String namespace)
        Set a namespace within which this artifact is stored. This usually is an identifier of software collection.
        Parameters:
        namespace -
      • setOptional

        public void setOptional​(java.lang.Boolean optional)
        Set specifies whether given dependency is optional or not.
        Parameters:
        optional -
      • setRequestedVersion

        public void setRequestedVersion​(java.lang.String requestedVersion)
        Set version of the dependency artifact as defined in the main artifact descriptor. This may be a version range as supported by Maven.
        Parameters:
        requestedVersion -
      • setResolvedVersion

        public void setResolvedVersion​(java.lang.String resolvedVersion)
        Set version of the dependency artifact, as resolved during build. Absence of this field indicates a dependency on default artifact version.
        Parameters:
        resolvedVersion -
      • toArtifact

        public Artifact toArtifact()
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object