public final class Reference extends Object
Although this class is final so that it cannot be derived, extra implementation
data can be attached using the implData property. This is useful since
References are generally specific to some build tool and build-tool-specific
NodePlugin's such as ReferenceManagerPlugin may need to include
extra implementation data.
When implData is specified, it is used in the following way by this class:
ReferenceManagerPlugin in order to map
them to internal references that are specific to various SCM.| Constructor and Description |
|---|
Reference(ModuleVersion moduleVersion)
Constructor for a source-level reference, or when artifact-level
reference is not important.
|
Reference(ModuleVersion moduleVersion,
ArtifactGroupId artifactGroupId,
ArtifactVersion artifactVersion)
Constructor with no extra implementation data.
|
Reference(ModuleVersion moduleVersion,
ArtifactGroupId artifactGroupId,
ArtifactVersion artifactVersion,
Object implData)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(Object other) |
boolean |
equalsNoVersion(Reference referenceOther)
Tests equality between two Reference without considering the Version and
ArtifactVersion.
|
ArtifactGroupId |
getArtifactGroupId() |
ArtifactVersion |
getArtifactVersion() |
Object |
getImplData() |
ModuleVersion |
getModuleVersion() |
int |
hashCode() |
String |
toString()
Reference's are often displayed to the user and need to be shown in a human-
friendly and not too cryptic way.
|
public Reference(ModuleVersion moduleVersion, ArtifactGroupId artifactGroupId, ArtifactVersion artifactVersion, Object implData)
moduleVersion - ModuleVersion.artifactGroupId - ArtifactGroupId.artifactVersion - ArtifactVersion.implData - Extra implementation data.public Reference(ModuleVersion moduleVersion, ArtifactGroupId artifactGroupId, ArtifactVersion artifactVersion)
moduleVersion - ModuleVersion.artifactGroupId - ArtifactGroupId.artifactVersion - ArtifactVersion.public Reference(ModuleVersion moduleVersion)
moduleVersion - ModuleVersion.public ModuleVersion getModuleVersion()
public ArtifactGroupId getArtifactGroupId()
public ArtifactVersion getArtifactVersion()
public Object getImplData()
public String toString()
When Reference's are shown to the user they are generally as part of a
ReferencePath which puts the Reference's in context.
public boolean equalsNoVersion(Reference referenceOther)
referenceOther - Other Reference.Copyright © 2015–2017 AZYVA INC.. All rights reserved.