LocalVariableTableAttributepublic class LocalVariableTableAttribute extends Attribute
Fields Summary |
---|
public LocalVariableTableEntry[] | data |
Methods Summary |
---|
public void | countConstantReferences(boolean isRelocatable)
super.countConstantReferences( isRelocatable );
for (int i = 0; i < data.length; i++) {
data[i].name.incReference();
data[i].sig.incReference();
}
| public void | externalize(ConstantPool p)
super.externalize( p );
for (int i = 0; i < data.length; i++) {
if (data[i].name != null) {
data[i].name = (UnicodeConstant)p.add( data[i].name );
}
if (data[i].sig != null) {
data[i].sig = (UnicodeConstant)p.add( data[i].sig );
}
}
| public static Attribute | finishReadAttribute(java.io.DataInput in, UnicodeConstant name, ConstantObject[] globals)
int l;
int n;
LocalVariableTableEntry d[];
l = in.readInt();
n = in.readUnsignedShort();
d = new LocalVariableTableEntry[ n ];
for ( int i = 0; i < n; i++ ){
d[i] = new
LocalVariableTableEntry( in.readUnsignedShort(),
in.readUnsignedShort(),
(UnicodeConstant)
globals[in.readUnsignedShort()],
(UnicodeConstant)
globals[in.readUnsignedShort()],
in.readUnsignedShort()
);
}
return new LocalVariableTableAttribute( name, l, d );
| public static Attribute | readAttribute(java.io.DataInput i, ConstantObject[] globals)
UnicodeConstant name;
name = (UnicodeConstant)globals[i.readUnsignedShort()];
return finishReadAttribute( i, name, globals );
| protected int | writeData(java.io.DataOutput o)
int n = data.length;
o.writeShort( n );
for ( int i = 0; i < n; i++ ){
data[i].write( o );
}
return 2+LocalVariableTableEntry.size*n;
|
|