Interface IASTBinaryExpression

    • Method Detail

      • setOperator

        void setOperator​(int op)
        Sets the operator.
        Parameters:
        op - value to set.
      • getOperator

        int getOperator()
        Returns the operator.
        Returns:
        int value as operator
      • getOperand1

        IASTExpression getOperand1()
        Get the first operand.
        Returns:
        IASTExpression representing operand 1.
      • setOperand1

        void setOperand1​(IASTExpression expression)
        Set the first operand.
        Parameters:
        expression - IASTExpression value.
      • getOperand2

        IASTExpression getOperand2()
        Get the second operand.
        Returns:
        IASTExpression representing operand 2.
      • getInitOperand2

        IASTInitializerClause getInitOperand2()
        Returns the second operand of the expression. For c++ assignment expressions this can be a braced list initializer.
        Since:
        5.2
      • setOperand2

        void setOperand2​(IASTExpression expression)
        Parameters:
        expression - IASTExpression value
      • copy

        IASTBinaryExpression copy()
        Description copied from interface: IASTNode
        Returns a mutable copy of the tree rooted at this node. The following postconditions hold:
         copy.getParent() == null
         copy.getPropertyInParent() == null
         copy.isFrozen() == false
         
        Preprocessor nodes do not currently support being copied. Implicit name nodes are not copied, instead they can be regenerated if required.

        Calling this method is equivalent to copy(CopyStyle.withoutLocations).

        Specified by:
        copy in interface IASTExpression
        Specified by:
        copy in interface IASTInitializerClause
        Specified by:
        copy in interface IASTNode
        Since:
        5.1
      • copy

        IASTBinaryExpression copy​(IASTNode.CopyStyle style)
        Description copied from interface: IASTNode
        Returns a mutable copy of the tree rooted at this node. The following postconditions hold:
         copy.getParent() == null
         copy.getPropertyInParent() == null
         copy.isFrozen() == false
         
        Preprocessor nodes do not currently support being copied. Implicit name nodes are not copied, instead they can be regenerated if required.
        Specified by:
        copy in interface IASTExpression
        Specified by:
        copy in interface IASTInitializerClause
        Specified by:
        copy in interface IASTNode
        Parameters:
        style - IASTNode.CopyStyle create a copy with or without locations. Please see IASTNode.CopyStyle for restrictions on copies with Locations.
        Since:
        5.3