class IntervalContextVar extends ContextVar implements Comparable<IntervalContextVar> {

  // The interval is [L, R), which stands for a set of consecutive contexts
  public long L = 0, R = 0;

  public IntervalContextVar() {
  }

  public IntervalContextVar(long l, long r, Node v) {
    assert l < r;
    L = l;
    R = r;
    var = v;
  }

  public IntervalContextVar(IntervalContextVar o) {
    L = o.L;
    R = o.R;
    var = o.var;
  }

  @Override
  public String toString() {<FILL_FUNCTION_BODY>}

  @Override
  public boolean equals(Object o) {
    IntervalContextVar other = (IntervalContextVar) o;
    return (other.L == L) && (other.R == R) && (other.var == var);
  }

  @Override
  public int hashCode() {
    int ch = (int) ((L + R) % Integer.MAX_VALUE);
    int ans = var.hashCode() + ch;
    if (ans < 0) {
      ans = var.hashCode();
    }
    return ans;
  }

  @Override
  public int compareTo(IntervalContextVar o) {
    if (L == o.L) {
      return R < o.R ? -1 : 1;
    }

    return L < o.L ? -1 : 1;
  }

  @Override
  public boolean contains(ContextVar cv) {
    IntervalContextVar icv = (IntervalContextVar) cv;
    if (L <= icv.L && R >= icv.R) {
      return true;
    }
    return false;
  }

  @Override
  public boolean merge(ContextVar cv) {
    IntervalContextVar icv = (IntervalContextVar) cv;

    if (icv.L < L) {
      if (L <= icv.R) {
        L = icv.L;
        if (R < icv.R) {
          R = icv.R;
        }
        return true;
      }
    } else {
      if (icv.L <= R) {
        if (R < icv.R) {
          R = icv.R;
        }
        return true;
      }
    }

    return false;
  }

  @Override
  public boolean intersect(ContextVar cv) {
    IntervalContextVar icv = (IntervalContextVar) cv;

    if ((L <= icv.L && icv.L < R) || (icv.L <= L && L < icv.R)) {
      return true;
    }
    return false;
  }
}

    return "<" + var.toString() + ", " + L + ", " + R + ">";
  
<methods>public abstract boolean contains(soot.jimple.spark.geom.dataRep.ContextVar) ,public int getNumber() ,public abstract boolean intersect(soot.jimple.spark.geom.dataRep.ContextVar) ,public abstract boolean merge(soot.jimple.spark.geom.dataRep.ContextVar) ,public void setNumber(int) <variables>public int id,public soot.jimple.spark.pag.Node var