com.github.dockerjava.core.command
Class StartContainerCmdImpl
java.lang.Object
com.github.dockerjava.core.command.AbstrDockerCmd<StartContainerCmd,Void>
com.github.dockerjava.core.command.StartContainerCmdImpl
- All Implemented Interfaces:
- DockerCmd<Void>, StartContainerCmd
public class StartContainerCmdImpl
- extends AbstrDockerCmd<StartContainerCmd,Void>
- implements StartContainerCmd
Start a container
StartContainerCmdImpl
public StartContainerCmdImpl(StartContainerCmd.Exec exec,
String containerId)
getBinds
public Bind[] getBinds()
- Specified by:
getBinds
in interface StartContainerCmd
getLinks
public Link[] getLinks()
- Specified by:
getLinks
in interface StartContainerCmd
getLxcConf
public LxcConf[] getLxcConf()
- Specified by:
getLxcConf
in interface StartContainerCmd
getPortBindings
public Ports getPortBindings()
- Specified by:
getPortBindings
in interface StartContainerCmd
isPublishAllPorts
public boolean isPublishAllPorts()
- Specified by:
isPublishAllPorts
in interface StartContainerCmd
isPrivileged
public boolean isPrivileged()
- Specified by:
isPrivileged
in interface StartContainerCmd
getDns
public String[] getDns()
- Specified by:
getDns
in interface StartContainerCmd
getVolumesFrom
public String getVolumesFrom()
- Specified by:
getVolumesFrom
in interface StartContainerCmd
getContainerId
public String getContainerId()
- Specified by:
getContainerId
in interface StartContainerCmd
getNetworkMode
public String getNetworkMode()
- Specified by:
getNetworkMode
in interface StartContainerCmd
getDevices
public Device[] getDevices()
- Specified by:
getDevices
in interface StartContainerCmd
getRestartPolicy
public RestartPolicy getRestartPolicy()
- Specified by:
getRestartPolicy
in interface StartContainerCmd
getCapAdd
public String[] getCapAdd()
- Specified by:
getCapAdd
in interface StartContainerCmd
getCapDrop
public String[] getCapDrop()
- Specified by:
getCapDrop
in interface StartContainerCmd
withBinds
public StartContainerCmd withBinds(Bind... binds)
- Specified by:
withBinds
in interface StartContainerCmd
withLinks
public StartContainerCmd withLinks(Link... links)
- Specified by:
withLinks
in interface StartContainerCmd
withLxcConf
public StartContainerCmd withLxcConf(LxcConf... lxcConf)
- Specified by:
withLxcConf
in interface StartContainerCmd
withPortBindings
public StartContainerCmd withPortBindings(Ports portBindings)
- Specified by:
withPortBindings
in interface StartContainerCmd
withPrivileged
public StartContainerCmd withPrivileged(boolean privileged)
- Specified by:
withPrivileged
in interface StartContainerCmd
withPublishAllPorts
public StartContainerCmd withPublishAllPorts(boolean publishAllPorts)
- Specified by:
withPublishAllPorts
in interface StartContainerCmd
withDns
public StartContainerCmd withDns(String... dns)
- Specified by:
withDns
in interface StartContainerCmd
withVolumesFrom
public StartContainerCmd withVolumesFrom(String volumesFrom)
- Specified by:
withVolumesFrom
in interface StartContainerCmd
withContainerId
public StartContainerCmd withContainerId(String containerId)
- Specified by:
withContainerId
in interface StartContainerCmd
withNetworkMode
public StartContainerCmd withNetworkMode(String networkMode)
- Specified by:
withNetworkMode
in interface StartContainerCmd
withDevices
public StartContainerCmd withDevices(Device... devices)
- Specified by:
withDevices
in interface StartContainerCmd
withRestartPolicy
public StartContainerCmd withRestartPolicy(RestartPolicy restartPolicy)
- Specified by:
withRestartPolicy
in interface StartContainerCmd
withCapAdd
public StartContainerCmd withCapAdd(String... capAdd)
- Specified by:
withCapAdd
in interface StartContainerCmd
withCapDrop
public StartContainerCmd withCapDrop(String... capDrop)
- Specified by:
withCapDrop
in interface StartContainerCmd
toString
public String toString()
- Overrides:
toString
in class Object
exec
public Void exec()
throws NotFoundException,
NotModifiedException
- Specified by:
exec
in interface DockerCmd<Void>
- Specified by:
exec
in interface StartContainerCmd
- Overrides:
exec
in class AbstrDockerCmd<StartContainerCmd,Void>
- Throws:
NotFoundException
- No such container
NotModifiedException
- Container already started
Copyright © 2014. All rights reserved.