public enum GroupCapability extends Enum<GroupCapability> implements OfpBitmapEnum
Enum Constant and Description |
---|
CHAINING
Support chaining groups; Since 1.2.
|
CHAINING_CHECKS
Check chaining for loops and delete; Since 1.2.
|
SELECT_LIVENESS
Support liveness for select groups; Since 1.2.
|
SELECT_WEIGHT
Support weight for select groups; Since 1.2.
|
Modifier and Type | Method and Description |
---|---|
static Set<GroupCapability> |
decodeBitmap(int bitmap,
ProtocolVersion pv)
Decodes the group capabilities flags and returns the set of
corresponding constants.
|
static int |
encodeBitmap(Set<GroupCapability> flags,
ProtocolVersion pv)
Encodes a set of group capabilities flags as a bitmap.
|
int |
getBit(ProtocolVersion pv)
Returns the bit value for the constant, under the given protocol
version.
|
String |
toDisplayString()
Returns a string representation of the constant, suitable for
presentation in a display.
|
String |
toString() |
static GroupCapability |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static GroupCapability[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final GroupCapability SELECT_WEIGHT
public static final GroupCapability SELECT_LIVENESS
public static final GroupCapability CHAINING
public static final GroupCapability CHAINING_CHECKS
public static GroupCapability[] values()
for (GroupCapability c : GroupCapability.values()) System.out.println(c);
public static GroupCapability valueOf(String name)
name
- the name of the enum constant to be returned.IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is nullpublic int getBit(ProtocolVersion pv)
OfpBitmapEnum
getBit
in interface OfpBitmapEnum
pv
- the protocol versionpublic String toString()
toString
in class Enum<GroupCapability>
public String toDisplayString()
OfpBitmapEnum
toDisplayString
in interface OfpBitmapEnum
public static Set<GroupCapability> decodeBitmap(int bitmap, ProtocolVersion pv)
bitmap
- the bitmap to decodepv
- the protocol versionVersionMismatchException
- if a bit position is not supported
in the given versionpublic static int encodeBitmap(Set<GroupCapability> flags, ProtocolVersion pv)
flags
parameter may be null, in which case a bitmap of 0 (zero) is returned.flags
- the flags to encodepv
- the protocol versionNullPointerException
- if protocol version is nullVersionMismatchException
- if a flag is present that is not
supported in the given protocol versionCopyright © 2015. All Rights Reserved.