com.togethersoft.sca.ast
Interface AstBinaryExpression

All Superinterfaces:
AstExpression, AstObject

public interface AstBinaryExpression
extends AstExpression

Represents a two operand expression. For example:

 
     int i = size * 2;
     int b = mask & 0x80;
 


Field Summary
static int BAND
          Constant representing an integer bitwise & expression.
static int BOR
          Constant representing an integer bitwise | expression.
static int BSR
          Constant representing an unsigned right shift >>> expression.
static int BXOR
          Constant representing an integer bitwise ^ expression.
static int DIV
          Constant representing a division / expression.
static int EQ
          Constant representing a == eqiality expression.
static int GE
          Constant representing a >= relational expression.
static int GT
          Constant representing a > relational expression.
static int INSTANCEOF
          Constant representing a type comparison instanceof expression.
static int LAND
          Constant representing a conditional-and && expression.
static int LE
          Constant representing a <= relational expression.
static int LOR
          Constant representing a conditional-or || expression.
static int LT
          Constant representing a < relational expression.
static int MINUS
          Constant representing a binary - expression.
static int MOD
          Constant representing a remainder % expression.
static int MUL
          Constant representing a multiplication * expression.
static int NE
          Constant representing a != equality expression.
static int PLUS
          Constant representing a binary + expression.
static int SL
          Constant representing a left shift << expression.
static int SR
          Constant representing a signed right shift >> expression.
 
Fields inherited from interface com.togethersoft.sca.ast.AstObject
ARRAY_CREATION, ARRAY_INITIALIZER, ARRAY_REFERENCE, ASSERT_STATEMENT, ASSIGNMENT_EXPRESSION, BINARY_EXPRESSION, BREAK_STATEMENT, CASE_LABEL, CAST_EXPRESSION, CATCH_CLAUSE, CLASS_FILE, COMMENT, COMPILATION_UNIT, COMPOUND_STATEMENT, CONDITIONAL_EXPRESSION, CONSTRUCTOR_INVOCATION, CONTINUE_STATEMENT, DBC_RESULT, DECLARATION_STATEMENT, DO_STATEMENT, EMPTY_STATEMENT, EXPRESSION_STATEMENT, FIELD_REFERENCE, FINALLY_CLAUSE, FOR_STATEMENT, IF_STATEMENT, IMPORT, INITIALIZER, JAVADOC_TAG, LITERAL, METHOD, METHOD_CALL_EXPRESSION, N_A, OBJECT_CREATION_EXPRESSION, PACKAGE, PARENTHESIZED_EXPRESSION, RETURN_STATEMENT, SIMPLE_REFERENCE, SUPER_EXPRESSION, SWITCH_GROUP, SWITCH_STATEMENT, SYNCHRONIZED_STATEMENT, THIS_EXPRESSION, THROW_SPECIFIER, THROW_STATEMENT, TRY_STATEMENT, TYPE, TYPE_EXPRESSION, UNARY_EXPRESSION, VARIABLE, VARIABLE_DECLARATION, WHILE_STATEMENT
 
Method Summary
 int getExpressionKind()
          Returns this expression's kind, encoded as an integer.
 AstExpression getLeftOperand()
          Returns the left operand of this expression.
 AstExpression getRightOperand()
          Returns the right operand of this expression.
 
Methods inherited from interface com.togethersoft.sca.ast.AstExpression
getOperands, getRuntimeType, getType, isConstant
 
Methods inherited from interface com.togethersoft.sca.ast.AstObject
addComment, getChildren, getComments, getCompilationUnit, getDeclaringMethod, getDeclaringType, getObjectKind, getPackage, getParent, getPosition, isDeleted, remove, replaceWith, replaceWith, setPosition, setPositionAfter, visitExpressions, visitStatements
 

Field Detail

BAND

public static final int BAND
Constant representing an integer bitwise & expression.

BOR

public static final int BOR
Constant representing an integer bitwise | expression.

BSR

public static final int BSR
Constant representing an unsigned right shift >>> expression.

BXOR

public static final int BXOR
Constant representing an integer bitwise ^ expression.

DIV

public static final int DIV
Constant representing a division / expression.

EQ

public static final int EQ
Constant representing a == eqiality expression.

GE

public static final int GE
Constant representing a >= relational expression.

GT

public static final int GT
Constant representing a > relational expression.

INSTANCEOF

public static final int INSTANCEOF
Constant representing a type comparison instanceof expression.

LAND

public static final int LAND
Constant representing a conditional-and && expression.

LE

public static final int LE
Constant representing a <= relational expression.

LOR

public static final int LOR
Constant representing a conditional-or || expression.

LT

public static final int LT
Constant representing a < relational expression.

MINUS

public static final int MINUS
Constant representing a binary - expression.

MOD

public static final int MOD
Constant representing a remainder % expression.

MUL

public static final int MUL
Constant representing a multiplication * expression.

NE

public static final int NE
Constant representing a != equality expression.

PLUS

public static final int PLUS
Constant representing a binary + expression.

SL

public static final int SL
Constant representing a left shift << expression.

SR

public static final int SR
Constant representing a signed right shift >> expression.
Method Detail

getExpressionKind

public int getExpressionKind()
Returns this expression's kind, encoded as an integer.
Returns:
the kind of this expression.

getLeftOperand

public AstExpression getLeftOperand()
Returns the left operand of this expression.
Returns:
the left operand.

getRightOperand

public AstExpression getRightOperand()
Returns the right operand of this expression.
Returns:
the right operand.