Class ProjectPoolAgentTypePolicy
- java.lang.Object
-
- jetbrains.buildServer.serverSide.agentTypes.ProjectPoolAgentTypePolicy
-
- All Implemented Interfaces:
AgentTypePolicy
public class ProjectPoolAgentTypePolicy extends Object implements AgentTypePolicy
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(Object o)Set<String>getAllowedBuildTypes()Selected build types.Set<String>getAllowedProjects()Allowed projects.intgetPolicyKind()Kind of the policy.inthashCode()booleanisAllowedToRun(String projectId, String buildTypeId)Checks whether the specified build configuration is allowed to run on this agent.booleanisBuildTypeAllowed(String buildTypeId)Checks whether the specified build configuration is selected by this policy (this method does not consider pool associations).StringtoString()
-
-
-
Method Detail
-
getPolicyKind
public int getPolicyKind()
Kind of the policy. SeeSimpleAgentTypePolicy- Specified by:
getPolicyKindin interfaceAgentTypePolicy- Returns:
- 1 - run all configurations from associated (by pool) projects, 2 - run selected only (but from associated projects).
-
getAllowedProjects
@NotNull public Set<String> getAllowedProjects()
Allowed projects.- Specified by:
getAllowedProjectsin interfaceAgentTypePolicy- Returns:
- an immutable set of project identifiers; may be ampty.
-
getAllowedBuildTypes
@NotNull public Set<String> getAllowedBuildTypes()
Selected build types.- Specified by:
getAllowedBuildTypesin interfaceAgentTypePolicy- Returns:
- an immutable set of build type identifiers; may be ampty.
-
isBuildTypeAllowed
public boolean isBuildTypeAllowed(@NotNull String buildTypeId)Checks whether the specified build configuration is selected by this policy (this method does not consider pool associations).- Specified by:
isBuildTypeAllowedin interfaceAgentTypePolicy- Returns:
- see above
-
isAllowedToRun
public boolean isAllowedToRun(@NotNull String projectId, @NotNull String buildTypeId)Checks whether the specified build configuration is allowed to run on this agent.- Specified by:
isAllowedToRunin interfaceAgentTypePolicy- Parameters:
projectId-buildTypeId- build configuration to check.- Returns:
- true if allowed.
-
-