Package com.javacc.parser.tree
Class CodeBlock
java.lang.Object
com.javacc.parser.BaseNode
com.javacc.core.Expansion
com.javacc.core.EmptyExpansion
com.javacc.parser.tree.CodeBlock
- All Implemented Interfaces:
JavaCCConstants,Node,Expression,freemarker.template.TemplateHashModel,freemarker.template.TemplateModel,freemarker.template.TemplateNodeModel,freemarker.template.TemplateScalarModel,Comparable<Node>
-
Nested Class Summary
Nested classes/interfaces inherited from interface com.javacc.parser.JavaCCConstants
JavaCCConstants.LexicalState, JavaCCConstants.TokenTypeNested classes/interfaces inherited from interface com.javacc.parser.Node
Node.VisitorNested classes/interfaces inherited from interface freemarker.template.TemplateModel
freemarker.template.TemplateModel.InvalidExpressionModel, freemarker.template.TemplateModel.JavaNull -
Field Summary
Fields inherited from interface com.javacc.parser.JavaCCConstants
BUF_SIZEFields inherited from interface freemarker.template.TemplateModel
INVALID_EXPRESSION, JAVA_NULL, NOTHINGFields inherited from interface freemarker.template.TemplateScalarModel
EMPTY_STRING -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanbooleanisEmpty()The block is empty if it only consists of { and }booleanvoidsetAppliesInLookahead(boolean appliesInLookahead) Methods inherited from class com.javacc.core.EmptyExpansion
getFinalSet, getFirstSet, getMaximumSize, getMinimumSize, getRequiresScanAhead, getSpecifiesLexicalStateSwitchMethods inherited from class com.javacc.core.Expansion
beginsSequence, getContainingProduction, getCustomErrorRecoveryBlock, getFinalSetSize, getFinalSetVarName, getFirstSetVarName, getFollowingExpansion, getFollowSet, getFollowSetVarName, getHasExplicitLookahead, getHasExplicitNumericalLookahead, getHasFullFollowSet, getHasGlobalSemanticActions, getHasImplicitSyntacticLookahead, getHasInnerScanLimit, getHasLookBehind, getHasScanLimit, getHasSemanticLookahead, getHasSeparateSyntacticLookahead, getHasTokenActivation, getIndex, getIsRegexp, getLabel, getLookahead, getLookaheadAmount, getLookaheadExpansion, getLookBehind, getNestedExpansion, getNonSuperfluousParent, getPredicateMethodName, getRecoverMethodName, getRecoverToMethodName, getRequiresPredicateMethod, getRequiresRecoverMethod, getScanLimitPlus, getScanRoutineName, getSemanticLookahead, getSpecifiedLexicalState, getTokenActivation, getTreeNodeBehavior, getUpToExpansion, isAlwaysSuccessful, isAtChoicePoint, isBeforeLexicalStateSwitch, isInsideLookahead, isNegated, isScanLimit, isSingleToken, isTolerantParsing, setCustomErrorRecoveryBlock, setLabel, setScanLimit, setScanLimitPlus, setTolerantParsing, setTreeNodeBehavior, superfluousParentheses, toStringMethods inherited from class com.javacc.parser.BaseNode
addChild, addChild, children, clearChildren, get, getBeginOffset, getChild, getChildCount, getChildNodes, getEndOffset, getGrammar, getInnerText, getLiteralText, getNodeName, getNodeNamespace, getNodeType, getParent, getParentNode, getSimpleName, getTokenSource, hasKeyWord, isUnparsed, prepend, removeChild, setBeginOffset, setChild, setEndOffset, setGrammar, setListClass, setParent, setTokenSource, setUnparsedMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface com.javacc.parser.tree.Expression
isAssignableToMethods inherited from interface com.javacc.parser.Node
addChild, addChild, appendChild, children, children, childrenOfType, clearChildren, close, compareTo, copyLocationInfo, copyLocationInfo, descendants, descendants, descendants, descendants, descendantsOfType, dump, dump, firstAncestorOfType, firstChildOfType, firstChildOfType, firstChildOfType, firstDescendantOfType, firstDescendantOfType, getAllTokens, getBeginColumn, getBeginLine, getBeginOffset, getChild, getChildCount, getEndColumn, getEndLine, getEndOffset, getFirstChild, getFirstToken, getGrammar, getInputSource, getLastChild, getLastToken, getLocation, getParent, getRealTokens, getRoot, getSource, getTokenSource, getTokenType, hasChildNodes, indexOf, isUnparsed, iterator, nextSibling, open, prependChild, previousSibling, removeChild, removeChild, replace, replaceChild, setBeginOffset, setChild, setEndOffset, setGrammar, setParent, setTokenSource, setUnparsedMethods inherited from interface freemarker.template.TemplateNodeModel
getChildNodes, getNodeName, getNodeNamespace, getNodeType, getParentNode
-
Constructor Details
-
CodeBlock
public CodeBlock()
-
-
Method Details
-
getAsString
- Specified by:
getAsStringin interfaceExpression- Specified by:
getAsStringin interfacefreemarker.template.TemplateScalarModel- Overrides:
getAsStringin classBaseNode
-
isEmpty
public boolean isEmpty()The block is empty if it only consists of { and } -
isAppliesInLookahead
public boolean isAppliesInLookahead() -
setAppliesInLookahead
public void setAppliesInLookahead(boolean appliesInLookahead) -
getJavaCode
-
isPossiblyEmpty
public boolean isPossiblyEmpty()- Overrides:
isPossiblyEmptyin classEmptyExpansion- Returns:
- Can this expansion be matched by the empty string.
-