public class MCPingResponse extends java.lang.Object implements IPingResponse
ModernPing and LegacyPing.| Modifier and Type | Class and Description |
|---|---|
static class |
MCPingResponse.ForgeData |
static class |
MCPingResponse.ModInfo |
static class |
MCPingResponse.Players |
static class |
MCPingResponse.Server |
static class |
MCPingResponse.Version |
| Modifier and Type | Field and Description |
|---|---|
java.lang.String |
description |
DescriptionType |
descriptionType |
java.lang.String |
favicon |
MCPingResponse.ForgeData |
forgeData |
MCPingResponse.ModInfo |
modinfo |
MCPingResponse.Players |
players |
java.lang.Boolean |
previewsChat |
MCPingResponse.Server |
server |
MCPingResponse.Version |
version |
| Constructor and Description |
|---|
MCPingResponse() |
| Modifier and Type | Method and Description |
|---|---|
java.lang.String |
getAddress()
Get the address of the server.
|
java.lang.String |
getFavicon()
Get the favicon of the server.
|
int |
getMaxPlayers()
Get the maximum amount of players that can be online on the server.
|
java.lang.String |
getMotd()
Get the MOTD of the server.
|
int |
getOnlinePlayers()
Get the amount of players currently online on the server.
|
long |
getPing()
Get the ping to the server in milliseconds.
|
int |
getPort()
Get the port of the server.
|
int |
getProtocolId()
Get the protocol id of the server.
|
java.util.List<java.lang.String> |
getSample()
Get a sample of players on the server.
|
java.lang.String |
getVersionName()
Get the version name of the server.
|
java.lang.String |
toString() |
public java.lang.String description
public DescriptionType descriptionType
public java.lang.String favicon
public MCPingResponse.Server server
public java.lang.Boolean previewsChat
public MCPingResponse.Version version
public MCPingResponse.Players players
public MCPingResponse.ModInfo modinfo
public MCPingResponse.ForgeData forgeData
@Nonnull public java.lang.String getAddress()
IPingResponseMCPingResponse, ClassicPingResponse, BedrockPingResponse, QueryPingResponse, SocketPingResponse"Unknown"getAddress in interface IPingResponsepublic int getPort()
IPingResponseMCPingResponse, ClassicPingResponse, BedrockPingResponse, QueryPingResponse, SocketPingResponse-1getPort in interface IPingResponse@Nonnull public java.lang.String getMotd()
IPingResponseMCPingResponse, ClassicPingResponse, BedrockPingResponse, QueryPingResponse"Unknown"getMotd in interface IPingResponse@Nullable public java.lang.String getFavicon()
IPingResponseMCPingResponsenullgetFavicon in interface IPingResponsepublic long getPing()
IPingResponseMCPingResponse, ClassicPingResponse, BedrockPingResponse, QueryPingResponse, SocketPingResponse-1getPing in interface IPingResponsepublic int getOnlinePlayers()
IPingResponseMCPingResponse, BedrockPingResponse, QueryPingResponse-1getOnlinePlayers in interface IPingResponsepublic int getMaxPlayers()
IPingResponseMCPingResponse, BedrockPingResponse, QueryPingResponse-1getMaxPlayers in interface IPingResponse@Nonnull public java.lang.String getVersionName()
IPingResponseMCPingResponse, BedrockPingResponse, QueryPingResponse"Unknown"getVersionName in interface IPingResponsepublic int getProtocolId()
IPingResponseMCPingResponse, ClassicPingResponse, BedrockPingResponse, QueryPingResponse-1getProtocolId in interface IPingResponse@Nonnull public java.util.List<java.lang.String> getSample()
IPingResponseBedrockPingResponse).MCPingResponse, BedrockPingResponse, QueryPingResponsegetSample in interface IPingResponsepublic java.lang.String toString()
toString in class java.lang.Object