Package com.github.javaparser.ast.type
Enum ArrayType.Origin
- java.lang.Object
-
- java.lang.Enum<ArrayType.Origin>
-
- com.github.javaparser.ast.type.ArrayType.Origin
-
- All Implemented Interfaces:
Serializable
,Comparable<ArrayType.Origin>
- Enclosing class:
- ArrayType
public static enum ArrayType.Origin extends Enum<ArrayType.Origin>
The origin of a pair of array brackets [].
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static ArrayType.Origin
valueOf(String name)
Returns the enum constant of this type with the specified name.static ArrayType.Origin[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
NAME
public static final ArrayType.Origin NAME
The [] were found on the name, like "int a[]" or "String abc()[][]"
-
TYPE
public static final ArrayType.Origin TYPE
The [] were found on the type, like "int[] a" or "String[][] abc()"
-
-
Method Detail
-
values
public static ArrayType.Origin[] 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 (ArrayType.Origin c : ArrayType.Origin.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static ArrayType.Origin 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
-
-