Class SubtaskInformation
- java.lang.Object
-
- com.microsoft.azure.batch.protocol.models.SubtaskInformation
-
public class SubtaskInformation extends Object
Information about an Azure Batch subtask.
-
-
Constructor Summary
Constructors Constructor Description SubtaskInformation()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description TaskContainerExecutionInformation
containerInfo()
Get this property is set only if the Task runs in a container context.org.joda.time.DateTime
endTime()
Get this property is set only if the subtask is in the Completed state.Integer
exitCode()
Get this property is set only if the subtask is in the completed state.TaskFailureInformation
failureInfo()
Get this property is set only if the Task is in the completed state and encountered a failure.Integer
id()
Get the id value.ComputeNodeInformation
nodeInfo()
Get the nodeInfo value.SubtaskState
previousState()
Get this property is not set if the subtask is in its initial running state.org.joda.time.DateTime
previousStateTransitionTime()
Get this property is not set if the subtask is in its initial running state.TaskExecutionResult
result()
Get if the value is 'failed', then the details of the failure can be found in the failureInfo property.org.joda.time.DateTime
startTime()
Get the startTime value.SubtaskState
state()
Get possible values include: 'preparing', 'running', 'completed'.org.joda.time.DateTime
stateTransitionTime()
Get the stateTransitionTime value.SubtaskInformation
withContainerInfo(TaskContainerExecutionInformation containerInfo)
Set this property is set only if the Task runs in a container context.SubtaskInformation
withEndTime(org.joda.time.DateTime endTime)
Set this property is set only if the subtask is in the Completed state.SubtaskInformation
withExitCode(Integer exitCode)
Set this property is set only if the subtask is in the completed state.SubtaskInformation
withFailureInfo(TaskFailureInformation failureInfo)
Set this property is set only if the Task is in the completed state and encountered a failure.SubtaskInformation
withId(Integer id)
Set the id value.SubtaskInformation
withNodeInfo(ComputeNodeInformation nodeInfo)
Set the nodeInfo value.SubtaskInformation
withPreviousState(SubtaskState previousState)
Set this property is not set if the subtask is in its initial running state.SubtaskInformation
withPreviousStateTransitionTime(org.joda.time.DateTime previousStateTransitionTime)
Set this property is not set if the subtask is in its initial running state.SubtaskInformation
withResult(TaskExecutionResult result)
Set if the value is 'failed', then the details of the failure can be found in the failureInfo property.SubtaskInformation
withStartTime(org.joda.time.DateTime startTime)
Set the startTime value.SubtaskInformation
withState(SubtaskState state)
Set possible values include: 'preparing', 'running', 'completed'.SubtaskInformation
withStateTransitionTime(org.joda.time.DateTime stateTransitionTime)
Set the stateTransitionTime value.
-
-
-
Method Detail
-
id
public Integer id()
Get the id value.- Returns:
- the id value
-
withId
public SubtaskInformation withId(Integer id)
Set the id value.- Parameters:
id
- the id value to set- Returns:
- the SubtaskInformation object itself.
-
nodeInfo
public ComputeNodeInformation nodeInfo()
Get the nodeInfo value.- Returns:
- the nodeInfo value
-
withNodeInfo
public SubtaskInformation withNodeInfo(ComputeNodeInformation nodeInfo)
Set the nodeInfo value.- Parameters:
nodeInfo
- the nodeInfo value to set- Returns:
- the SubtaskInformation object itself.
-
startTime
public org.joda.time.DateTime startTime()
Get the startTime value.- Returns:
- the startTime value
-
withStartTime
public SubtaskInformation withStartTime(org.joda.time.DateTime startTime)
Set the startTime value.- Parameters:
startTime
- the startTime value to set- Returns:
- the SubtaskInformation object itself.
-
endTime
public org.joda.time.DateTime endTime()
Get this property is set only if the subtask is in the Completed state.- Returns:
- the endTime value
-
withEndTime
public SubtaskInformation withEndTime(org.joda.time.DateTime endTime)
Set this property is set only if the subtask is in the Completed state.- Parameters:
endTime
- the endTime value to set- Returns:
- the SubtaskInformation object itself.
-
exitCode
public Integer exitCode()
Get this property is set only if the subtask is in the completed state. In general, the exit code for a process reflects the specific convention implemented by the application developer for that process. If you use the exit code value to make decisions in your code, be sure that you know the exit code convention used by the application process. However, if the Batch service terminates the subtask (due to timeout, or user termination via the API) you may see an operating system-defined exit code.- Returns:
- the exitCode value
-
withExitCode
public SubtaskInformation withExitCode(Integer exitCode)
Set this property is set only if the subtask is in the completed state. In general, the exit code for a process reflects the specific convention implemented by the application developer for that process. If you use the exit code value to make decisions in your code, be sure that you know the exit code convention used by the application process. However, if the Batch service terminates the subtask (due to timeout, or user termination via the API) you may see an operating system-defined exit code.- Parameters:
exitCode
- the exitCode value to set- Returns:
- the SubtaskInformation object itself.
-
containerInfo
public TaskContainerExecutionInformation containerInfo()
Get this property is set only if the Task runs in a container context.- Returns:
- the containerInfo value
-
withContainerInfo
public SubtaskInformation withContainerInfo(TaskContainerExecutionInformation containerInfo)
Set this property is set only if the Task runs in a container context.- Parameters:
containerInfo
- the containerInfo value to set- Returns:
- the SubtaskInformation object itself.
-
failureInfo
public TaskFailureInformation failureInfo()
Get this property is set only if the Task is in the completed state and encountered a failure.- Returns:
- the failureInfo value
-
withFailureInfo
public SubtaskInformation withFailureInfo(TaskFailureInformation failureInfo)
Set this property is set only if the Task is in the completed state and encountered a failure.- Parameters:
failureInfo
- the failureInfo value to set- Returns:
- the SubtaskInformation object itself.
-
state
public SubtaskState state()
Get possible values include: 'preparing', 'running', 'completed'.- Returns:
- the state value
-
withState
public SubtaskInformation withState(SubtaskState state)
Set possible values include: 'preparing', 'running', 'completed'.- Parameters:
state
- the state value to set- Returns:
- the SubtaskInformation object itself.
-
stateTransitionTime
public org.joda.time.DateTime stateTransitionTime()
Get the stateTransitionTime value.- Returns:
- the stateTransitionTime value
-
withStateTransitionTime
public SubtaskInformation withStateTransitionTime(org.joda.time.DateTime stateTransitionTime)
Set the stateTransitionTime value.- Parameters:
stateTransitionTime
- the stateTransitionTime value to set- Returns:
- the SubtaskInformation object itself.
-
previousState
public SubtaskState previousState()
Get this property is not set if the subtask is in its initial running state. Possible values include: 'preparing', 'running', 'completed'.- Returns:
- the previousState value
-
withPreviousState
public SubtaskInformation withPreviousState(SubtaskState previousState)
Set this property is not set if the subtask is in its initial running state. Possible values include: 'preparing', 'running', 'completed'.- Parameters:
previousState
- the previousState value to set- Returns:
- the SubtaskInformation object itself.
-
previousStateTransitionTime
public org.joda.time.DateTime previousStateTransitionTime()
Get this property is not set if the subtask is in its initial running state.- Returns:
- the previousStateTransitionTime value
-
withPreviousStateTransitionTime
public SubtaskInformation withPreviousStateTransitionTime(org.joda.time.DateTime previousStateTransitionTime)
Set this property is not set if the subtask is in its initial running state.- Parameters:
previousStateTransitionTime
- the previousStateTransitionTime value to set- Returns:
- the SubtaskInformation object itself.
-
result
public TaskExecutionResult result()
Get if the value is 'failed', then the details of the failure can be found in the failureInfo property. Possible values include: 'success', 'failure'.- Returns:
- the result value
-
withResult
public SubtaskInformation withResult(TaskExecutionResult result)
Set if the value is 'failed', then the details of the failure can be found in the failureInfo property. Possible values include: 'success', 'failure'.- Parameters:
result
- the result value to set- Returns:
- the SubtaskInformation object itself.
-
-