Class ServerInfo
java.lang.Object
com.velocitypowered.api.proxy.server.ServerInfo
- All Implemented Interfaces:
Comparable<ServerInfo>
ServerInfo represents a server that a player can connect to. This object is immutable and safe
for concurrent access.
-
Constructor Summary
ConstructorsConstructorDescriptionServerInfo(String name, InetSocketAddress address) Creates a new ServerInfo object. -
Method Summary
-
Constructor Details
-
ServerInfo
Creates a new ServerInfo object.- Parameters:
name- the name for the serveraddress- the address of the server to connect to
-
-
Method Details
-
getName
Gets the name of the server.- Returns:
- the name of the server
-
getAddress
Gets the network address of the server.- Returns:
- the
InetSocketAddressof the server
-
toString
-
equals
-
hashCode
public int hashCode() -
compareTo
- Specified by:
compareToin interfaceComparable<ServerInfo>
-