com.eurotech.framework.net
Enum NetworkState

java.lang.Object
  extended by java.lang.Enum<NetworkState>
      extended by com.eurotech.framework.net.NetworkState
All Implemented Interfaces:
Serializable, Comparable<NetworkState>

public enum NetworkState
extends Enum<NetworkState>

The overall state of the networking subsystem.


Enum Constant Summary
ASLEEP
          Networking is inactive and all devices are disabled.
CONNECTED_GLOBAL
          A network device is connected, with global network connectivity.
CONNECTED_LOCAL
          A network device is connected, but there is only link-local connectivity.
CONNECTED_SITE
          A network device is connected, but there is only site-local connectivity.
CONNECTING
          A network device is connecting to a network and there is no other available network connection.
DISCONNECTED
          There is no active network connection.
DISCONNECTING
          Network connections are being cleaned up.
UNKNOWN
          Networking state is unknown.
 
Method Summary
static NetworkState parseCode(int code)
           
static NetworkState valueOf(String name)
          Returns the enum constant of this type with the specified name.
static NetworkState[] values()
          Returns an array containing the constants of this enum type, in the order they are declared.
 
Methods inherited from class java.lang.Enum
clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Enum Constant Detail

UNKNOWN

public static final NetworkState UNKNOWN
Networking state is unknown.


ASLEEP

public static final NetworkState ASLEEP
Networking is inactive and all devices are disabled.


DISCONNECTED

public static final NetworkState DISCONNECTED
There is no active network connection.


DISCONNECTING

public static final NetworkState DISCONNECTING
Network connections are being cleaned up.


CONNECTING

public static final NetworkState CONNECTING
A network device is connecting to a network and there is no other available network connection.


CONNECTED_LOCAL

public static final NetworkState CONNECTED_LOCAL
A network device is connected, but there is only link-local connectivity.


CONNECTED_SITE

public static final NetworkState CONNECTED_SITE
A network device is connected, but there is only site-local connectivity.


CONNECTED_GLOBAL

public static final NetworkState CONNECTED_GLOBAL
A network device is connected, with global network connectivity.

Method Detail

values

public static 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 (NetworkState c : 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 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 name
NullPointerException - if the argument is null

parseCode

public static NetworkState parseCode(int code)


Copyright © 2013. All Rights Reserved.