FileDocCategorySizeDatePackage
ClassDefParser.javaAPI DocAndroid 1.5 API10924Wed May 06 22:41:16 BST 2009com.vladium.jcd.parser

ClassDefParser

public abstract class ClassDefParser extends Object
This class provides an API for parsing a stream or array of bytecodes into a {@link ClassDef} AST.
author
(C) 2001, Vlad Roubtsov

Fields Summary
static final boolean
PARSE_SERIAL_VERSION_UID
static final String
SERIAL_VERSION_UID_FIELD_NAME
static final int
SERIAL_VERSION_UID_FIELD_MASK
Constructors Summary
Methods Summary
public static ClassDefparseClass(byte[] bytes)
Parses an array of bytecodes into a {@link ClassDef}.

        if (bytes == null) throw new IllegalArgumentException ("null input: bytes");
        
        classParser parser = new classParser (new UDataInputStream (new ByteArrayIStream (bytes)));
        
        return parser.class_table ();
    
public static ClassDefparseClass(byte[] bytes, int length)
Parses an array of bytecodes into a {@link ClassDef}.

        if (bytes == null) throw new IllegalArgumentException ("null input: bytes");
        
        classParser parser = new classParser (new UDataInputStream (new ByteArrayIStream (bytes, length)));
        
        return parser.class_table ();
    
public static ClassDefparseClass(java.io.InputStream bytes)
Parses a stream of bytecodes into a {@link ClassDef}.

        if (bytes == null) throw new IllegalArgumentException ("null input: bytes");
        
        classParser parser = new classParser (new UDataInputStream (bytes));
        
        return parser.class_table ();