net.sf.rej.java.attribute
Class Attributes
java.lang.Object
net.sf.rej.java.attribute.Attributes
public class Attributes
- extends java.lang.Object
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Attributes
public Attributes()
Attributes
public Attributes(ByteParser parser,
ConstantPool pool)
getAttributes
public java.util.List<Attribute> getAttributes()
getLineNumberTable
public LineNumberTableAttribute getLineNumberTable()
getLocalVariableTable
public LocalVariableTableAttribute getLocalVariableTable()
getSyntheticAttribute
public SyntheticAttribute getSyntheticAttribute()
getDeprecatedAttribute
public DeprecatedAttribute getDeprecatedAttribute()
getSourceFileAttribute
public SourceFileAttribute getSourceFileAttribute()
getExceptionsAttribute
public ExceptionsAttribute getExceptionsAttribute()
getSignatureAttribute
public SignatureAttribute getSignatureAttribute()
getLocalVariableTypeTable
public LocalVariableTypeTableAttribute getLocalVariableTypeTable()
getRuntimeVisibleAnnotationsAttribute
public RuntimeVisibleAnnotationsAttribute getRuntimeVisibleAnnotationsAttribute()
getRuntimeInvisibleAnnotationsAttribute
public RuntimeInvisibleAnnotationsAttribute getRuntimeInvisibleAnnotationsAttribute()
getCode
public CodeAttribute getCode()
getConstantValueAttribute
public ConstantValueAttribute getConstantValueAttribute()
getNamedAttribute
public Attribute getNamedAttribute(java.lang.String name)
getData
public byte[] getData()
getOffsetMap
public java.util.Map<java.lang.Object,Range> getOffsetMap(int initialOffset)
- Returns a map of offsets of each significant element of this method.
The offsets returned by this method are only valid until this
object is modified. The keys in the map are
of type
OffsetTag
, Interface
,
Field
and Method
.
- Parameters:
initialOffset
- the initial offset (this is added to each offset value).
- Returns:
- a map of element offsets in class file data.
removeAttribute
public void removeAttribute(Attribute attr)
addAttribute
public void addAttribute(Attribute attr)