Package com.blackrook.archetext
Enum Combinator
- java.lang.Object
-
- java.lang.Enum<Combinator>
-
- com.blackrook.archetext.Combinator
-
- All Implemented Interfaces:
Serializable
,Comparable<Combinator>
public enum Combinator extends Enum<Combinator>
ArcheText object internal accumulation types.
-
-
Enum Constant Summary
Enum Constants Enum Constant Description ADD
BITWISEAND
BITWISEOR
BITWISEXOR
DIVISION
LEFTSHIFT
MODULO
MULTIPLY
POWER
RIGHTPADDINGSHIFT
RIGHTSHIFT
SET
SUBTRACT
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description abstract ArcheTextValue
combine(ArcheTextValue operand, ArcheTextValue source)
Combines two values.String
getAssignmentOperator()
static Combinator
valueOf(String name)
Returns the enum constant of this type with the specified name.static Combinator[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
SET
public static final Combinator SET
-
ADD
public static final Combinator ADD
-
SUBTRACT
public static final Combinator SUBTRACT
-
MULTIPLY
public static final Combinator MULTIPLY
-
DIVISION
public static final Combinator DIVISION
-
MODULO
public static final Combinator MODULO
-
POWER
public static final Combinator POWER
-
BITWISEAND
public static final Combinator BITWISEAND
-
BITWISEOR
public static final Combinator BITWISEOR
-
BITWISEXOR
public static final Combinator BITWISEXOR
-
LEFTSHIFT
public static final Combinator LEFTSHIFT
-
RIGHTSHIFT
public static final Combinator RIGHTSHIFT
-
RIGHTPADDINGSHIFT
public static final Combinator RIGHTPADDINGSHIFT
-
-
Method Detail
-
values
public static Combinator[] 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 (Combinator c : Combinator.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static Combinator 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
-
getAssignmentOperator
public String getAssignmentOperator()
- Returns:
- the assignment operator for this combinator.
-
combine
public abstract ArcheTextValue combine(ArcheTextValue operand, ArcheTextValue source)
Combines two values.- Parameters:
operand
- the incoming value.source
- the source value that this is combining with.- Returns:
- the resultant value.
- Throws:
NullPointerException
- if source or operand is null. If source or operand is supposed to be null, useArcheTextValue.NULL
.
-
-