Package org.onosproject.vpls.cli
Enum VplsCommandEnum
- java.lang.Object
-
- java.lang.Enum<VplsCommandEnum>
-
- org.onosproject.vpls.cli.VplsCommandEnum
-
- All Implemented Interfaces:
Serializable,Comparable<VplsCommandEnum>
public enum VplsCommandEnum extends Enum<VplsCommandEnum>
Enum representing the VPLS command type.
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static VplsCommandEnumenumFromString(String command)Alternative method to valueOf.StringtoString()static List<String>toStringList()Returns a list of command string values.static VplsCommandEnumvalueOf(String name)Returns the enum constant of this type with the specified name.static VplsCommandEnum[]values()Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
ADD_IFACE
public static final VplsCommandEnum ADD_IFACE
-
CREATE
public static final VplsCommandEnum CREATE
-
DELETE
public static final VplsCommandEnum DELETE
-
LIST
public static final VplsCommandEnum LIST
-
REMOVE_IFACE
public static final VplsCommandEnum REMOVE_IFACE
-
SET_ENCAP
public static final VplsCommandEnum SET_ENCAP
-
SHOW
public static final VplsCommandEnum SHOW
-
CLEAN
public static final VplsCommandEnum CLEAN
-
-
Method Detail
-
values
public static VplsCommandEnum[] 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 (VplsCommandEnum c : VplsCommandEnum.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static VplsCommandEnum 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
-
toString
public String toString()
- Overrides:
toStringin classEnum<VplsCommandEnum>
-
toStringList
public static List<String> toStringList()
Returns a list of command string values.- Returns:
- the list of string values corresponding to the enums
-
enumFromString
public static VplsCommandEnum enumFromString(String command)
Alternative method to valueOf. It returns the command type corresponding to the given string. If the parameter does not match a constant name, or is null, null is returned.- Parameters:
command- the string representing the encapsulation type- Returns:
- the EncapsulationType constant corresponding to the string given
-
-