Class Container
- java.lang.Object
-
- com.amazonaws.services.ecs.model.Container
-
- All Implemented Interfaces:
Serializable
,Cloneable
public class Container extends Object implements Serializable, Cloneable
A Docker container that is part of a task.
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description Container()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Container
clone()
boolean
equals(Object obj)
String
getContainerArn()
The Amazon Resource Name (ARN) of the container.Integer
getExitCode()
The exit code returned from the container.String
getLastStatus()
The last known status of the container.String
getName()
The name of the container.List<NetworkBinding>
getNetworkBindings()
The network bindings associated with the container.String
getReason()
A short (255 max characters) human-readable string to provide additional detail about a running or stopped container.String
getTaskArn()
The Amazon Resource Name (ARN) of the task.int
hashCode()
void
setContainerArn(String containerArn)
The Amazon Resource Name (ARN) of the container.void
setExitCode(Integer exitCode)
The exit code returned from the container.void
setLastStatus(String lastStatus)
The last known status of the container.void
setName(String name)
The name of the container.void
setNetworkBindings(Collection<NetworkBinding> networkBindings)
The network bindings associated with the container.void
setReason(String reason)
A short (255 max characters) human-readable string to provide additional detail about a running or stopped container.void
setTaskArn(String taskArn)
The Amazon Resource Name (ARN) of the task.String
toString()
Returns a string representation of this object; useful for testing and debugging.Container
withContainerArn(String containerArn)
The Amazon Resource Name (ARN) of the container.Container
withExitCode(Integer exitCode)
The exit code returned from the container.Container
withLastStatus(String lastStatus)
The last known status of the container.Container
withName(String name)
The name of the container.Container
withNetworkBindings(NetworkBinding... networkBindings)
The network bindings associated with the container.Container
withNetworkBindings(Collection<NetworkBinding> networkBindings)
The network bindings associated with the container.Container
withReason(String reason)
A short (255 max characters) human-readable string to provide additional detail about a running or stopped container.Container
withTaskArn(String taskArn)
The Amazon Resource Name (ARN) of the task.
-
-
-
Method Detail
-
setContainerArn
public void setContainerArn(String containerArn)
The Amazon Resource Name (ARN) of the container.
- Parameters:
containerArn
- The Amazon Resource Name (ARN) of the container.
-
getContainerArn
public String getContainerArn()
The Amazon Resource Name (ARN) of the container.
- Returns:
- The Amazon Resource Name (ARN) of the container.
-
withContainerArn
public Container withContainerArn(String containerArn)
The Amazon Resource Name (ARN) of the container.
- Parameters:
containerArn
- The Amazon Resource Name (ARN) of the container.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setTaskArn
public void setTaskArn(String taskArn)
The Amazon Resource Name (ARN) of the task.
- Parameters:
taskArn
- The Amazon Resource Name (ARN) of the task.
-
getTaskArn
public String getTaskArn()
The Amazon Resource Name (ARN) of the task.
- Returns:
- The Amazon Resource Name (ARN) of the task.
-
withTaskArn
public Container withTaskArn(String taskArn)
The Amazon Resource Name (ARN) of the task.
- Parameters:
taskArn
- The Amazon Resource Name (ARN) of the task.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setName
public void setName(String name)
The name of the container.
- Parameters:
name
- The name of the container.
-
getName
public String getName()
The name of the container.
- Returns:
- The name of the container.
-
withName
public Container withName(String name)
The name of the container.
- Parameters:
name
- The name of the container.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setLastStatus
public void setLastStatus(String lastStatus)
The last known status of the container.
- Parameters:
lastStatus
- The last known status of the container.
-
getLastStatus
public String getLastStatus()
The last known status of the container.
- Returns:
- The last known status of the container.
-
withLastStatus
public Container withLastStatus(String lastStatus)
The last known status of the container.
- Parameters:
lastStatus
- The last known status of the container.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setExitCode
public void setExitCode(Integer exitCode)
The exit code returned from the container.
- Parameters:
exitCode
- The exit code returned from the container.
-
getExitCode
public Integer getExitCode()
The exit code returned from the container.
- Returns:
- The exit code returned from the container.
-
withExitCode
public Container withExitCode(Integer exitCode)
The exit code returned from the container.
- Parameters:
exitCode
- The exit code returned from the container.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setReason
public void setReason(String reason)
A short (255 max characters) human-readable string to provide additional detail about a running or stopped container.
- Parameters:
reason
- A short (255 max characters) human-readable string to provide additional detail about a running or stopped container.
-
getReason
public String getReason()
A short (255 max characters) human-readable string to provide additional detail about a running or stopped container.
- Returns:
- A short (255 max characters) human-readable string to provide additional detail about a running or stopped container.
-
withReason
public Container withReason(String reason)
A short (255 max characters) human-readable string to provide additional detail about a running or stopped container.
- Parameters:
reason
- A short (255 max characters) human-readable string to provide additional detail about a running or stopped container.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
getNetworkBindings
public List<NetworkBinding> getNetworkBindings()
The network bindings associated with the container.
- Returns:
- The network bindings associated with the container.
-
setNetworkBindings
public void setNetworkBindings(Collection<NetworkBinding> networkBindings)
The network bindings associated with the container.
- Parameters:
networkBindings
- The network bindings associated with the container.
-
withNetworkBindings
public Container withNetworkBindings(NetworkBinding... networkBindings)
The network bindings associated with the container.
NOTE: This method appends the values to the existing list (if any). Use
setNetworkBindings(java.util.Collection)
orwithNetworkBindings(java.util.Collection)
if you want to override the existing values.- Parameters:
networkBindings
- The network bindings associated with the container.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
withNetworkBindings
public Container withNetworkBindings(Collection<NetworkBinding> networkBindings)
The network bindings associated with the container.
- Parameters:
networkBindings
- The network bindings associated with the container.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
toString
public String toString()
Returns a string representation of this object; useful for testing and debugging.- Overrides:
toString
in classObject
- Returns:
- A string representation of this object.
- See Also:
Object.toString()
-
-