Class DeploymentInstance
- java.lang.Object
-
- jetbrains.buildServer.serverSide.deploymentDashboards.entities.DeploymentInstance
-
public class DeploymentInstance extends Object
-
-
Constructor Summary
Constructors Constructor Description DeploymentInstance(String id, DeploymentHistory deploymentHistory, Map<String,String> attributes, String dashboardId)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addAttribute(String key, String value)
Adds information about attribute `key` with value `value`.void
addNewState(DeploymentStateEntry deploymentStateEntry)
Adds information about new deployment state `deploymentStateEntry`.void
addNewState(DeploymentState newState, Date statusChangedAt, Long buildId)
Adds information about new state `newState`, reported at `statusChangedAt`, with optional `buildId` to be associated with the state.Map<String,String>
getAttributes()
Return a map of attribute names and values for this instance.Long
getBuildId()
Returns build ID associated with current (latest) state of this instance, if present, otherwise returns `null`.DeploymentState
getCurrentState()
Return current (the latest reported) state of this instance.Date
getCurrentStateChangeDate()
Return the change date of current (the latest reported) state of this instance.String
getDashboardId()
String
getId()
Return unique identifier of this instance.List<DeploymentStateEntry>
getKnownStates()
Returns a list of all known states of this instance.
-
-
-
Method Detail
-
getId
@NotNull public String getId()
Return unique identifier of this instance.
-
getCurrentStateChangeDate
public Date getCurrentStateChangeDate()
Return the change date of current (the latest reported) state of this instance. If no state was reported for some reason, returns current timestamp.
-
getCurrentState
public DeploymentState getCurrentState()
Return current (the latest reported) state of this instance. If no state was reported for some reason, returns `DeploymentState.UNKNOWN` state.
-
getAttributes
public Map<String,String> getAttributes()
Return a map of attribute names and values for this instance.
-
getBuildId
@Nullable public Long getBuildId()
Returns build ID associated with current (latest) state of this instance, if present, otherwise returns `null`.
-
getKnownStates
public List<DeploymentStateEntry> getKnownStates()
Returns a list of all known states of this instance.
-
addNewState
public void addNewState(DeploymentState newState, Date statusChangedAt, @Nullable Long buildId)
Adds information about new state `newState`, reported at `statusChangedAt`, with optional `buildId` to be associated with the state.
-
addNewState
public void addNewState(DeploymentStateEntry deploymentStateEntry)
Adds information about new deployment state `deploymentStateEntry`.
-
addAttribute
public void addAttribute(String key, String value)
Adds information about attribute `key` with value `value`.
-
getDashboardId
@NotNull public String getDashboardId()
-
-