All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class espresso.classfile.util.Class2HTML

java.lang.Object
   |
   +----espresso.classfile.util.Class2HTML

public class Class2HTML
extends Object
implements Constants
Read class file(s) and convert them into HTML files. Given a JavaClass object "class" that is in package "package" five files will be created in the specified directory.
  1. "package"."class".html as the main file which defines the frames for the following subfiles.
  2. "package"."class"_attributes.html contains all (known) attributes found in the file
  3. "package"."class"_cp.html contains the constant pool
  4. "package"."class"_code.html contains the byte code
  5. "package"."class"_methods.html contains references to all methods and fields of the class
All subfiles reference each other appropiately, e.g. clicking on a method in the Method's frame will jump to the appropiate method in the Code frame.


Variable Index

 o class_name
 o class_package
 o constant_pool
 o dir
 o java_class

Constructor Index

 o Class2HTML(JavaClass, String)
Write contents of the given JavaClass into HTML files.

Method Index

 o main(String[])
 o referenceClass(int)
Utility method that converts a class reference in the constant pool, i.e.
 o referenceType(String)
 o toHTML(String)
 o writeMainHTML(AttributeHTML)

Variables

 o java_class
 private JavaClass java_class
 o dir
 private String dir
 o class_package
 private static String class_package
 o class_name
 private static String class_name
 o constant_pool
 private static ConstantPool constant_pool

Constructors

 o Class2HTML
 public Class2HTML(JavaClass java_class,
                   String dir) throws IOException
Write contents of the given JavaClass into HTML files.

Parameters:
java_class - The class to write
dir - The directory to put the files in

Methods

 o main
 public static void main(String argv[])
 o referenceClass
 static String referenceClass(int index)
Utility method that converts a class reference in the constant pool, i.e. an index to a string.

 o referenceType
 static final String referenceType(String type)
 o toHTML
 static String toHTML(String str)
 o writeMainHTML
 private void writeMainHTML(AttributeHTML attribute_html) throws IOException

All Packages  Class Hierarchy  This Package  Previous  Next  Index