PMGClasspublic final class PMGClass extends Attribute This class is derived from Attribute and represents a reference
to a PMG
attribute. |
Fields Summary |
---|
private int | pmg_class_index | private int | pmg_index |
Constructors Summary |
---|
public PMGClass(PMGClass c)Initialize from another object. Note that both objects use the same
references (shallow copy). Use clone() for a physical copy.
this(c.getNameIndex(), c.getLength(), c.getPMGIndex(), c.getPMGClassIndex(),
c.getConstantPool());
| PMGClass(int name_index, int length, DataInputStream file, ConstantPool constant_pool)Construct object from file stream.
this(name_index, length, file.readUnsignedShort(), file.readUnsignedShort(),
constant_pool);
| public PMGClass(int name_index, int length, int pmg_index, int pmg_class_index, ConstantPool constant_pool)
super(Constants.ATTR_PMG, name_index, length, constant_pool);
this.pmg_index = pmg_index;
this.pmg_class_index = pmg_class_index;
|
Methods Summary |
---|
public void | accept(com.sun.org.apache.bcel.internal.classfile.Visitor v)Called by objects that are traversing the nodes of the tree implicitely
defined by the contents of a Java class. I.e., the hierarchy of methods,
fields, attributes, etc. spawns a tree of objects.
System.err.println("Visiting non-standard PMGClass object");
| public com.sun.org.apache.bcel.internal.classfile.Attribute | copy(com.sun.org.apache.bcel.internal.classfile.ConstantPool constant_pool)
return (PMGClass)clone();
| public final void | dump(java.io.DataOutputStream file)Dump source file attribute to file stream in binary format.
super.dump(file);
file.writeShort(pmg_index);
file.writeShort(pmg_class_index);
| public final int | getPMGClassIndex() return pmg_class_index;
| public final java.lang.String | getPMGClassName()
ConstantUtf8 c = (ConstantUtf8)constant_pool.getConstant(pmg_class_index,
Constants.CONSTANT_Utf8);
return c.getBytes();
| public final int | getPMGIndex() return pmg_index;
| public final java.lang.String | getPMGName()
ConstantUtf8 c = (ConstantUtf8)constant_pool.getConstant(pmg_index,
Constants.CONSTANT_Utf8);
return c.getBytes();
| public final void | setPMGClassIndex(int pmg_class_index)
this.pmg_class_index = pmg_class_index;
| public final void | setPMGIndex(int pmg_index)
this.pmg_index = pmg_index;
| public final java.lang.String | toString()
return "PMGClass(" + getPMGName() + ", " + getPMGClassName() + ")";
|
|