jif.types

## Class Equation

- java.lang.Object
- - jif.types.Equation

- Direct Known Subclasses:
    LabelEquation, PrincipalEquation

      public abstract class Equation
      extends java.lang.Object

  Label equation derived from a label constraint. A label equation represents an inequality that must be satisfied, namely `lhs <= rhs` in the environment `env`.
  See Also:
    `LabelConstraint`

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `protected Constraint` | `constraint` The constraint from which this equation was derived.

  - ### Constructor Summary

    Constructors
    Modifier | Constructor and Description
    --- | ---
    `protected` | `Equation(Constraint constraint)`

  - ### Method Summary

    All Methods Instance Methods Abstract Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `Constraint` | `constraint()` The constraint from which this equation was derived.
    `abstract java.lang.Object` | `copy()`
    `LabelEnv` | `env()`
    `abstract boolean` | `equals(java.lang.Object o)`
    `abstract int` | `hashCode()`
    `polyglot.util.Position` | `position()`
    `abstract void` | `subst(LabelSubstitution subst)` Replace the `lhs` and `rhs` with the result of `lhs.subst(subst)` and `rhs.subst(subst)` respectively.
    `abstract java.lang.String` | `toString()`
    `abstract java.util.Set<Variable>` | `variables()` Return a `Set` of variables that occur in either the left or right hand side.

    - ### Methods inherited from class java.lang.Object

      `clone, finalize, getClass, notify, notifyAll, wait, wait, wait`

- - ### Field Detail

    - #### constraint

          protected final Constraint constraint

      The constraint from which this equation was derived.

  - ### Constructor Detail

    - #### Equation

          protected Equation(Constraint constraint)

      Parameters:
        `constraint` - the constraint from which this equation was derived.

  - ### Method Detail

    - #### env

          public LabelEnv env()

    - #### position

          public polyglot.util.Position position()

    - #### constraint

          public Constraint constraint()

      The constraint from which this equation was derived.

    - #### variables

          public abstract java.util.Set<Variable> variables()

      Return a `Set` of variables that occur in either the left or right hand side.

    - #### hashCode

          public abstract int hashCode()

      Overrides:
        `hashCode` in class `java.lang.Object`

    - #### equals

          public abstract boolean equals(java.lang.Object o)

      Overrides:
        `equals` in class `java.lang.Object`

    - #### toString

          public abstract java.lang.String toString()

      Overrides:
        `toString` in class `java.lang.Object`

    - #### subst

          public abstract void subst(LabelSubstitution subst)
                              throws polyglot.types.SemanticException

      Replace the `lhs` and `rhs` with the result of `lhs.subst(subst)` and `rhs.subst(subst)` respectively.
      Throws:
        `polyglot.types.SemanticException`

    - #### copy

          public abstract java.lang.Object copy()