Skip to content

Commit 8fd8953

Browse files
authored
Rename RestartContainerCmd#withtTimeout to #withTimeout (docker-java#1817)
Fixes docker-java#1792
1 parent 0169cc4 commit 8fd8953

File tree

2 files changed

+10
-2
lines changed

2 files changed

+10
-2
lines changed

docker-java-api/src/main/java/com/github/dockerjava/api/command/RestartContainerCmd.java

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,15 @@ public interface RestartContainerCmd extends SyncDockerCmd<Void> {
2222

2323
RestartContainerCmd withContainerId(@Nonnull String containerId);
2424

25-
RestartContainerCmd withtTimeout(Integer timeout);
25+
/**
26+
* @deprecated wrong name, use {@link #withTimeout(Integer)}
27+
*/
28+
@Deprecated
29+
default RestartContainerCmd withtTimeout(Integer timeout) {
30+
return withTimeout(timeout);
31+
}
32+
33+
RestartContainerCmd withTimeout(Integer timeout);
2634

2735
/**
2836
* @throws NotFoundException

docker-java-core/src/main/java/com/github/dockerjava/core/command/RestartContainerCmdImpl.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ public RestartContainerCmd withContainerId(String containerId) {
4242
}
4343

4444
@Override
45-
public RestartContainerCmd withtTimeout(Integer timeout) {
45+
public RestartContainerCmd withTimeout(Integer timeout) {
4646
checkNotNull(timeout, "timeout was not specified");
4747
checkArgument(timeout >= 0, "timeout must be greater or equal 0");
4848
this.timeout = timeout;

0 commit comments

Comments
 (0)