Record Class ProxyHostStatus
- Record Components:
name- the Proxy Host's own nameaddress- the Proxy Host's own address (HOS_HOST)connected- whether its Continental Mover is currently connected to the MasterServer (seeManagementInterface.getActiveProxyHostNames()), resolved via that Host'sproxy.rootoption (seeECtransOptions#HOST_PROXY_ROOT)root- this Host's ownproxy.rootoption value, or blank/nullif left unconfiguredlatitude- this Proxy Host's own resolved latitude, ornullif unresolvedlongitude- this Proxy Host's own resolved longitude, ornullif unresolvednickname- the Proxy Host's display nickname (HOS_NICKNAME)
- All Implemented Interfaces:
Serializable
latitude/longitude are resolved once, server-side, by ManagementImpl#getEnabledProxyHosts()
itself (preferring this Host's own manually-stored location over a live GeoIP guess of its raw address - see
ManagementImpl#_resolveProxyHostLocation), rather than left for the caller to re-resolve generically via
ManagementInterface.getGeoLocations(String[]). That generic, address-keyed lookup has no way to tell a Proxy
Host's own address apart from an ordinary target Host's address that merely failed to resolve, and could therefore
end up resolving both to the same coincidental fallback location - resolving it here instead, directly from the
actual Host object, avoids that ambiguity entirely. null when neither a stored location nor a live
GeoIP lookup of the address succeeded.
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionaddress()Returns the value of theaddressrecord component.booleanReturns the value of theconnectedrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.latitude()Returns the value of thelatituderecord component.Returns the value of thelongituderecord component.name()Returns the value of thenamerecord component.nickname()Returns the value of thenicknamerecord component.root()Returns the value of therootrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
ProxyHostStatus
public ProxyHostStatus(String name, String address, boolean connected, String root, Double latitude, Double longitude, String nickname) Creates an instance of aProxyHostStatusrecord class.- Parameters:
name- the value for thenamerecord componentaddress- the value for theaddressrecord componentconnected- the value for theconnectedrecord componentroot- the value for therootrecord componentlatitude- the value for thelatituderecord componentlongitude- the value for thelongituderecord componentnickname- the value for thenicknamerecord component
-
-
Method Details
-
toString
-
hashCode
-
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with thecomparemethod from their corresponding wrapper classes. -
name
-
address
-
connected
-
root
-
latitude
-
longitude
-
nickname
-