Class MockAgentType
- java.lang.Object
-
- jetbrains.buildServer.serverSide.agentTypes.AgentDescriptionBase
-
- jetbrains.buildServer.serverSide.impl.MockAgentDescription
-
- jetbrains.buildServer.serverSide.impl.MockAgentType
-
- All Implemented Interfaces:
AgentBuildHistory,AgentDescription,AgentType,MutableAgentDescription,SAgentType
public class MockAgentType extends MockAgentDescription implements SAgentType
-
-
Constructor Summary
Constructors Constructor Description MockAgentType(BuildHistoryEx buildHistory)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleancontainsAgentDescriptionData()AgentPoolgetAgentPool()intgetAgentPoolId()intgetAgentTypeId()AgentTypeKeygetAgentTypeKey()List<SFinishedBuild>getBuildHistory(User user, boolean includeCanceled)Returns the build history of this agent.AgentTypeDetailsgetDetails()AgentTypePolicygetPolicy()SBuildAgentgetRealAgent()For real agent types returns the corresponding agent or null if it does not exist anymore.voidsetAgentPoolId(int agentPoolId)voidsetAgentTypeId(int agentTypeId)voidsetName(String name)StringtoString()-
Methods inherited from class jetbrains.buildServer.serverSide.impl.MockAgentDescription
addAvailableRunnerType, addAvailableVcsPlugin, addBuildParameter, addConfigParameter, getAvailableParameters, getAvailableRunTypeIds, getAvailableRunTypes, getAvailableVcsPlugins, getCpuBenchmarkIndex, getCpuCount, getOperatingSystemName, isCaseInsensitiveEnvironment, isEphemeral, setCpuBenchmarkIndex, setCpuCount, setEphemeral, setOperatingSystemName
-
Methods inherited from class jetbrains.buildServer.serverSide.agentTypes.AgentDescriptionBase
getAvailableParameterValue, getBuildParameters, getConfigurationParameters, getDefinedParameters, isCaseInsensitiveEnvironment, updateParameters
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface jetbrains.buildServer.serverSide.AgentDescription
getAvailableParameters, getAvailableParameterValue, getAvailableRunTypeIds, getAvailableRunTypes, getAvailableVcsPlugins, getBuildParameters, getConfigurationParameters, getCpuBenchmarkIndex, getCpuCount, getDefinedParameters, getOperatingSystemName, isCaseInsensitiveEnvironment
-
Methods inherited from interface jetbrains.buildServer.serverSide.agentTypes.SAgentType
isCloud
-
-
-
-
Constructor Detail
-
MockAgentType
public MockAgentType(BuildHistoryEx buildHistory)
-
-
Method Detail
-
setName
public void setName(String name)
-
setAgentTypeId
public void setAgentTypeId(int agentTypeId)
-
getAgentTypeId
public int getAgentTypeId()
- Specified by:
getAgentTypeIdin interfaceAgentType
-
getAgentTypeKey
@NotNull public AgentTypeKey getAgentTypeKey()
- Specified by:
getAgentTypeKeyin interfaceAgentType
-
setAgentPoolId
public void setAgentPoolId(int agentPoolId)
-
getAgentPoolId
public int getAgentPoolId()
- Specified by:
getAgentPoolIdin interfaceAgentType
-
getBuildHistory
@NotNull public List<SFinishedBuild> getBuildHistory(@Nullable User user, boolean includeCanceled)
Description copied from interface:AgentBuildHistoryReturns the build history of this agent.The history can be filtered by user, as well as by cancelled builds.
- Specified by:
getBuildHistoryin interfaceAgentBuildHistory- Parameters:
user- if set the result will contain only builds byuserincludeCanceled- if set the result will include canceled builds as well- Returns:
- build history
-
getPolicy
@NotNull public AgentTypePolicy getPolicy()
-
getAgentPool
@NotNull public AgentPool getAgentPool()
- Specified by:
getAgentPoolin interfaceSAgentType
-
getRealAgent
@Nullable public SBuildAgent getRealAgent()
Description copied from interface:SAgentTypeFor real agent types returns the corresponding agent or null if it does not exist anymore. For cloud agent types returns null always.- Specified by:
getRealAgentin interfaceSAgentType- Returns:
- see above
-
containsAgentDescriptionData
public boolean containsAgentDescriptionData()
- Specified by:
containsAgentDescriptionDatain interfaceSAgentType- Returns:
- true if agent contains AgentDescription from some connected agent
-
getDetails
@NotNull public AgentTypeDetails getDetails()
- Specified by:
getDetailsin interfaceSAgentType- Returns:
- runtime details of the associated agent type
-
-