类 SemanticContext.CommutativePredicate
- java.lang.Object
-
- org.antlr.analysis.SemanticContext
-
- org.antlr.analysis.SemanticContext.CommutativePredicate
-
- 直接已知子类:
SemanticContext.AND
,SemanticContext.OR
- 封闭类:
- SemanticContext
public abstract static class SemanticContext.CommutativePredicate extends SemanticContext
-
-
字段概要
字段 修饰符和类型 字段 说明 protected int
hashcode
protected java.util.Set<SemanticContext>
operands
-
从类继承的字段 org.antlr.analysis.SemanticContext
EMPTY_SEMANTIC_CONTEXT
-
-
构造器概要
构造器 构造器 说明 CommutativePredicate(java.util.HashSet<SemanticContext> contexts)
CommutativePredicate(SemanticContext a, SemanticContext b)
-
方法概要
所有方法 实例方法 抽象方法 具体方法 修饰符和类型 方法 说明 abstract int
calculateHashCode()
abstract SemanticContext
combinePredicates(SemanticContext left, SemanticContext right)
boolean
equals(java.lang.Object obj)
SemanticContext
getGatedPredicateContext()
Given a semantic context expression tree, return a tree with all nongated predicates set to true and then reduced.abstract java.lang.String
getOperandString()
int
hashCode()
boolean
hasUserSemanticPredicate()
boolean
isSyntacticPredicate()
java.lang.String
toString()
void
trackUseOfSyntacticPredicates(Grammar g)
Notify the indicated grammar of any syn preds used within this context-
从类继承的方法 org.antlr.analysis.SemanticContext
and, factorAnd, factorOr, genExpr, getAndOperands, getOrOperands, not, or
-
-
-
-
字段详细资料
-
operands
protected final java.util.Set<SemanticContext> operands
-
hashcode
protected int hashcode
-
-
构造器详细资料
-
CommutativePredicate
public CommutativePredicate(SemanticContext a, SemanticContext b)
-
CommutativePredicate
public CommutativePredicate(java.util.HashSet<SemanticContext> contexts)
-
-
方法详细资料
-
getGatedPredicateContext
public SemanticContext getGatedPredicateContext()
从类复制的说明:SemanticContext
Given a semantic context expression tree, return a tree with all nongated predicates set to true and then reduced. So p&&(q||r) would return p&&r if q is nongated but p and r are gated.- 指定者:
getGatedPredicateContext
在类中SemanticContext
-
hasUserSemanticPredicate
public boolean hasUserSemanticPredicate()
- 指定者:
hasUserSemanticPredicate
在类中SemanticContext
-
isSyntacticPredicate
public boolean isSyntacticPredicate()
- 指定者:
isSyntacticPredicate
在类中SemanticContext
-
trackUseOfSyntacticPredicates
public void trackUseOfSyntacticPredicates(Grammar g)
从类复制的说明:SemanticContext
Notify the indicated grammar of any syn preds used within this context
-
equals
public boolean equals(java.lang.Object obj)
- 覆盖:
equals
在类中java.lang.Object
-
hashCode
public int hashCode()
- 覆盖:
hashCode
在类中java.lang.Object
-
toString
public java.lang.String toString()
- 覆盖:
toString
在类中java.lang.Object
-
getOperandString
public abstract java.lang.String getOperandString()
-
combinePredicates
public abstract SemanticContext combinePredicates(SemanticContext left, SemanticContext right)
-
calculateHashCode
public abstract int calculateHashCode()
-
-