Skip to content

Commit ef03027

Browse files
committed
Improve JavaDoc and include @checkfornull
Conflicts: src/main/java/com/github/dockerjava/api/model/Statistics.java
1 parent f8a5fb4 commit ef03027

File tree

1 file changed

+15
-1
lines changed

1 file changed

+15
-1
lines changed

src/main/java/com/github/dockerjava/api/model/Statistics.java

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22

33
import java.util.Map;
44

5+
import javax.annotation.CheckForNull;
6+
57
import org.apache.commons.lang.builder.ToStringBuilder;
68

79
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
@@ -16,11 +18,15 @@ public class Statistics {
1618
@JsonProperty("read")
1719
private String read;
1820

21+
/**
22+
* @since Docker Remote API 1.21
23+
*/
24+
@CheckForNull
1925
@JsonProperty("networks")
2026
private Map<String, Object> networksStats;
2127

2228
/**
23-
* Deprecated as of Docker Remote API 1.21
29+
* @deprecated as of Docker Remote API 1.21, replaced by {@link #networksStats}
2430
*/
2531
@Deprecated
2632
@JsonProperty("network")
@@ -35,10 +41,18 @@ public class Statistics {
3541
@JsonProperty("cpu_stats")
3642
private Map<String, Object> cpuStats;
3743

44+
/**
45+
* @since Docker Remote API 1.21
46+
*/
47+
@CheckForNull
3848
public Map<String, Object> getNetworksStats() {
3949
return networksStats;
4050
}
4151

52+
/**
53+
* @deprecated as of Docker Remote API 1.21, replaced by {@link #getNetworksStats()}
54+
*/
55+
@Deprecated
4256
public Map<String, Object> getNetworkStats() {
4357
return networkStats;
4458
}

0 commit comments

Comments
 (0)