net.sf.magicproject.operation
Class Dummy

java.lang.Object
  extended by net.sf.magicproject.operation.Operation
      extended by net.sf.magicproject.operation.Dummy

public final class Dummy
extends Operation

No standard expression is associated to this operation. Special expression such as BitCount are plugged in this operation.

Since:
0.83
Author:
Fabrice Daugan

Method Summary
static Dummy getInstance()
          Return the unique instance of this operation.
 java.lang.String getOperator()
          Return operator name
 int process(int leftValue, int rightValue)
          Process a binary operation with two values and return the result.
 Expression readNextExpression(java.io.InputStream inputFile)
          return the next Expression read from the current offset
 Expression readNextExpression(int idExpression, java.io.InputStream inputFile)
          return the next Expression read from the current offset
 
Methods inherited from class net.sf.magicproject.operation.Operation
isUselessWith
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

readNextExpression

public Expression readNextExpression(java.io.InputStream inputFile)
Description copied from class: Operation
return the next Expression read from the current offset

Specified by:
readNextExpression in class Operation
Parameters:
inputFile - is the file containing this expression
Returns:
the next Expression read from the current offset

getOperator

public java.lang.String getOperator()
Return operator name

Specified by:
getOperator in class Operation
Returns:
the operator name

process

public int process(int leftValue,
                   int rightValue)
Description copied from class: Operation
Process a binary operation with two values and return the result.

Specified by:
process in class Operation
Parameters:
leftValue - the left value of binary operation
rightValue - the right value of binary operation
Returns:
the result

readNextExpression

public Expression readNextExpression(int idExpression,
                                     java.io.InputStream inputFile)
                              throws java.io.IOException
return the next Expression read from the current offset

Parameters:
idExpression - expression type
inputFile - is the file containing this expression
Returns:
the next Expression read from the current offset
Throws:
java.io.IOException - if error occurred during the reading process from the specified input stream

getInstance

public static Dummy getInstance()
Return the unique instance of this operation.

Returns:
the unique instance of this operation.


Copyright © 2003-2007 Magic-Project. All Rights Reserved.