Represents a list of values for attributes of an MBean. See the
getAttributes and
setAttributes methods of
MBeanServer and MBeanServerConnection.
It is not permitted to add objects to an AttributeList that are
not instances of Attribute. This will produce an IllegalArgumentException
when calling methods in this class, or when using listIterator and add or set.
| Modifier and Type | Field and Description |
|---|---|
| private static final long |
| Access | Constructor and Description |
|---|---|
| public | |
| public | AttributeList(int
the initial capacity of the
initialCapacity)AttributeList, as specified by ArrayList#ArrayList(int).Constructs an empty |
| public | AttributeList(AttributeList
the list)AttributeList that defines the initial
contents of the new AttributeList.Constructs an |
| public | AttributeList(List<Attribute>
the list)List that defines the initial contents of
the new AttributeList.Constructs an |
| Modifier and Type | Method and Description |
|---|---|
| public void | add(Attribute
The attribute to be added. object)Overrides java. Implements java. Adds the |
| public void | add(int
The position in the list where the new index, Attribute Attribute
object is to be inserted.The object)Attribute object to be inserted.Overrides java. Implements java. Inserts the attribute specified as an element at the position specified. |
| public boolean | add(Object element)
Overrides java. Implements java. Appends the specified element to the end of this list. |
| public void | add(int index, Object element)
Overrides java. Implements java. Inserts the specified element at the specified position in this list. |
| public boolean | Returns: true if this list changed as a result of the call.Elements to be inserted into the list. list)Appends all the elements in the |
| public boolean | Returns: true if this list changed as a result of the call.Position at which to insert the first element from the
index, AttributeList AttributeList specified.Elements to be inserted into the list. list)Inserts all of the elements in the |
| public boolean | addAll(Collection<?> c)
Overrides java. Implements java. Appends all of the elements in the specified collection to the end of this list, in the order that they are returned by the specified collection's Iterator. |
| public boolean | addAll(int index, Collection<?> c)
Overrides java. Implements java. Inserts all of the elements in the specified collection into this list, starting at the specified position. |
| private void | |
| private void | |
| public List | Returns: aList<Attribute> whose contents
reflect the contents of this AttributeList.Return a view of this list as a |
| public void | set(int
The position specified. index, Attribute The value to which the attribute element should be set. object)Overrides java. Implements java. Sets the element at the position specified to be the attribute specified. |
| public Object | set(int index, Object element)
Overrides java. Implements java. Replaces the element at the specified position in this list with the specified element. |
| serialVersionUID | back to summary |
|---|---|
| private static final long serialVersionUID | |
| AttributeList | back to summary |
|---|---|
| public AttributeList() Constructs an empty | |
| AttributeList | back to summary |
|---|---|
| public AttributeList(int initialCapacity) Constructs an empty
| |
| AttributeList | back to summary |
|---|---|
| public AttributeList(AttributeList list) Constructs an
| |
| AttributeList | back to summary |
|---|---|
| public AttributeList(List<Attribute> list) Constructs an
| |
| add | back to summary |
|---|---|
| public void add(Attribute object) Overrides java. Implements java. Adds the
| |
| add | back to summary |
|---|---|
| public void add(int index, Attribute object) Overrides java. Implements java. Inserts the attribute specified as an element at the position specified. Elements with an index greater than or equal to the current position are shifted up. If the index is out of range (index < 0 || index > size()) a RuntimeOperationsException should be raised, wrapping the java.lang.IndexOutOfBoundsException thrown.
| |
| add | back to summary |
|---|---|
| public boolean add(Object element) Overrides java. Implements java. Doc from java. Appends the specified element to the end of this list.
| |
| add | back to summary |
|---|---|
| public void add(int index, Object element) Overrides java. Implements java. Doc from java. Inserts the specified element at the specified position in this list. Shifts the element currently at that position (if any) and any subsequent elements to the right (adds one to their indices).
| |
| addAll | back to summary |
|---|---|
| public boolean addAll(AttributeList list) Appends all the elements in the
| |
| addAll | back to summary |
|---|---|
| public boolean addAll(int index, AttributeList list) Inserts all of the elements in the
| |
| addAll | back to summary |
|---|---|
| public boolean addAll(Collection<?> c) Overrides java. Implements java. Doc from java. Appends all of the elements in the specified collection to the end of this list, in the order that they are returned by the specified collection's Iterator. The behavior of this operation is undefined if the specified collection is modified while the operation is in progress. (This implies that the behavior of this call is undefined if the specified collection is this list, and this list is nonempty.)
| |
| addAll | back to summary |
|---|---|
| public boolean addAll(int index, Collection<?> c) Overrides java. Implements java. Doc from java. Inserts all of the elements in the specified collection into this list, starting at the specified position. Shifts the element currently at that position (if any) and any subsequent elements to the right (increases their indices). The new elements will appear in the list in the order that they are returned by the specified collection's iterator.
| |
| adding | back to summary |
|---|---|
| private void adding(Object x) | |
| adding | back to summary |
|---|---|
| private void adding(Collection<?> c) | |
| asList | back to summary |
|---|---|
| public List Return a view of this list as a
| |
| set | back to summary |
|---|---|
| public void set(int index, Attribute object) Overrides java. Implements java. Sets the element at the position specified to be the attribute specified. The previous element at that position is discarded. If the index is out of range (index < 0 || index > size()) a RuntimeOperationsException should be raised, wrapping the java.lang.IndexOutOfBoundsException thrown.
| |
| set | back to summary |
|---|---|
| public Object set(int index, Object element) Overrides java. Implements java. Doc from java. Replaces the element at the specified position in this list with the specified element.
| |