code.loader.parser
Class TxtParser

java.lang.Object
  extended by code.loader.parser.TxtParser
All Implemented Interfaces:
ModuleParser

public class TxtParser
extends java.lang.Object
implements ModuleParser

Parse and get the txt based module information from the stream provided.

Class Responsibilities :

  1. Parse the txt based compiled module
  2. return back important information of the module through public functions
Class Collaborators :
  1. symbol package
  2. type package

Since:
Jan 09, 2003
Author:
jimeng

Field Summary
private  java.util.Vector allSymbols
           
private  boolean compiled
           
private  java.util.Vector imported
           
private  java.lang.String moduleName
           
private  java.lang.String source
           
private  int timestamp
           
 
Constructor Summary
TxtParser()
           
 
Method Summary
 java.util.Vector getAllSymbols()
          Gets the allSymbols attribute of the ModuleParser object
 java.util.Vector getImported()
          Gets the imported attribute of the ModuleParser object
 int getTimestamp()
          Gets the module's timestamp
 void initParser(java.io.BufferedReader in)
          Initializes the parser for incremental parsing of the file.
 boolean isCompiled()
          Gets the compiled attribute of the ModuleParser object
 java.lang.String moduleName()
          Gets the moduleNmae attribute of the ModuleParser object.
 void parse(java.io.BufferedReader in)
          Parse the source from the BufferedReader
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

imported

private java.util.Vector imported

allSymbols

private java.util.Vector allSymbols

compiled

private boolean compiled

timestamp

private int timestamp

source

private java.lang.String source

moduleName

private java.lang.String moduleName
Constructor Detail

TxtParser

public TxtParser()
Method Detail

parse

public void parse(java.io.BufferedReader in)
           throws ParseException
Description copied from interface: ModuleParser
Parse the source from the BufferedReader

Specified by:
parse in interface ModuleParser
Parameters:
in - Description of the Parameter
Throws:
ParseException - Description of the Exception

getImported

public java.util.Vector getImported()
Description copied from interface: ModuleParser
Gets the imported attribute of the ModuleParser object

Specified by:
getImported in interface ModuleParser
Returns:
The imported value

getAllSymbols

public java.util.Vector getAllSymbols()
Description copied from interface: ModuleParser
Gets the allSymbols attribute of the ModuleParser object

Specified by:
getAllSymbols in interface ModuleParser
Returns:
The allSymbols value

isCompiled

public boolean isCompiled()
Description copied from interface: ModuleParser
Gets the compiled attribute of the ModuleParser object

Specified by:
isCompiled in interface ModuleParser
Returns:
The compiled value

moduleName

public java.lang.String moduleName()
Description copied from interface: ModuleParser
Gets the moduleNmae attribute of the ModuleParser object.

Specified by:
moduleName in interface ModuleParser
Returns:
The moduleName

getTimestamp

public int getTimestamp()
Description copied from interface: ModuleParser
Gets the module's timestamp

Specified by:
getTimestamp in interface ModuleParser
Returns:
The moduleName

initParser

public void initParser(java.io.BufferedReader in)
                throws ParseException
Initializes the parser for incremental parsing of the file.

Specified by:
initParser in interface ModuleParser
Parameters:
in - Reader that is prepared to read in the module file's contents.
Throws:
ParseException - Description Needed.