mmp.engine
Enum Macro.Style

java.lang.Object
  extended by java.lang.Enum<Macro.Style>
      extended by mmp.engine.Macro.Style
All Implemented Interfaces:
java.io.Serializable, java.lang.Comparable<Macro.Style>
Enclosing class:
Macro

public static enum Macro.Style
extends java.lang.Enum<Macro.Style>

Enumeration classifying whether the macro needs parenthesis to be recognized as a macro.


Enum Constant Summary
DOES_NOT_NEED_PARENTHESIS
          The macro does not need parenthesis to be recognized as a macro.
NEEDS_PARENTHESIS
          The macro needs parenthesis to be recognized as a macro, e.g.
 
Method Summary
static Macro.Style valueOf(java.lang.String name)
          Returns the enum constant of this type with the specified name.
static Macro.Style[] values()
          Returns an array containing the constants of this enum type, in the order they are declared.
 
Methods inherited from class java.lang.Enum
compareTo, equals, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Enum Constant Detail

DOES_NOT_NEED_PARENTHESIS

public static final Macro.Style DOES_NOT_NEED_PARENTHESIS
The macro does not need parenthesis to be recognized as a macro. This is always the case with user defined macros, e.g. if 'foo' is defined to expand to 'bar' the string 'foo' will be recognized as a macro an processed by the engine.


NEEDS_PARENTHESIS

public static final Macro.Style NEEDS_PARENTHESIS
The macro needs parenthesis to be recognized as a macro, e.g. 'define(`foo',`bar')' will be processed as a macro, whereas 'define' will written to output without being processed by the macro processing engine.

Method Detail

valueOf

public static Macro.Style 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 name
java.lang.NullPointerException - if the argument is null

values

public static Macro.Style[] 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 (Macro.Style c : Macro.Style.values())
    System.out.println(c);

Returns:
an array containing the constants of this enum type, in the order they are declared