Class writing, call graph, eclipse project
This commit is contained in:
@@ -3,22 +3,29 @@ package info.sigterm.deob.attributes;
|
||||
import info.sigterm.deob.pool.PoolEntry;
|
||||
|
||||
import java.io.DataInputStream;
|
||||
import java.io.DataOutputStream;
|
||||
import java.io.IOException;
|
||||
|
||||
public class ConstantValue extends Attribute
|
||||
{
|
||||
private int constantVlaueIndex;
|
||||
private int constantValueIndex;
|
||||
|
||||
public ConstantValue(Attributes attributes) throws IOException
|
||||
{
|
||||
super(attributes, AttributeType.CONSTANT_VALUE);
|
||||
|
||||
DataInputStream is = attributes.getStream();
|
||||
constantVlaueIndex = is.readUnsignedShort();
|
||||
constantValueIndex = is.readUnsignedShort();
|
||||
}
|
||||
|
||||
public PoolEntry getValue()
|
||||
{
|
||||
return this.getAttributes().getClassFile().getPool().getEntry(constantVlaueIndex);
|
||||
return this.getAttributes().getClassFile().getPool().getEntry(constantValueIndex);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void writeAttr(DataOutputStream out) throws IOException
|
||||
{
|
||||
out.writeShort(constantValueIndex);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user