org.dom4j.tree
public class ContentListFacade extends java.util.AbstractList
ContentListFacade
represents a facade of the content of a
Branch
which is returned via calls to the Branch.content()
method to allow users to modify the content of a
Branch
directly using the List
interface. This list
is backed by the branch such that changes to the list will be reflected in
the branch and changes to the branch will be reflected in this list.
Constructor and Description |
---|
ContentListFacade(AbstractBranch branch,
java.util.List branchContent) |
Modifier and Type | Method and Description |
---|---|
void |
add(int index,
java.lang.Object object) |
boolean |
add(java.lang.Object object) |
boolean |
addAll(java.util.Collection collection) |
boolean |
addAll(int index,
java.util.Collection collection) |
protected Node |
asNode(java.lang.Object object) |
void |
clear() |
boolean |
contains(java.lang.Object o) |
boolean |
containsAll(java.util.Collection c) |
java.lang.Object |
get(int index) |
protected java.util.List |
getBackingList() |
int |
indexOf(java.lang.Object o) |
boolean |
isEmpty() |
int |
lastIndexOf(java.lang.Object o) |
java.lang.Object |
remove(int index) |
boolean |
remove(java.lang.Object object) |
boolean |
removeAll(java.util.Collection c) |
java.lang.Object |
set(int index,
java.lang.Object object) |
int |
size() |
java.lang.Object[] |
toArray() |
java.lang.Object[] |
toArray(java.lang.Object[] a) |
equals, hashCode, iterator, listIterator, listIterator, removeRange, subList
public ContentListFacade(AbstractBranch branch, java.util.List branchContent)
public boolean add(java.lang.Object object)
add
in interface java.util.Collection
add
in interface java.util.List
add
in class java.util.AbstractList
public void add(int index, java.lang.Object object)
add
in interface java.util.List
add
in class java.util.AbstractList
public java.lang.Object set(int index, java.lang.Object object)
set
in interface java.util.List
set
in class java.util.AbstractList
public boolean remove(java.lang.Object object)
remove
in interface java.util.Collection
remove
in interface java.util.List
remove
in class java.util.AbstractCollection
public java.lang.Object remove(int index)
remove
in interface java.util.List
remove
in class java.util.AbstractList
public boolean addAll(java.util.Collection collection)
addAll
in interface java.util.Collection
addAll
in interface java.util.List
addAll
in class java.util.AbstractCollection
public boolean addAll(int index, java.util.Collection collection)
addAll
in interface java.util.List
addAll
in class java.util.AbstractList
public void clear()
clear
in interface java.util.Collection
clear
in interface java.util.List
clear
in class java.util.AbstractList
public boolean removeAll(java.util.Collection c)
removeAll
in interface java.util.Collection
removeAll
in interface java.util.List
removeAll
in class java.util.AbstractCollection
public int size()
size
in interface java.util.Collection
size
in interface java.util.List
size
in class java.util.AbstractCollection
public boolean isEmpty()
isEmpty
in interface java.util.Collection
isEmpty
in interface java.util.List
isEmpty
in class java.util.AbstractCollection
public boolean contains(java.lang.Object o)
contains
in interface java.util.Collection
contains
in interface java.util.List
contains
in class java.util.AbstractCollection
public java.lang.Object[] toArray()
toArray
in interface java.util.Collection
toArray
in interface java.util.List
toArray
in class java.util.AbstractCollection
public java.lang.Object[] toArray(java.lang.Object[] a)
toArray
in interface java.util.Collection
toArray
in interface java.util.List
toArray
in class java.util.AbstractCollection
public boolean containsAll(java.util.Collection c)
containsAll
in interface java.util.Collection
containsAll
in interface java.util.List
containsAll
in class java.util.AbstractCollection
public java.lang.Object get(int index)
get
in interface java.util.List
get
in class java.util.AbstractList
public int indexOf(java.lang.Object o)
indexOf
in interface java.util.List
indexOf
in class java.util.AbstractList
public int lastIndexOf(java.lang.Object o)
lastIndexOf
in interface java.util.List
lastIndexOf
in class java.util.AbstractList
protected Node asNode(java.lang.Object object)
protected java.util.List getBackingList()
Copyright ? 2005 MetaStuff Ltd. All Rights Reserved. Hosted by