com.vladium.jcd.parser
Class ClassDefParser

java.lang.Object
  extended bycom.vladium.jcd.parser.ClassDefParser

public abstract class ClassDefParser
extends java.lang.Object

This class provides an API for parsing a stream or array of bytecodes into a ClassDef AST.

Author:
(C) 2001, Vlad Roubtsov

Nested Class Summary
private static class ClassDefParser.classParser
          All the parsing work is done by this class and its class_table method.
 
Field Summary
(package private) static boolean PARSE_SERIAL_VERSION_UID
           
(package private) static int SERIAL_VERSION_UID_FIELD_MASK
           
(package private) static java.lang.String SERIAL_VERSION_UID_FIELD_NAME
           
 
Constructor Summary
ClassDefParser()
           
 
Method Summary
static ClassDef parseClass(byte[] bytes)
          Parses an array of bytecodes into a ClassDef.
static ClassDef parseClass(byte[] bytes, int length)
          Parses an array of bytecodes into a ClassDef.
static ClassDef parseClass(java.io.InputStream bytes)
          Parses a stream of bytecodes into a ClassDef.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

PARSE_SERIAL_VERSION_UID

static final boolean PARSE_SERIAL_VERSION_UID
See Also:
Constant Field Values

SERIAL_VERSION_UID_FIELD_NAME

static final java.lang.String SERIAL_VERSION_UID_FIELD_NAME
See Also:
Constant Field Values

SERIAL_VERSION_UID_FIELD_MASK

static final int SERIAL_VERSION_UID_FIELD_MASK
See Also:
Constant Field Values
Constructor Detail

ClassDefParser

public ClassDefParser()
Method Detail

parseClass

public static ClassDef parseClass(byte[] bytes)
                           throws java.io.IOException
Parses an array of bytecodes into a ClassDef.

Throws:
java.io.IOException

parseClass

public static ClassDef parseClass(byte[] bytes,
                                  int length)
                           throws java.io.IOException
Parses an array of bytecodes into a ClassDef.

Throws:
java.io.IOException

parseClass

public static ClassDef parseClass(java.io.InputStream bytes)
                           throws java.io.IOException
Parses a stream of bytecodes into a ClassDef.

Throws:
java.io.IOException