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 Containerclone()booleanequals(Object obj)StringgetContainerArn()The Amazon Resource Name (ARN) of the container.IntegergetExitCode()The exit code returned from the container.StringgetLastStatus()The last known status of the container.StringgetName()The name of the container.List<NetworkBinding>getNetworkBindings()The network bindings associated with the container.StringgetReason()A short (255 max characters) human-readable string to provide additional detail about a running or stopped container.StringgetTaskArn()The Amazon Resource Name (ARN) of the task.inthashCode()voidsetContainerArn(String containerArn)The Amazon Resource Name (ARN) of the container.voidsetExitCode(Integer exitCode)The exit code returned from the container.voidsetLastStatus(String lastStatus)The last known status of the container.voidsetName(String name)The name of the container.voidsetNetworkBindings(Collection<NetworkBinding> networkBindings)The network bindings associated with the container.voidsetReason(String reason)A short (255 max characters) human-readable string to provide additional detail about a running or stopped container.voidsetTaskArn(String taskArn)The Amazon Resource Name (ARN) of the task.StringtoString()Returns a string representation of this object; useful for testing and debugging.ContainerwithContainerArn(String containerArn)The Amazon Resource Name (ARN) of the container.ContainerwithExitCode(Integer exitCode)The exit code returned from the container.ContainerwithLastStatus(String lastStatus)The last known status of the container.ContainerwithName(String name)The name of the container.ContainerwithNetworkBindings(NetworkBinding... networkBindings)The network bindings associated with the container.ContainerwithNetworkBindings(Collection<NetworkBinding> networkBindings)The network bindings associated with the container.ContainerwithReason(String reason)A short (255 max characters) human-readable string to provide additional detail about a running or stopped container.ContainerwithTaskArn(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:
toStringin classObject- Returns:
- A string representation of this object.
- See Also:
Object.toString()
-
-