Package io.deephaven.process
Class NetworkOshi
java.lang.Object
io.deephaven.process.NetworkOshi
- All Implemented Interfaces:
PropertySet
NetworkParams presents network parameters of running OS, such as DNS, host name etc.
-
Nested Class Summary
Nested classes/interfaces inherited from interface io.deephaven.properties.PropertySet
PropertySet.PropertiesImpl, PropertySet.StringListImpl, PropertySet.StringMapImpl
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic NetworkOshi
from
(oshi.software.os.NetworkParams network) abstract io.deephaven.process.DnsServers
getDnsServers.getDomainName.abstract String
getHostName.getIpv4DefaultGateway.getIpv6DefaultGateway.final void
traverse
(PropertyVisitor visitor) Traverse this property set and output the property key/values to the given visitor.
-
Constructor Details
-
NetworkOshi
public NetworkOshi()
-
-
Method Details
-
getHostName
getHostName.
- Returns:
- Gets host name
-
getDomainName
getDomainName.
- Returns:
- Gets domain name
-
getDnsServers
@Parameter public abstract io.deephaven.process.DnsServers getDnsServers()getDnsServers.
- Returns:
- Gets DNS servers
-
getIpv4DefaultGateway
getIpv4DefaultGateway.
- Returns:
- Gets default gateway(routing destination for 0.0.0.0/0) for IPv4
-
getIpv6DefaultGateway
getIpv6DefaultGateway.
- Returns:
- Gets default gateway(routing destination for ::/0) for IPv6
-
traverse
Description copied from interface:PropertySet
Traverse this property set and output the property key/values to the given visitor.Callers should typically prefer to call
PropertyVisitor.visitProperties(PropertySet)
, as the inversion of logic allows the visitor (the more stateful object) to potentially perform initialization logic and traverse more efficiently.- Specified by:
traverse
in interfacePropertySet
- Parameters:
visitor
- the visitor- See Also:
-
from
-