org.ourgrid.common.spec.semantic
Interface SemanticAnalyzer

All Known Implementing Classes:
CommonSemanticAnalyzer

public interface SemanticAnalyzer

This entity is responsable for building a answer using the semantic actions defined at the grammar. The structure of this interface sugests the use of Introspection to call the method defined by the name of the action.


Method Summary
 int getOperationMode()
          Returns a integer code that can be used to signalize some functional modes.
 void performAction(java.lang.String action, Token token)
          This is the interface method for the semantic actions.
 

Method Detail

performAction

void performAction(java.lang.String action,
                   Token token)
                   throws SemanticException
This is the interface method for the semantic actions. It will try to execute the action defined by the paramether.

Parameters:
action - The name of the action. It is generally a integer number.
token - The token that will be used at action
Throws:
SemanticException - If the action does not exists or any other problem happens.

getOperationMode

int getOperationMode()
Returns a integer code that can be used to signalize some functional modes. It is used basically to export some chages that can be used by the other modules, principally the SyntacticalAnalyzer.

Returns:
The integer code