-
- All Implemented Interfaces:
public class ClassFileReaderConverts class files to a class file structure ClassFile as defined in org.gjt.jclasslib.structures.
-
-
Field Summary
Fields Modifier and Type Field Description public final static ClassFileReaderINSTANCE
-
Method Summary
Modifier and Type Method Description final static ClassFilereadFromClassPath(Array<String> classPath, String packageName, String className, Boolean suppressEOF)Looks up a class file in the specified class path and converts it to a ClassFile structure. final static ClassFilereadFromClassPath(Array<String> classPath, String packageName, String className)Looks up a class file in the specified class path and converts it to a ClassFile structure. final static ClassFilereadFromFile(File file, Boolean suppressEOF)Converts a class file to a ClassFile structure. final static ClassFilereadFromFile(File file)Converts a class file to a ClassFile structure. final static ClassFilereadFromInputStream(InputStream stream, Boolean suppressEOF)Converts a class file to a ClassFile structure. final static ClassFilereadFromInputStream(InputStream stream)Converts a class file to a ClassFile structure. -
-
Method Detail
-
readFromClassPath
@JvmOverloads() final static ClassFile readFromClassPath(Array<String> classPath, String packageName, String className, Boolean suppressEOF)
Looks up a class file in the specified class path and converts it to a ClassFile structure.
- Parameters:
classPath- the class path from which to read the ClassFile structurepackageName- the name of the package in which the class residesclassName- the simple name of the classsuppressEOF- whether an unexpected end-of-file while reading the class file should be ignored
-
readFromClassPath
@JvmOverloads() final static ClassFile readFromClassPath(Array<String> classPath, String packageName, String className)
Looks up a class file in the specified class path and converts it to a ClassFile structure.
- Parameters:
classPath- the class path from which to read the ClassFile structurepackageName- the name of the package in which the class residesclassName- the simple name of the class
-
readFromFile
@JvmOverloads() final static ClassFile readFromFile(File file, Boolean suppressEOF)
Converts a class file to a ClassFile structure.
- Parameters:
file- the file from which to read the ClassFile structuresuppressEOF- whether an unexpected end-of-file while reading the class file should be ignored
-
readFromFile
@JvmOverloads() final static ClassFile readFromFile(File file)
Converts a class file to a ClassFile structure.
- Parameters:
file- the file from which to read the ClassFile structure
-
readFromInputStream
@JvmOverloads() final static ClassFile readFromInputStream(InputStream stream, Boolean suppressEOF)
Converts a class file to a ClassFile structure.
- Parameters:
stream- the input stream from which to read the ClassFile structuresuppressEOF- whether an unexpected end-of-file while reading the class file should be ignored
-
readFromInputStream
@JvmOverloads() final static ClassFile readFromInputStream(InputStream stream)
Converts a class file to a ClassFile structure.
- Parameters:
stream- the input stream from which to read the ClassFile structure
-
-
-
-