forked from docker-java/docker-java
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathWaitContainerCmd.java
More file actions
37 lines (28 loc) · 975 Bytes
/
Copy pathWaitContainerCmd.java
File metadata and controls
37 lines (28 loc) · 975 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
package com.github.dockerjava.api.command;
import javax.annotation.CheckForNull;
import javax.annotation.Nonnull;
import com.github.dockerjava.api.async.ResultCallback;
import com.github.dockerjava.api.exception.NotFoundException;
import com.github.dockerjava.api.model.WaitResponse;
/**
* Wait a container
*
* Block until container stops, then returns its exit code
*/
public interface WaitContainerCmd extends AsyncDockerCmd<WaitContainerCmd, WaitResponse> {
@CheckForNull
String getContainerId();
WaitContainerCmd withContainerId(@Nonnull String containerId);
/**
* @throws NotFoundException
* container not found
*/
@Override
<T extends ResultCallback<WaitResponse>> T exec(T resultCallback);
@Override
default WaitContainerResultCallback start() {
return exec(new WaitContainerResultCallback());
}
interface Exec extends DockerCmdAsyncExec<WaitContainerCmd, WaitResponse> {
}
}