Package com.sonar.sslr.api
Interface AstNodeSkippingPolicy
-
- All Superinterfaces:
AstNodeType
- All Known Implementing Classes:
AlwaysSkipFromAst
,MutableParsingRule
,NeverSkipFromAst
,RuleDefinition
,SkipFromAstIfOnlyOneChild
public interface AstNodeSkippingPolicy extends AstNodeType
Specific Ast node types that can tell whether they should be skipped from being attached to the AST or not.- See Also:
AstVisitor
,Grammar
,AstNode
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description boolean
hasToBeSkippedFromAst(AstNode node)
Some AstNode can be pretty useless and makes a global AST less readable.
-
-
-
Method Detail
-
hasToBeSkippedFromAst
boolean hasToBeSkippedFromAst(AstNode node)
Some AstNode can be pretty useless and makes a global AST less readable. This method allows to automatically remove those AstNode from the AST.- Parameters:
node
- the node that should or not be removed from the AST- Returns:
- true if AstNode with this type must be skipped from the AST.
-
-