public class Command
extends java.lang.Object
implements java.io.Serializable, java.lang.Cloneable
Describes a command request.
Modifier and Type | Field and Description |
---|---|
private java.lang.String |
commandId
A unique identifier for this command.
|
private java.lang.String |
comment
User-specified information about the command, such as a brief description
of what the command should do.
|
private java.lang.String |
documentName
The name of the SSM document requested for execution.
|
private java.util.Date |
expiresAfter
If this time is reached and the command has not already started
executing, it will not execute.
|
private SdkInternalList<java.lang.String> |
instanceIds
The instance IDs against which this command was requested.
|
private java.lang.String |
outputS3BucketName
The S3 bucket where the responses to the command executions should be
stored.
|
private java.lang.String |
outputS3KeyPrefix
The S3 directory path inside the bucket where the responses to the
command executions should be stored.
|
private java.util.Map<java.lang.String,java.util.List<java.lang.String>> |
parameters
The parameter values to be inserted in the SSM document when executing
the command.
|
private java.util.Date |
requestedDateTime
The date and time the command was requested.
|
private java.lang.String |
status
The status of the command.
|
Constructor and Description |
---|
Command() |
Modifier and Type | Method and Description |
---|---|
Command |
addParametersEntry(java.lang.String key,
java.util.List<java.lang.String> value) |
Command |
clearParametersEntries()
Removes all the entries added into Parameters.
|
Command |
clone() |
boolean |
equals(java.lang.Object obj) |
java.lang.String |
getCommandId()
A unique identifier for this command.
|
java.lang.String |
getComment()
User-specified information about the command, such as a brief description
of what the command should do.
|
java.lang.String |
getDocumentName()
The name of the SSM document requested for execution.
|
java.util.Date |
getExpiresAfter()
If this time is reached and the command has not already started
executing, it will not execute.
|
java.util.List<java.lang.String> |
getInstanceIds()
The instance IDs against which this command was requested.
|
java.lang.String |
getOutputS3BucketName()
The S3 bucket where the responses to the command executions should be
stored.
|
java.lang.String |
getOutputS3KeyPrefix()
The S3 directory path inside the bucket where the responses to the
command executions should be stored.
|
java.util.Map<java.lang.String,java.util.List<java.lang.String>> |
getParameters()
The parameter values to be inserted in the SSM document when executing
the command.
|
java.util.Date |
getRequestedDateTime()
The date and time the command was requested.
|
java.lang.String |
getStatus()
The status of the command.
|
int |
hashCode() |
void |
setCommandId(java.lang.String commandId)
A unique identifier for this command.
|
void |
setComment(java.lang.String comment)
User-specified information about the command, such as a brief description
of what the command should do.
|
void |
setDocumentName(java.lang.String documentName)
The name of the SSM document requested for execution.
|
void |
setExpiresAfter(java.util.Date expiresAfter)
If this time is reached and the command has not already started
executing, it will not execute.
|
void |
setInstanceIds(java.util.Collection<java.lang.String> instanceIds)
The instance IDs against which this command was requested.
|
void |
setOutputS3BucketName(java.lang.String outputS3BucketName)
The S3 bucket where the responses to the command executions should be
stored.
|
void |
setOutputS3KeyPrefix(java.lang.String outputS3KeyPrefix)
The S3 directory path inside the bucket where the responses to the
command executions should be stored.
|
void |
setParameters(java.util.Map<java.lang.String,java.util.List<java.lang.String>> parameters)
The parameter values to be inserted in the SSM document when executing
the command.
|
void |
setRequestedDateTime(java.util.Date requestedDateTime)
The date and time the command was requested.
|
void |
setStatus(CommandStatus status)
The status of the command.
|
void |
setStatus(java.lang.String status)
The status of the command.
|
java.lang.String |
toString()
Returns a string representation of this object; useful for testing and
debugging.
|
Command |
withCommandId(java.lang.String commandId)
A unique identifier for this command.
|
Command |
withComment(java.lang.String comment)
User-specified information about the command, such as a brief description
of what the command should do.
|
Command |
withDocumentName(java.lang.String documentName)
The name of the SSM document requested for execution.
|
Command |
withExpiresAfter(java.util.Date expiresAfter)
If this time is reached and the command has not already started
executing, it will not execute.
|
Command |
withInstanceIds(java.util.Collection<java.lang.String> instanceIds)
The instance IDs against which this command was requested.
|
Command |
withInstanceIds(java.lang.String... instanceIds)
The instance IDs against which this command was requested.
|
Command |
withOutputS3BucketName(java.lang.String outputS3BucketName)
The S3 bucket where the responses to the command executions should be
stored.
|
Command |
withOutputS3KeyPrefix(java.lang.String outputS3KeyPrefix)
The S3 directory path inside the bucket where the responses to the
command executions should be stored.
|
Command |
withParameters(java.util.Map<java.lang.String,java.util.List<java.lang.String>> parameters)
The parameter values to be inserted in the SSM document when executing
the command.
|
Command |
withRequestedDateTime(java.util.Date requestedDateTime)
The date and time the command was requested.
|
Command |
withStatus(CommandStatus status)
The status of the command.
|
Command |
withStatus(java.lang.String status)
The status of the command.
|
private java.lang.String commandId
A unique identifier for this command.
private java.lang.String documentName
The name of the SSM document requested for execution.
private java.lang.String comment
User-specified information about the command, such as a brief description of what the command should do.
private java.util.Date expiresAfter
If this time is reached and the command has not already started executing, it will not execute. Calculated based on the ExpiresAfter user input provided as part of the SendCommand API.
private java.util.Map<java.lang.String,java.util.List<java.lang.String>> parameters
The parameter values to be inserted in the SSM document when executing the command.
private SdkInternalList<java.lang.String> instanceIds
The instance IDs against which this command was requested.
private java.util.Date requestedDateTime
The date and time the command was requested.
private java.lang.String status
The status of the command.
private java.lang.String outputS3BucketName
The S3 bucket where the responses to the command executions should be stored. This was requested when issuing the command.
private java.lang.String outputS3KeyPrefix
The S3 directory path inside the bucket where the responses to the command executions should be stored. This was requested when issuing the command.
public void setCommandId(java.lang.String commandId)
A unique identifier for this command.
commandId
- A unique identifier for this command.public java.lang.String getCommandId()
A unique identifier for this command.
public Command withCommandId(java.lang.String commandId)
A unique identifier for this command.
commandId
- A unique identifier for this command.public void setDocumentName(java.lang.String documentName)
The name of the SSM document requested for execution.
documentName
- The name of the SSM document requested for execution.public java.lang.String getDocumentName()
The name of the SSM document requested for execution.
public Command withDocumentName(java.lang.String documentName)
The name of the SSM document requested for execution.
documentName
- The name of the SSM document requested for execution.public void setComment(java.lang.String comment)
User-specified information about the command, such as a brief description of what the command should do.
comment
- User-specified information about the command, such as a brief
description of what the command should do.public java.lang.String getComment()
User-specified information about the command, such as a brief description of what the command should do.
public Command withComment(java.lang.String comment)
User-specified information about the command, such as a brief description of what the command should do.
comment
- User-specified information about the command, such as a brief
description of what the command should do.public void setExpiresAfter(java.util.Date expiresAfter)
If this time is reached and the command has not already started executing, it will not execute. Calculated based on the ExpiresAfter user input provided as part of the SendCommand API.
expiresAfter
- If this time is reached and the command has not already started
executing, it will not execute. Calculated based on the
ExpiresAfter user input provided as part of the SendCommand API.public java.util.Date getExpiresAfter()
If this time is reached and the command has not already started executing, it will not execute. Calculated based on the ExpiresAfter user input provided as part of the SendCommand API.
public Command withExpiresAfter(java.util.Date expiresAfter)
If this time is reached and the command has not already started executing, it will not execute. Calculated based on the ExpiresAfter user input provided as part of the SendCommand API.
expiresAfter
- If this time is reached and the command has not already started
executing, it will not execute. Calculated based on the
ExpiresAfter user input provided as part of the SendCommand API.public java.util.Map<java.lang.String,java.util.List<java.lang.String>> getParameters()
The parameter values to be inserted in the SSM document when executing the command.
public void setParameters(java.util.Map<java.lang.String,java.util.List<java.lang.String>> parameters)
The parameter values to be inserted in the SSM document when executing the command.
parameters
- The parameter values to be inserted in the SSM document when
executing the command.public Command withParameters(java.util.Map<java.lang.String,java.util.List<java.lang.String>> parameters)
The parameter values to be inserted in the SSM document when executing the command.
parameters
- The parameter values to be inserted in the SSM document when
executing the command.public Command addParametersEntry(java.lang.String key, java.util.List<java.lang.String> value)
public Command clearParametersEntries()
public java.util.List<java.lang.String> getInstanceIds()
The instance IDs against which this command was requested.
public void setInstanceIds(java.util.Collection<java.lang.String> instanceIds)
The instance IDs against which this command was requested.
instanceIds
- The instance IDs against which this command was requested.public Command withInstanceIds(java.lang.String... instanceIds)
The instance IDs against which this command was requested.
NOTE: This method appends the values to the existing list (if
any). Use setInstanceIds(java.util.Collection)
or
withInstanceIds(java.util.Collection)
if you want to override
the existing values.
instanceIds
- The instance IDs against which this command was requested.public Command withInstanceIds(java.util.Collection<java.lang.String> instanceIds)
The instance IDs against which this command was requested.
instanceIds
- The instance IDs against which this command was requested.public void setRequestedDateTime(java.util.Date requestedDateTime)
The date and time the command was requested.
requestedDateTime
- The date and time the command was requested.public java.util.Date getRequestedDateTime()
The date and time the command was requested.
public Command withRequestedDateTime(java.util.Date requestedDateTime)
The date and time the command was requested.
requestedDateTime
- The date and time the command was requested.public void setStatus(java.lang.String status)
The status of the command.
status
- The status of the command.CommandStatus
public java.lang.String getStatus()
The status of the command.
CommandStatus
public Command withStatus(java.lang.String status)
The status of the command.
status
- The status of the command.CommandStatus
public void setStatus(CommandStatus status)
The status of the command.
status
- The status of the command.CommandStatus
public Command withStatus(CommandStatus status)
The status of the command.
status
- The status of the command.CommandStatus
public void setOutputS3BucketName(java.lang.String outputS3BucketName)
The S3 bucket where the responses to the command executions should be stored. This was requested when issuing the command.
outputS3BucketName
- The S3 bucket where the responses to the command executions should
be stored. This was requested when issuing the command.public java.lang.String getOutputS3BucketName()
The S3 bucket where the responses to the command executions should be stored. This was requested when issuing the command.
public Command withOutputS3BucketName(java.lang.String outputS3BucketName)
The S3 bucket where the responses to the command executions should be stored. This was requested when issuing the command.
outputS3BucketName
- The S3 bucket where the responses to the command executions should
be stored. This was requested when issuing the command.public void setOutputS3KeyPrefix(java.lang.String outputS3KeyPrefix)
The S3 directory path inside the bucket where the responses to the command executions should be stored. This was requested when issuing the command.
outputS3KeyPrefix
- The S3 directory path inside the bucket where the responses to the
command executions should be stored. This was requested when
issuing the command.public java.lang.String getOutputS3KeyPrefix()
The S3 directory path inside the bucket where the responses to the command executions should be stored. This was requested when issuing the command.
public Command withOutputS3KeyPrefix(java.lang.String outputS3KeyPrefix)
The S3 directory path inside the bucket where the responses to the command executions should be stored. This was requested when issuing the command.
outputS3KeyPrefix
- The S3 directory path inside the bucket where the responses to the
command executions should be stored. This was requested when
issuing the command.public java.lang.String toString()
toString
in class java.lang.Object
Object.toString()
public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object
public Command clone()
clone
in class java.lang.Object