|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object jif.types.Constraint
public abstract class Constraint
A Constraint
is the superclass of label
constraints and principals constraints, which
are generated during type checking and label checking.
Nested Class Summary | |
---|---|
static class |
Constraint.Kind
Kinds of constraint, either equality or inequality. |
Field Summary | |
---|---|
protected LabelEnv |
env
The environment under which this constraint needs to be satisfied. |
protected Constraint.Kind |
kind
|
protected Param |
lhs
|
protected ConstraintMessage |
messages
Error messages |
protected polyglot.util.Position |
pos
|
protected boolean |
report
Do we want to report a violation of this constraint, or report the error for a different constraint? |
protected Param |
rhs
|
Constructor Summary | |
---|---|
Constraint(Param lhs,
Constraint.Kind kind,
Param rhs,
LabelEnv env,
polyglot.util.Position pos,
ConstraintMessage msg,
boolean report)
|
Method Summary | |
---|---|
java.lang.String |
detailMsg()
A detailed message to display if this constraint is violated. |
LabelEnv |
env()
|
abstract java.util.Collection |
getEquations()
Produce a Collection of Equations for this
constraint. |
abstract boolean |
hasVariables()
|
boolean |
isCanonical()
|
Constraint.Kind |
kind()
|
ConstraintMessage |
messages()
|
java.lang.String |
msg()
A message to display if this constraint is violated. |
polyglot.util.Position |
position()
|
boolean |
report()
|
java.lang.String |
technicalMsg()
A technical message to display if this constraint is violated. |
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
protected final Param lhs
protected final Param rhs
protected final Constraint.Kind kind
protected final LabelEnv env
protected final polyglot.util.Position pos
protected final ConstraintMessage messages
protected final boolean report
Constructor Detail |
---|
public Constraint(Param lhs, Constraint.Kind kind, Param rhs, LabelEnv env, polyglot.util.Position pos, ConstraintMessage msg, boolean report)
Method Detail |
---|
public Constraint.Kind kind()
public LabelEnv env()
public polyglot.util.Position position()
public boolean report()
public ConstraintMessage messages()
public java.lang.String msg()
NamedLabel
s.
public java.lang.String detailMsg()
NamedLabel
s are used.
public java.lang.String technicalMsg()
NamedLabel
s are used.
public java.lang.String toString()
toString
in class java.lang.Object
public abstract java.util.Collection getEquations()
Collection
of Equations
for this
constraint.
public boolean isCanonical()
public abstract boolean hasVariables()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |