public class CalculatorEventProcessor extends java.lang.Object implements ICalculatorEventListener
Constructor and Description |
---|
CalculatorEventProcessor(java.lang.String tableID,
IValidationChecker validationChecker)
Instantiates a new calculator event processor.
|
Modifier and Type | Method and Description |
---|---|
void |
calculatorDragAndDropEvent(Calculator calculator,
IItem itemDropped,
IItem onto,
int indexOfDrop)
Calculator drag and drop event.
|
void |
characterAdded(char character,
Calculator calculator,
java.lang.String currentDisplay)
Character added.
|
void |
characterRemoved(Calculator calculator,
java.lang.String text)
Character removed.
|
void |
enterKeyPressed(Calculator calculator,
java.lang.String currentDisplay)
Enter key pressed.
|
void |
setExpressionSession(ExpressionSession session)
Sets the expression session.
|
public CalculatorEventProcessor(java.lang.String tableID, IValidationChecker validationChecker)
tableID
- the table idvalidationChecker
- the validation checkerpublic void calculatorDragAndDropEvent(Calculator calculator, IItem itemDropped, IItem onto, int indexOfDrop)
calculator
- the calculatoritemDropped
- the item droppedonto
- the ontoindexOfDrop
- the index of droppublic void characterAdded(char character, Calculator calculator, java.lang.String currentDisplay)
ICalculatorEventListener
characterAdded
in interface ICalculatorEventListener
character
- the charactercalculator
- the calculatorcurrentDisplay
- the current displaypublic void characterRemoved(Calculator calculator, java.lang.String text)
ICalculatorEventListener
characterRemoved
in interface ICalculatorEventListener
calculator
- the calculatortext
- the textpublic void enterKeyPressed(Calculator calculator, java.lang.String currentDisplay)
ICalculatorEventListener
enterKeyPressed
in interface ICalculatorEventListener
calculator
- the calculatorcurrentDisplay
- the current displaypublic void setExpressionSession(ExpressionSession session)
session
- the new expression session