Package de.coreengine.network
Enum NetworkManager.NetworkState
- java.lang.Object
-
- java.lang.Enum<NetworkManager.NetworkState>
-
- de.coreengine.network.NetworkManager.NetworkState
-
- All Implemented Interfaces:
Serializable
,Comparable<NetworkManager.NetworkState>
- Enclosing class:
- NetworkManager
public static enum NetworkManager.NetworkState extends Enum<NetworkManager.NetworkState>
Network state of the game (one of):
- DEDICATED_SERVER (Only server)
- HOSTER (Hosting client)
- CLIENT (Connected Client)
- SINGLE (Singleplayer)
-
-
Enum Constant Summary
Enum Constants Enum Constant Description CLIENT
DEDICATED_SERVER
HOSTER
SINGLEPLAYER
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static NetworkManager.NetworkState
valueOf(String name)
Returns the enum constant of this type with the specified name.static NetworkManager.NetworkState[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
DEDICATED_SERVER
public static final NetworkManager.NetworkState DEDICATED_SERVER
-
HOSTER
public static final NetworkManager.NetworkState HOSTER
-
CLIENT
public static final NetworkManager.NetworkState CLIENT
-
SINGLEPLAYER
public static final NetworkManager.NetworkState SINGLEPLAYER
-
-
Method Detail
-
values
public static NetworkManager.NetworkState[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (NetworkManager.NetworkState c : NetworkManager.NetworkState.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static NetworkManager.NetworkState valueOf(String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is null
-
-