org.objectweb.asm.tree

Class ClassNode

public class ClassNode extends Object

A node that represents a class.

Author: Eric Bruneton

Field Summary
intaccess
The class's access flags (see {@link org.objectweb.asm.Constants}).
Attributeattrs
The non standard attributes of the class.
Listfields
The fields of this class.
ListinnerClasses
Informations about the inner classes of this class.
Listinterfaces
The internal names of the class's interfaces (see {@link org.objectweb.asm.Type#getInternalName() getInternalName}).
Listmethods
The methods of this class.
Stringname
The internal name of the class (see {@link org.objectweb.asm.Type#getInternalName() getInternalName}).
StringsourceFile
The name of the source file from which this class was compiled.
StringsuperName
The internal of name of the super class (see {@link org.objectweb.asm.Type#getInternalName() getInternalName}).
intversion
The class version.
Constructor Summary
ClassNode(int version, int access, String name, String superName, String[] interfaces, String sourceFile)
Constructs a new {@link ClassNode ClassNode} object.
Method Summary
voidaccept(ClassVisitor cv)
Makes the given class visitor visit this class.

Field Detail

access

public int access
The class's access flags (see {@link org.objectweb.asm.Constants}). This field also indicates if the class is deprecated.

attrs

public Attribute attrs
The non standard attributes of the class.

fields

public final List fields
The fields of this class. This list is a list of {@link FieldNode FieldNode} objects.

innerClasses

public final List innerClasses
Informations about the inner classes of this class. This list is a list of {@link InnerClassNode InnerClassNode} objects.

interfaces

public final List interfaces
The internal names of the class's interfaces (see {@link org.objectweb.asm.Type#getInternalName() getInternalName}). This list is a list of {@link String} objects.

methods

public final List methods
The methods of this class. This list is a list of {@link MethodNode MethodNode} objects.

name

public String name
The internal name of the class (see {@link org.objectweb.asm.Type#getInternalName() getInternalName}).

sourceFile

public String sourceFile
The name of the source file from which this class was compiled. May be null.

superName

public String superName
The internal of name of the super class (see {@link org.objectweb.asm.Type#getInternalName() getInternalName}). For interfaces, the super class is {@link Object}. May be null, but only for the {@link Object java.lang.Object} class.

version

public int version
The class version.

Constructor Detail

ClassNode

public ClassNode(int version, int access, String name, String superName, String[] interfaces, String sourceFile)
Constructs a new {@link ClassNode ClassNode} object.

Parameters: version the class version. access the class's access flags (see {@link org.objectweb.asm.Constants}). This parameter also indicates if the class is deprecated. name the internal name of the class (see {@link org.objectweb.asm.Type#getInternalName() getInternalName}). superName the internal of name of the super class (see {@link org.objectweb.asm.Type#getInternalName() getInternalName}). For interfaces, the super class is {@link Object}. interfaces the internal names of the class's interfaces (see {@link org.objectweb.asm.Type#getInternalName() getInternalName}). May be null. sourceFile the name of the source file from which this class was compiled. May be null.

Method Detail

accept

public void accept(ClassVisitor cv)
Makes the given class visitor visit this class.

Parameters: cv a class visitor.