public abstract class AbstractDirectiveHandler
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
DIRECTIVE_PREFIX
The common preprocessor prefix for all directives
|
static AbstractDirectiveHandler[] |
DIRECTIVES
The array contains all directives of the preprocessor
|
static AbstractDirectiveHandler[] |
GLOBAL_DIRECTIVES
The array contains preprocessor directives active only during the global
preprocessing phase
|
static java.lang.String |
ONE_LINE_COMMENT
The prefix for one line comment
|
static java.lang.String |
PREFIX_FOR_KEEPING_LINES
The prefix for lines to be kept by preprocessor
|
static java.lang.String |
PREFIX_FOR_KEEPING_LINES_PROCESSED_DIRECTIVES
The prefix for lines to be kept by preprocessor, which contain processed
directives
|
Constructor and Description |
---|
AbstractDirectiveHandler() |
Modifier and Type | Method and Description |
---|---|
abstract AfterDirectiveProcessingBehaviour |
execute(java.lang.String tailString,
PreprocessorContext context)
Execute directive
|
boolean |
executeOnlyWhenExecutionAllowed()
Shows that the directive can be executed only when the preprocessing n
active state i.e.
|
DirectiveArgumentType |
getArgumentType()
Get the argument type needed by the directive
|
java.lang.String |
getFullName()
Get the directive name with prefix
|
abstract java.lang.String |
getName()
Get the name of the directive without prefix
|
abstract java.lang.String |
getReference()
Get the directive reference, it will be printed for a help request
|
boolean |
isDeprecated()
Check that the directive is deprecated one and can be removed in a next release
|
boolean |
isGlobalPhaseAllowed()
Shows that the directive can be executed during a global preprocessing
phase
|
boolean |
isPreprocessingPhaseAllowed()
Shows that the directive can be executed during the second preprocessing
phase
|
public static final java.lang.String DIRECTIVE_PREFIX
public static final java.lang.String PREFIX_FOR_KEEPING_LINES
public static final java.lang.String PREFIX_FOR_KEEPING_LINES_PROCESSED_DIRECTIVES
public static final java.lang.String ONE_LINE_COMMENT
public static final AbstractDirectiveHandler[] DIRECTIVES
public static final AbstractDirectiveHandler[] GLOBAL_DIRECTIVES
public abstract java.lang.String getName()
public abstract java.lang.String getReference()
public java.lang.String getFullName()
public DirectiveArgumentType getArgumentType()
public abstract AfterDirectiveProcessingBehaviour execute(java.lang.String tailString, PreprocessorContext context)
tailString
- the tail of the string where the directive has been met, must not be null but can be emptycontext
- the preprocessor context, it can be nullpublic boolean executeOnlyWhenExecutionAllowed()
public boolean isGlobalPhaseAllowed()
public boolean isPreprocessingPhaseAllowed()
public boolean isDeprecated()