Interface AttributeList
- All Known Implementing Classes:
StdAttributeList
public interface AttributeList
Interface for lists of attributes.
-
Method Summary
Modifier and TypeMethodDescriptionintGet the total length of this list in bytes, when part of a class file.Get the first attribute in the list with the given name, if any.Get the next attribute in the list after the given one, with the same name, if any.get(int n) Get thenth attribute.booleanGet whether this instance is mutable.intsize()Get the number of attributes in the list.
-
Method Details
-
isMutable
boolean isMutable()Get whether this instance is mutable. Note that theAttributeListinterface itself doesn't provide any means of mutation, but that doesn't mean that there isn't a non-interface way of mutating an instance.- Returns:
trueiff this instance is somehow mutable
-
size
int size()Get the number of attributes in the list.- Returns:
- the size
-
get
Get thenth attribute.- Parameters:
n-n >= 0, n < size();which attribute- Returns:
non-null;the attribute in question
-
byteLength
int byteLength()Get the total length of this list in bytes, when part of a class file. The returned value includes the two bytes for theattributes_countlength indicator.- Returns:
>= 2;the total length, in bytes
-
findFirst
-
findNext
-