net.sf.cb2java.copybook
Class CopybookParser
java.lang.Object
net.sf.cb2java.copybook.CopybookParser
- public class CopybookParser
- extends java.lang.Object
This class is the starting point for parsing copybooks
To parse or create data, you need to first parse the
copybook. The returned CopyBook instance will allow for
working with data.
- Author:
- James Watson
Method Summary |
static Copybook |
parse(java.lang.String name,
java.io.InputStream stream)
Parses a copybook defintion and returns a Copybook instance |
static Copybook |
parse(java.lang.String name,
java.io.Reader reader)
Parses a copybook defintion and returns a Copybook instance |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
CopybookParser
public CopybookParser()
parse
public static Copybook parse(java.lang.String name,
java.io.InputStream stream)
- Parses a copybook defintion and returns a Copybook instance
- Parameters:
name
- the name of the copybook. For future use.stream
- the copybook definiton's source stream
- Returns:
- a copybook instance containg the parse tree for the definition
parse
public static Copybook parse(java.lang.String name,
java.io.Reader reader)
- Parses a copybook defintion and returns a Copybook instance
- Parameters:
name
- the name of the copybook. For future use.reader
- the copybook definiton's source reader
- Returns:
- a copybook instance containg the parse tree for the definition