slogo.jelan.parser
Class InstructionParser

java.lang.Object
  extended by slogo.jelan.parser.InstructionParser
All Implemented Interfaces:
Parser

public class InstructionParser
extends java.lang.Object
implements Parser

Instruction Parser - calls appropriate Parser for each Instruction


Method Summary
static InstructionParser getInstance()
           
 GrammarElement parse(ElanInterpreter ep)
          Reads the next token from the parser, gets the appropriate parser for the token, continues parsing with the appropriate parser, returns the element parsed by the appropriate parser.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getInstance

public static InstructionParser getInstance()
Returns:
the one InstructionParser for the application

parse

public GrammarElement parse(ElanInterpreter ep)
Reads the next token from the parser, gets the appropriate parser for the token, continues parsing with the appropriate parser, returns the element parsed by the appropriate parser.

Specified by:
parse in interface Parser
Returns:
the GrammarElement parsed from the ElanParser