jetbrains.buildServer.artifacts
Class BaseArtifactDependency

java.lang.Object
  extended by jetbrains.buildServer.artifacts.BaseArtifactDependency
All Implemented Interfaces:
ArtifactDependency
Direct Known Subclasses:
ArtifactDependencyInfo

public abstract class BaseArtifactDependency
extends java.lang.Object
implements ArtifactDependency

Base class for artifact dependency information.


Constructor Summary
protected BaseArtifactDependency(java.lang.String sourcePaths, RevisionRule revisionRule)
          Represents dependency on one or more artifacts of some build.
 
Method Summary
 boolean equals(java.lang.Object o)
           
 java.util.List<java.lang.String> getReferences()
          Returns references used in this dependency (in destination path, source paths or in the build number)
 RevisionRule getRevisionRule()
          Returns revision rule for downloaded artifacts.
abstract  java.lang.String getSourceBuildTypeId()
          Returns internal id of build configuration this artifact belongs to
abstract  java.lang.String getSourceExternalId()
          Returns external id of source build configuration
 java.lang.String getSourcePaths()
          Returns path to this artifact in the build of the source build configuration
 int hashCode()
           
 boolean isCleanDestinationFolder()
          Returns true if destination directory should be cleaned before artifacts downloaded
 void replaceReferences(ValueResolver resolver)
          Replaces references in this artifact dependency using the provided resolver
 void setCleanDestinationFolder(boolean cleanDestinationFolder)
          Set to true if destination directory should be cleaned before artifacts processing
 void setRevisionRule(RevisionRule revisionRule)
          Sets new revision rule to this artifact dependency
abstract  void setSourceBuildTypeId(java.lang.String sourceBuildTypeInternalId)
          Sets new source build configuration id
 void setSourcePaths(java.lang.String paths)
          Sets new source paths to this artifact dependency
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface jetbrains.buildServer.artifacts.ArtifactDependency
getSourceName
 

Constructor Detail

BaseArtifactDependency

protected BaseArtifactDependency(@NotNull
                                 java.lang.String sourcePaths,
                                 @NotNull
                                 RevisionRule revisionRule)
Represents dependency on one or more artifacts of some build.

Parameters:
sourceInternalId - build configuration where artifacts reside
sourcePaths - paths to artifacts in source build configuration
revisionRule - rule by which to select build with artifacts
Method Detail

setCleanDestinationFolder

public void setCleanDestinationFolder(boolean cleanDestinationFolder)
Set to true if destination directory should be cleaned before artifacts processing

Specified by:
setCleanDestinationFolder in interface ArtifactDependency
Parameters:
cleanDestinationFolder - true to clean destination directory

getSourceBuildTypeId

@NotNull
public abstract java.lang.String getSourceBuildTypeId()
Returns internal id of build configuration this artifact belongs to

Specified by:
getSourceBuildTypeId in interface ArtifactDependency
Returns:
internal id of build configuration containing this artifact

getSourceExternalId

@NotNull
public abstract java.lang.String getSourceExternalId()
Description copied from interface: ArtifactDependency
Returns external id of source build configuration

Specified by:
getSourceExternalId in interface ArtifactDependency
Returns:
build configuration external id

getSourcePaths

public java.lang.String getSourcePaths()
Returns path to this artifact in the build of the source build configuration

Specified by:
getSourcePaths in interface ArtifactDependency
Returns:
artifacts source paths.

isCleanDestinationFolder

public boolean isCleanDestinationFolder()
Returns true if destination directory should be cleaned before artifacts downloaded

Specified by:
isCleanDestinationFolder in interface ArtifactDependency
Returns:
if destination directory should be cleaned before artifacts downloaded.

getRevisionRule

public RevisionRule getRevisionRule()
Description copied from interface: ArtifactDependency
Returns revision rule for downloaded artifacts. Revision rule identifies build from which artifacts should be downloaded.

Specified by:
getRevisionRule in interface ArtifactDependency
Returns:
revision rule

toString

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

setSourceBuildTypeId

public abstract void setSourceBuildTypeId(@NotNull
                                          java.lang.String sourceBuildTypeInternalId)
Sets new source build configuration id

Specified by:
setSourceBuildTypeId in interface ArtifactDependency
Parameters:
sourceBuildTypeInternalId - new source build configuration id

setRevisionRule

public void setRevisionRule(@NotNull
                            RevisionRule revisionRule)
Sets new revision rule to this artifact dependency

Specified by:
setRevisionRule in interface ArtifactDependency
Parameters:
revisionRule - new revision rule

setSourcePaths

public void setSourcePaths(@NotNull
                           java.lang.String paths)
Description copied from interface: ArtifactDependency
Sets new source paths to this artifact dependency

Specified by:
setSourcePaths in interface ArtifactDependency
Parameters:
paths - paths

replaceReferences

public void replaceReferences(@NotNull
                              ValueResolver resolver)
Description copied from interface: ArtifactDependency
Replaces references in this artifact dependency using the provided resolver

Specified by:
replaceReferences in interface ArtifactDependency
Parameters:
resolver - replacement map

getReferences

public java.util.List<java.lang.String> getReferences()
Description copied from interface: ArtifactDependency
Returns references used in this dependency (in destination path, source paths or in the build number)

Specified by:
getReferences in interface ArtifactDependency
Returns:
see above

equals

public boolean equals(java.lang.Object o)
Overrides:
equals in class java.lang.Object

hashCode

public int hashCode()
Overrides:
hashCode in class java.lang.Object