Class Expr.Or

  • Enclosing class:
    Expr

    public static class Expr.Or
    extends Expr.BinOp
    Class representing or-expressions.
    • Constructor Detail

      • Or

        public Or​(Expr left,
                  Expr right)
        Constructor initializing left and right subexpressions.
        Parameters:
        left - the left subexpression
        right - the right subexpression
    • Method Detail

      • getOp

        protected String getOp()
        Returns " || " as string for the operator.
        Specified by:
        getOp in class Expr.BinOp
        Returns:
        " || "
      • accept

        public <R> R accept​(Visitor<R> v)
        Accepts a visitor by calling the Visitor.visitOr(Or) method.
        Specified by:
        accept in class Expr
        Type Parameters:
        R - the type of the return value of the visitor.
        Parameters:
        v - the visitor
        Returns:
        the return value