Package org.onosproject.net
Enum MastershipRole
- java.lang.Object
-
- java.lang.Enum<MastershipRole>
-
- org.onosproject.net.MastershipRole
-
- All Implemented Interfaces:
java.io.Serializable
,java.lang.Comparable<MastershipRole>
public enum MastershipRole extends java.lang.Enum<MastershipRole>
Representation of a relationship role of a controller instance to a device or a region of network environment.
-
-
Enum Constant Summary
Enum Constants Enum Constant Description MASTER
Represents a relationship where the controller instance is the master to a device or a region of network environment.NONE
Represents that the controller instance is not eligible to be the master to a device or a region of network environment.STANDBY
Represents a relationship where the controller instance is the standby, i.e.
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static MastershipRole
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.static MastershipRole[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
MASTER
public static final MastershipRole MASTER
Represents a relationship where the controller instance is the master to a device or a region of network environment.
-
STANDBY
public static final MastershipRole STANDBY
Represents a relationship where the controller instance is the standby, i.e. potential master to a device or a region of network environment.
-
NONE
public static final MastershipRole NONE
Represents that the controller instance is not eligible to be the master to a device or a region of network environment.
-
-
Method Detail
-
values
public static MastershipRole[] 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 (MastershipRole c : MastershipRole.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static MastershipRole valueOf(java.lang.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:
java.lang.IllegalArgumentException
- if this enum type has no constant with the specified namejava.lang.NullPointerException
- if the argument is null
-
-