jetbrains.buildServer.serverSide
Interface BuildTypeTemplate

All Superinterfaces:
BuildTypeIdentity, BuildTypeOptions, BuildTypeSettings, java.lang.Comparable<BuildTypeTemplate>, CompatibleAgents, DependencySettings, InheritableUserParametersHolder, OptionSupport, ParametersSupport, ReadOnlyUserParameters, SPersistentEntity, UserParametersHolder, VcsLabelingSettings

public interface BuildTypeTemplate
extends BuildTypeIdentity, BuildTypeSettings, CompatibleAgents, java.lang.Comparable<BuildTypeTemplate>, ParametersSupport

Build configuration template. Contains settings of build configuration.

Since:
5.0

Nested Class Summary
 
Nested classes/interfaces inherited from interface jetbrains.buildServer.serverSide.vcs.VcsLabelingSettings
VcsLabelingSettings.LabelingType
 
Field Summary
 
Fields inherited from interface jetbrains.buildServer.serverSide.BuildTypeOptions
BT_ALLOW_EXTERNAL_STATUS, BT_BUILD_NUMBER_PATTERN, BT_CLEAN_BUILD, BT_EXECUTION_TIMEOUT, BT_FAIL_IF_TESTS_FAIL, BT_FAIL_ON_ANY_ERROR_MESSAGE, BT_FAIL_ON_EXIT_CODE, BT_FAIL_ON_OOME_OR_CRASH, BT_HANGING_BUILDS_DETECTION_ENABLED, BT_MAX_RUNNING_BUILDS, BT_SHOW_DEPS_CHANGES, DEFAULT_BUILD_NUMBER_PATTERN, DEFAULT_VCS_LABELING_BRANCH_FILTER, VCS_LABELING_BRANCH_FILTER
 
Fields inherited from interface jetbrains.buildServer.serverSide.vcs.VcsLabelingSettings
DEFAULT_LABEL_PATTERN
 
Method Summary
 void applyRunnersOrder(java.lang.String[] ids)
          Changes order of build runners in this template and in all of the inherited build configurations.
 boolean belongsTo(SProject project)
          Returns true if the specified project or some of its subprojects (not only direct) contains this build configuration template.
 java.lang.String getId()
          Returns the internal identifier (that is used inside the database).
 int getNumberOfUsages()
          Returns total number of this template usages (without permissions filtering)
 SProject getParentProject()
          Deprecated. use getProject()
 java.lang.String getParentProjectId()
          Deprecated. use getProjectId()
 SProject getProject()
          Returns project to which this template belongs
 java.lang.String getProjectId()
          Returns internal id of the project to which this template belongs
 java.util.Collection<SBuildType> getUsages()
          Returns collection of build configurations using this template.
 boolean isAccessibleFrom(SProject project)
          Returns true if this template is accessible from specified project, i.e.
 void moveToProject(SProject target)
          Moves this template to the specified project.
 void persist()
          Persist this template settings, should be called after settings modifications to preserve template state.
 
Methods inherited from interface jetbrains.buildServer.serverSide.BuildTypeIdentity
getConfigurationFile, getExternalId, getFullName, getInternalId, getName, remove, setExternalId, setName
 
Methods inherited from interface jetbrains.buildServer.serverSide.SPersistentEntity
getParent
 
Methods inherited from interface jetbrains.buildServer.serverSide.BuildTypeSettings
addBuildFeature, addBuildFeature, addBuildParameter, addBuildRunner, addBuildRunner, addBuildTrigger, addBuildTrigger, addConfigParameter, addRequirement, addVcsRoot, containsVcsRoot, findBuildRunnerById, findBuildRunnerByType, findRunnerParameter, findTriggerById, getArtifactDependencies, getArtifactPaths, getBuildFeatures, getBuildNumberPattern, getBuildParameter, getBuildParameters, getBuildParametersCollection, getBuildRunners, getBuildTriggersCollection, getCheckoutDirectory, getCheckoutRules, getCheckoutType, getConfigParameters, getConfigParametersCollection, getImplicitRequirements, getRequirements, getRunnerTypes, getRunTypeRequirements, getTemplate, getTemplateId, getUndefinedParameters, getVcsRootEntries, getVcsRoots, isEnabled, isTemplateBased, removeAllBuildRunners, removeBuildFeature, removeBuildParameter, removeBuildRunner, removeBuildTrigger, removeConfigParameter, removeRequirement, removeVcsRoot, replaceInValues, setArtifactDependencies, setArtifactPaths, setBuildNumberPattern, setCheckoutDirectory, setCheckoutRules, setCheckoutType, setEnabled, updateBuildFeature, updateBuildRunner, updateBuildTrigger
 
Methods inherited from interface jetbrains.buildServer.util.OptionSupport
getChangedOptions, getOption, setOption
 
Methods inherited from interface jetbrains.buildServer.serverSide.InheritableUserParametersHolder
getOwnParameters, getOwnParametersCollection, getParameters, getParametersCollection
 
Methods inherited from interface jetbrains.buildServer.serverSide.UserParametersHolder
addParameter, removeParameter
 
Methods inherited from interface jetbrains.buildServer.serverSide.dependency.DependencySettings
addDependency, getDependencies, removeDependency
 
Methods inherited from interface jetbrains.buildServer.serverSide.vcs.VcsLabelingSettings
getLabelingRoots, getLabelingType, getLabelPattern, setLabelingRoots, setLabelingType, setLabelPattern
 
Methods inherited from interface jetbrains.buildServer.serverSide.CompatibleAgents
getAgentCompatibility, getCompatibilityMap, getCompatibleAgents
 
Methods inherited from interface java.lang.Comparable
compareTo
 
Methods inherited from interface jetbrains.buildServer.serverSide.ParametersSupport
getParametersProvider, getValueResolver
 

Method Detail

getId

@NotNull
java.lang.String getId()
Returns the internal identifier (that is used inside the database).

Returns:
the internal identifier.
See Also:
BuildTypeIdentity.getExternalId()

persist

void persist()
Persist this template settings, should be called after settings modifications to preserve template state.

Specified by:
persist in interface BuildTypeIdentity
Specified by:
persist in interface BuildTypeSettings
Specified by:
persist in interface SPersistentEntity

getUsages

java.util.Collection<SBuildType> getUsages()
Returns collection of build configurations using this template.

Returns:
see above.

getNumberOfUsages

int getNumberOfUsages()
Returns total number of this template usages (without permissions filtering)

Returns:
see above

getParentProject

@NotNull
@Deprecated
SProject getParentProject()
Deprecated. use getProject()

Returns project to which this template belongs

Returns:
see above

getParentProjectId

@NotNull
@Deprecated
java.lang.String getParentProjectId()
Deprecated. use getProjectId()

Returns id of the project to which this template belongs

Returns:
see above
Since:
6.5

getProject

@NotNull
SProject getProject()
Returns project to which this template belongs

Specified by:
getProject in interface BuildTypeIdentity
Specified by:
getProject in interface BuildTypeSettings
Returns:
see above

getProjectId

@NotNull
java.lang.String getProjectId()
Returns internal id of the project to which this template belongs

Returns:
see above
Since:
6.5

moveToProject

void moveToProject(@NotNull
                   SProject target)
                   throws InvalidVcsRootScopeException,
                          TemplateBecomesInaccessibleException
Moves this template to the specified project. Note that if there are local VCS roots attached to this template, they will be shared. If sharing is impossible due to lack of access rights, AccessDeniedException will be thrown.

Parameters:
target - target project
Throws:
InvalidVcsRootScopeException - if VCS roots used by this template will not be accessible in the target project
TemplateBecomesInaccessibleException - if template is used by configurations and won't be available for them if it is moved to target project

applyRunnersOrder

void applyRunnersOrder(@NotNull
                       java.lang.String[] ids)
Changes order of build runners in this template and in all of the inherited build configurations. Note that after that persist operation invoked on the template will also persist inherited build configurations.

Specified by:
applyRunnersOrder in interface BuildTypeSettings
Parameters:
ids - runner identifiers

belongsTo

boolean belongsTo(@NotNull
                  SProject project)
Returns true if the specified project or some of its subprojects (not only direct) contains this build configuration template.

Parameters:
project - project
Returns:
see above
Since:
8.0

isAccessibleFrom

boolean isAccessibleFrom(@NotNull
                         SProject project)
Returns true if this template is accessible from specified project, i.e. it belongs to this project or to some of its parents

Parameters:
project - project to check
Returns:
see above
Since:
8.0