All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.fitbur.github.dockerjava.api.command.StopContainerCmd Maven / Gradle / Ivy

There is a newer version: 1.0.0
Show newest version
package com.fitbur.github.dockerjava.api.com.fitburmand;

import com.fitbur.github.dockerjava.api.NotFoundException;
import com.fitbur.github.dockerjava.api.NotModifiedException;

/**
 * Stop a running container.
 *
 * @param containerId
 *            - Id of the container
 * @param timeout
 *            - Timeout in seconds before killing the container. Defaults to 10 seconds.
 *
 */
public interface StopContainerCmd extends SyncDockerCmd {

    public String getContainerId();

    public int getTimeout();

    public StopContainerCmd withContainerId(String containerId);

    public StopContainerCmd withTimeout(int timeout);

    /**
     * @throws NotFoundException
     *             No such container
     * @throws NotModifiedException
     *             Container already stopped
     */
    @Override
    public Void exec() throws NotFoundException, NotModifiedException;

    public static interface Exec extends DockerCmdSyncExec {
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy