Class LocalVariableTableAttribute
- java.lang.Object
-
- kala.compress.harmony.unpack200.bytecode.ClassFileEntry
-
- kala.compress.harmony.unpack200.bytecode.Attribute
-
- kala.compress.harmony.unpack200.bytecode.BCIRenumberedAttribute
-
- kala.compress.harmony.unpack200.bytecode.LocalVariableTableAttribute
-
public class LocalVariableTableAttribute extends BCIRenumberedAttribute
Local variable table
-
-
Field Summary
Fields Modifier and Type Field Description private static CPUTF8attributeNameprivate intcodeLengthprivate int[]descriptorIndexesprivate CPUTF8[]descriptorsprivate int[]indexesprivate int[]lengthsprivate intlocalVariableTableLengthprivate int[]nameIndexesprivate CPUTF8[]namesprivate int[]startPcs-
Fields inherited from class kala.compress.harmony.unpack200.bytecode.BCIRenumberedAttribute
renumbered
-
Fields inherited from class kala.compress.harmony.unpack200.bytecode.ClassFileEntry
NONE
-
-
Constructor Summary
Constructors Constructor Description LocalVariableTableAttribute(int localVariableTableLength, int[] startPcs, int[] lengths, CPUTF8[] names, CPUTF8[] descriptors, int[] indexes)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description protected intgetLength()protected ClassFileEntry[]getNestedClassFileEntries()protected int[]getStartPCs()voidrenumber(java.util.List<java.lang.Integer> byteCodeOffsets)In Pack200, line number tables are BCI renumbered.protected voidresolve(ClassConstantPool pool)Allows the constant pool entries to resolve their nested entries.static voidsetAttributeName(CPUTF8 cpUTF8Value)voidsetCodeLength(int length)java.lang.StringtoString()protected voidwriteBody(java.io.DataOutputStream dos)-
Methods inherited from class kala.compress.harmony.unpack200.bytecode.BCIRenumberedAttribute
hasBCIRenumbering
-
Methods inherited from class kala.compress.harmony.unpack200.bytecode.Attribute
doWrite, equals, getAttributeName, getLengthIncludingHeader, hashCode, isSourceFileAttribute
-
Methods inherited from class kala.compress.harmony.unpack200.bytecode.ClassFileEntry
objectHashCode, write
-
-
-
-
Field Detail
-
attributeName
private static CPUTF8 attributeName
-
localVariableTableLength
private final int localVariableTableLength
-
startPcs
private final int[] startPcs
-
lengths
private final int[] lengths
-
nameIndexes
private int[] nameIndexes
-
descriptorIndexes
private int[] descriptorIndexes
-
indexes
private final int[] indexes
-
names
private final CPUTF8[] names
-
descriptors
private final CPUTF8[] descriptors
-
codeLength
private int codeLength
-
-
Method Detail
-
setAttributeName
public static void setAttributeName(CPUTF8 cpUTF8Value)
-
getLength
protected int getLength()
- Specified by:
getLengthin classBCIRenumberedAttribute
-
getNestedClassFileEntries
protected ClassFileEntry[] getNestedClassFileEntries()
- Overrides:
getNestedClassFileEntriesin classAttribute
-
getStartPCs
protected int[] getStartPCs()
- Specified by:
getStartPCsin classBCIRenumberedAttribute
-
renumber
public void renumber(java.util.List<java.lang.Integer> byteCodeOffsets) throws Pack200ExceptionDescription copied from class:BCIRenumberedAttributeIn Pack200, line number tables are BCI renumbered. This method takes the byteCodeOffsets (which is a List of Integers specifying the offset in the byte code array of each instruction) and updates the start_pcs so that it points to the instruction index itself, not the BCI renumbering of the instruction.- Overrides:
renumberin classBCIRenumberedAttribute- Parameters:
byteCodeOffsets- List of Integer offsets of the byte code array- Throws:
Pack200Exception- Thrown from a subclass.
-
resolve
protected void resolve(ClassConstantPool pool)
Description copied from class:ClassFileEntryAllows the constant pool entries to resolve their nested entries.
-
setCodeLength
public void setCodeLength(int length)
-
toString
public java.lang.String toString()
- Specified by:
toStringin classBCIRenumberedAttribute
-
writeBody
protected void writeBody(java.io.DataOutputStream dos) throws java.io.IOException- Specified by:
writeBodyin classBCIRenumberedAttribute- Throws:
java.io.IOException
-
-