fr.ove.openmath.jome.ctrl.linear.events
Class LinearParserEvent

java.lang.Object
  extended byjava.util.EventObject
      extended byfr.ove.openmath.jome.ctrl.linear.events.LinearParserEvent
All Implemented Interfaces:
java.io.Serializable

public class LinearParserEvent
extends java.util.EventObject

The event sent during the parsing of a linear form of an expression.
Each event sent corresponds to token in the expression parsed. The tokens are the following :

There exists other token identifiers : Finally, 2 other token identifiers dealing with the parsing itself.

Version:
1.0 27/09/1999
Author:
© 1999 DIRAT Laurent
See Also:
Serialized Form

Field Summary
static int ADDITION
           
static int CLOSE_BRACKET
           
static int CLOSE_CURLY
           
static int CLOSE_PAREN
           
static int DIVISION
           
static int END_EXPRESSION
           
static int EQUAL
           
static int FLOAT
           
static int FUNCTION
           
static int FUNCTION2
           
static int GREATER
           
static int GREATEREQUAL
           
static int GROUP_END
           
static int GROUP_START
           
static int INTEGER
           
static int LESS
           
static int LESSEQUAL
           
static int MULTIPLICATION
           
static int OPEN_BRACKET
           
static int OPEN_CURLY
           
static int OPEN_PAREN
           
static int POWER
           
static int RESERVED
           
static int SEPARATOR
           
static int SPECIALIZED
           
static int START_EXPRESSION
           
static int SUBSTRACTION
           
static int SYMBOL
           
static int UNDERSCRIPT
           
static int UNEQUAL
           
static int VARIABLE
          The different command tokens.
 
Fields inherited from class java.util.EventObject
source
 
Constructor Summary
LinearParserEvent(java.lang.Object src)
          The constructor.
 
Method Summary
 int getIdentifier()
          Returns the identifier of the token wrapped into the event.
 java.lang.String getIdentifierAsString()
          Returns the identifier of the token wrapped into the event, as a string
static int getStringIdentifierAsInt(java.lang.String identifier)
          Returns the int value of the specified identifier string representation .
 java.lang.String getValue()
          Returns the value of the identifier.
 void setToken(int identifier, java.lang.String value)
          Sets the identifier of the token and its value, if needed.
 java.lang.String toString()
          Returns a @see String representation of the instance.
 
Methods inherited from class java.util.EventObject
getSource
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

VARIABLE

public static final int VARIABLE
The different command tokens.

See Also:
Constant Field Values

INTEGER

public static final int INTEGER
See Also:
Constant Field Values

FLOAT

public static final int FLOAT
See Also:
Constant Field Values

ADDITION

public static final int ADDITION
See Also:
Constant Field Values

SUBSTRACTION

public static final int SUBSTRACTION
See Also:
Constant Field Values

MULTIPLICATION

public static final int MULTIPLICATION
See Also:
Constant Field Values

DIVISION

public static final int DIVISION
See Also:
Constant Field Values

POWER

public static final int POWER
See Also:
Constant Field Values

EQUAL

public static final int EQUAL
See Also:
Constant Field Values

UNEQUAL

public static final int UNEQUAL
See Also:
Constant Field Values

LESS

public static final int LESS
See Also:
Constant Field Values

LESSEQUAL

public static final int LESSEQUAL
See Also:
Constant Field Values

GREATER

public static final int GREATER
See Also:
Constant Field Values

GREATEREQUAL

public static final int GREATEREQUAL
See Also:
Constant Field Values

FUNCTION

public static final int FUNCTION
See Also:
Constant Field Values

SEPARATOR

public static final int SEPARATOR
See Also:
Constant Field Values

OPEN_PAREN

public static final int OPEN_PAREN
See Also:
Constant Field Values

CLOSE_PAREN

public static final int CLOSE_PAREN
See Also:
Constant Field Values

OPEN_BRACKET

public static final int OPEN_BRACKET
See Also:
Constant Field Values

CLOSE_BRACKET

public static final int CLOSE_BRACKET
See Also:
Constant Field Values

OPEN_CURLY

public static final int OPEN_CURLY
See Also:
Constant Field Values

CLOSE_CURLY

public static final int CLOSE_CURLY
See Also:
Constant Field Values

RESERVED

public static final int RESERVED
See Also:
Constant Field Values

UNDERSCRIPT

public static final int UNDERSCRIPT
See Also:
Constant Field Values

SPECIALIZED

public static final int SPECIALIZED
See Also:
Constant Field Values

START_EXPRESSION

public static final int START_EXPRESSION
See Also:
Constant Field Values

END_EXPRESSION

public static final int END_EXPRESSION
See Also:
Constant Field Values

SYMBOL

public static final int SYMBOL
See Also:
Constant Field Values

GROUP_START

public static final int GROUP_START
See Also:
Constant Field Values

GROUP_END

public static final int GROUP_END
See Also:
Constant Field Values

FUNCTION2

public static final int FUNCTION2
See Also:
Constant Field Values
Constructor Detail

LinearParserEvent

public LinearParserEvent(java.lang.Object src)
The constructor.

Parameters:
src - the object which produces this event.
Method Detail

setToken

public void setToken(int identifier,
                     java.lang.String value)
Sets the identifier of the token and its value, if needed.

Parameters:
identifier - the token identifier.
value - the token value.

getIdentifier

public int getIdentifier()
Returns the identifier of the token wrapped into the event.


getIdentifierAsString

public java.lang.String getIdentifierAsString()
Returns the identifier of the token wrapped into the event, as a string


getStringIdentifierAsInt

public static int getStringIdentifierAsInt(java.lang.String identifier)
Returns the int value of the specified identifier string representation .


getValue

public java.lang.String getValue()
Returns the value of the identifier.


toString

public java.lang.String toString()
Returns a @see String representation of the instance.
Mainly for debugg.



Copyright © 1999-2007 Universit?© de Nice Sophia-Antipolis, I3S, Ove SARL, DFKI and Universit?§t des Saarlandes. All Rights Reserved.