Package org.antlr.analysis
Class SemanticContext.OR
- java.lang.Object
-
- org.antlr.analysis.SemanticContext
-
- org.antlr.analysis.SemanticContext.CommutativePredicate
-
- org.antlr.analysis.SemanticContext.OR
-
- Enclosing class:
- SemanticContext
public static class SemanticContext.OR extends SemanticContext.CommutativePredicate
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.antlr.analysis.SemanticContext
SemanticContext.AND, SemanticContext.CommutativePredicate, SemanticContext.FalsePredicate, SemanticContext.NOT, SemanticContext.OR, SemanticContext.Predicate, SemanticContext.TruePredicate
-
-
Field Summary
-
Fields inherited from class org.antlr.analysis.SemanticContext.CommutativePredicate
hashcode, operands
-
Fields inherited from class org.antlr.analysis.SemanticContext
EMPTY_SEMANTIC_CONTEXT
-
-
Constructor Summary
Constructors Constructor Description OR(java.util.HashSet<SemanticContext> contexts)OR(SemanticContext a, SemanticContext b)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description intcalculateHashCode()SemanticContextcombinePredicates(SemanticContext left, SemanticContext right)org.stringtemplate.v4.STgenExpr(CodeGenerator generator, org.stringtemplate.v4.STGroup templates, DFA dfa)Generate an expression that will evaluate the semantic context, given a set of output templates.java.lang.StringgetOperandString()-
Methods inherited from class org.antlr.analysis.SemanticContext.CommutativePredicate
equals, getGatedPredicateContext, hashCode, hasUserSemanticPredicate, isSyntacticPredicate, toString, trackUseOfSyntacticPredicates
-
Methods inherited from class org.antlr.analysis.SemanticContext
and, factorAnd, factorOr, getAndOperands, getOrOperands, not, or
-
-
-
-
Constructor Detail
-
OR
public OR(SemanticContext a, SemanticContext b)
-
OR
public OR(java.util.HashSet<SemanticContext> contexts)
-
-
Method Detail
-
genExpr
public org.stringtemplate.v4.ST genExpr(CodeGenerator generator, org.stringtemplate.v4.STGroup templates, DFA dfa)
Description copied from class:SemanticContextGenerate an expression that will evaluate the semantic context, given a set of output templates.- Specified by:
genExprin classSemanticContext
-
getOperandString
public java.lang.String getOperandString()
- Specified by:
getOperandStringin classSemanticContext.CommutativePredicate
-
combinePredicates
public SemanticContext combinePredicates(SemanticContext left, SemanticContext right)
- Specified by:
combinePredicatesin classSemanticContext.CommutativePredicate
-
calculateHashCode
public int calculateHashCode()
- Specified by:
calculateHashCodein classSemanticContext.CommutativePredicate
-
-