@Override public boolean equals(Object o) { if (o == this) { return true; } if (o instanceof AttachedNetwork) { AttachedNetwork that = (AttachedNetwork) o; return ((this.aliases == null) ? (that.aliases() == null) : this.aliases.equals(that.aliases())) && ((this.networkId == null) ? (that.networkId() == null) : this.networkId.equals(that.networkId())) && (this.endpointId.equals(that.endpointId())) && (this.gateway.equals(that.gateway())) && (this.ipAddress.equals(that.ipAddress())) && (this.ipPrefixLen.equals(that.ipPrefixLen())) && (this.ipv6Gateway.equals(that.ipv6Gateway())) && (this.globalIPv6Address.equals(that.globalIPv6Address())) && (this.globalIPv6PrefixLen.equals(that.globalIPv6PrefixLen())) && (this.macAddress.equals(that.macAddress())); } return false; }
public String getHost(String containerId, String network) throws DockerException, InterruptedException { return IS_OS_LINUX ? dockerClient.inspectContainer(containerId).networkSettings() .networks().get(network).gateway() : dockerClient.getHost(); }
@Override public boolean equals(Object o) { if (o == this) { return true; } if (o instanceof AttachedNetwork) { AttachedNetwork that = (AttachedNetwork) o; return ((this.aliases == null) ? (that.aliases() == null) : this.aliases.equals(that.aliases())) && ((this.networkId == null) ? (that.networkId() == null) : this.networkId.equals(that.networkId())) && (this.endpointId.equals(that.endpointId())) && (this.gateway.equals(that.gateway())) && (this.ipAddress.equals(that.ipAddress())) && (this.ipPrefixLen.equals(that.ipPrefixLen())) && (this.ipv6Gateway.equals(that.ipv6Gateway())) && (this.globalIPv6Address.equals(that.globalIPv6Address())) && (this.globalIPv6PrefixLen.equals(that.globalIPv6PrefixLen())) && (this.macAddress.equals(that.macAddress())); } return false; }