forked from docker-java/docker-java
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathInspectServiceCmdImpl.java
More file actions
42 lines (34 loc) · 1.06 KB
/
Copy pathInspectServiceCmdImpl.java
File metadata and controls
42 lines (34 loc) · 1.06 KB
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
38
39
40
41
42
package com.github.dockerjava.core.command;
import com.github.dockerjava.api.command.InspectServiceCmd;
import com.github.dockerjava.api.exception.NotFoundException;
import com.github.dockerjava.api.model.Service;
import static com.google.common.base.Preconditions.checkNotNull;
/**
* Inspect the details of a container.
*/
public class InspectServiceCmdImpl extends AbstrDockerCmd<InspectServiceCmd, Service> implements
InspectServiceCmd {
private String serviceId;
public InspectServiceCmdImpl(Exec exec, String serviceId) {
super(exec);
withServiceId(serviceId);
}
@Override
public String getServiceId() {
return serviceId;
}
@Override
public InspectServiceCmd withServiceId(String serviceId) {
checkNotNull(serviceId, "serviceId was not specified");
this.serviceId = serviceId;
return this;
}
/**
* @throws NotFoundException
* No such service
*/
@Override
public Service exec() throws NotFoundException {
return super.exec();
}
}