com.github.dockerjava.core.command
Class RestartContainerCmdImpl

java.lang.Object
  extended by com.github.dockerjava.core.command.AbstrDockerCmd<RestartContainerCmd,Void>
      extended by com.github.dockerjava.core.command.RestartContainerCmdImpl
All Implemented Interfaces:
DockerCmd<Void>, RestartContainerCmd

public class RestartContainerCmdImpl
extends AbstrDockerCmd<RestartContainerCmd,Void>
implements RestartContainerCmd

Restart a running container.


Nested Class Summary
 
Nested classes/interfaces inherited from interface com.github.dockerjava.api.command.RestartContainerCmd
RestartContainerCmd.Exec
 
Field Summary
 
Fields inherited from class com.github.dockerjava.core.command.AbstrDockerCmd
execution
 
Constructor Summary
RestartContainerCmdImpl(RestartContainerCmd.Exec exec, String containerId)
           
 
Method Summary
 Void exec()
           
 String getContainerId()
           
 int getTimeout()
           
 String toString()
           
 RestartContainerCmd withContainerId(String containerId)
           
 RestartContainerCmd withtTimeout(int timeout)
           
 
Methods inherited from class com.github.dockerjava.core.command.AbstrDockerCmd
toDockerException
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

RestartContainerCmdImpl

public RestartContainerCmdImpl(RestartContainerCmd.Exec exec,
                               String containerId)
Method Detail

getContainerId

public String getContainerId()
Specified by:
getContainerId in interface RestartContainerCmd

getTimeout

public int getTimeout()
Specified by:
getTimeout in interface RestartContainerCmd

withContainerId

public RestartContainerCmd withContainerId(String containerId)
Specified by:
withContainerId in interface RestartContainerCmd

withtTimeout

public RestartContainerCmd withtTimeout(int timeout)
Specified by:
withtTimeout in interface RestartContainerCmd

toString

public String toString()
Overrides:
toString in class Object

exec

public Void exec()
          throws NotFoundException
Specified by:
exec in interface DockerCmd<Void>
Specified by:
exec in interface RestartContainerCmd
Overrides:
exec in class AbstrDockerCmd<RestartContainerCmd,Void>
Throws:
NotFoundException - No such container


Copyright © 2014. All rights reserved.