de.upb.swt.mcie.parser.token
Class BinOp

java.lang.Object
  extended by de.upb.swt.mcie.parser.token.Token
      extended by de.upb.swt.mcie.parser.token.BinOp

public class BinOp
extends Token

Class implementing a token for a binary operation. The operations, their encoding and their binding are defined in class BinaryOp.

Author:
Ekkart Kindler, kindler@upb.de
See Also:
BinaryOp

Field Summary
private  int op
          The operation (ie its encoding according to BinaryOp).
 
Constructor Summary
BinOp(int op)
          Creates a token for the binary operation op.
 
Method Summary
 int binding()
          Returns the binding level of this binary operation.
 int getOp()
          Returns the operation (i.e. its encoding).
 
Methods inherited from class de.upb.swt.mcie.parser.token.Token
setReference, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

op

private int op
The operation (ie its encoding according to BinaryOp).

Constructor Detail

BinOp

public BinOp(int op)
Creates a token for the binary operation op.

Parameters:
op -
Method Detail

binding

public int binding()
Returns the binding level of this binary operation. The binding level of this operation is defined in class BinaryOp.

Returns:
the binding level

getOp

public int getOp()
Returns the operation (i.e. its encoding).

Returns:
the operation