Record Class NetworkServiceInfo
java.lang.Object
java.lang.Record
eu.cloudnetservice.modules.bridge.player.NetworkServiceInfo
- Record Components:
groups- the groups of the represented service.serviceId- the service id of the represented service.
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionNetworkServiceInfo(@NonNull Set<String> groups, @NonNull eu.cloudnetservice.driver.service.ServiceId serviceId) Creates an instance of aNetworkServiceInforecord class. -
Method Summary
Modifier and TypeMethodDescription@NonNull eu.cloudnetservice.driver.service.ServiceEnvironmentTypeGets the environment of the given service from the given service id.final booleanIndicates whether some other object is "equal to" this one.static @NonNull NetworkServiceInfofromServiceInfoSnapshot(@NonNull eu.cloudnetservice.driver.service.ServiceInfoSnapshot snapshot) Creates a new network service info with groups and the service id from the given service.groups()Returns the value of thegroupsrecord component.final inthashCode()Returns a hash code value for this object.Gets the name of the given service from the given service id.@NonNull eu.cloudnetservice.driver.service.ServiceIdReturns the value of theserviceIdrecord component.taskName()Gets the name of the task the given service is associated with.final StringtoString()Returns a string representation of this record class.uniqueId()Gets the unique id of the given service from the given service id.
-
Field Details
-
groups
-
serviceId
-
-
Constructor Details
-
NetworkServiceInfo
-
-
Method Details
-
fromServiceInfoSnapshot
@NonNull public static @NonNull NetworkServiceInfo fromServiceInfoSnapshot(@NonNull @NonNull eu.cloudnetservice.driver.service.ServiceInfoSnapshot snapshot) Creates a new network service info with groups and the service id from the given service.- Parameters:
snapshot- the snapshot to create a network service from.- Returns:
- the new network service info for the given service info.
- Throws:
NullPointerException- if the given snapshot is null.
-
environment
-
uniqueId
-
serverName
-
taskName
-
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. All components in this record class are compared withObjects::equals(Object,Object). -
groups
-
serviceId
-