org.mmbase.bridge.util
Class BridgeCollections.UnmodifiableBridgeList<E>

java.lang.Object
  extended by org.mmbase.bridge.util.BridgeCollections.UnmodifiableBridgeList<E>
All Implemented Interfaces:
Iterable<E>, Collection<E>, List<E>, BridgeList<E>
Direct Known Subclasses:
BridgeCollections.UnmodifiableNodeList, BridgeCollections.UnmodifiableNodeManagerList, BridgeCollections.UnmodifiableRelationList, BridgeCollections.UnmodifiableRelationManagerList, BridgeCollections.UnmodifiableStringList
Enclosing class:
BridgeCollections

static class BridgeCollections.UnmodifiableBridgeList<E>
extends Object
implements BridgeList<E>


Field Summary
(package private)  List<E> c
           
(package private)  BridgeList<E> parent
           
 
Constructor Summary
BridgeCollections.UnmodifiableBridgeList()
           
BridgeCollections.UnmodifiableBridgeList(BridgeList<E> c)
           
BridgeCollections.UnmodifiableBridgeList(List<E> c, BridgeList<E> parent)
           
 
Method Summary
 void add(int i, Object o)
           
 boolean add(Object o)
           
 boolean addAll(Collection<? extends E> coll)
           
 boolean addAll(int i, Collection<? extends E> coll)
           
 void clear()
           
 boolean contains(Object o)
           
 boolean containsAll(Collection<?> coll)
           
 boolean equals(Object o)
           
 E get(int i)
           
 Map<Object,Object> getProperties()
          Returns an (unmodifiable) view on all properties of this list (See BridgeList.getProperty(java.lang.Object)).
 Object getProperty(Object key)
          Retrieves a property previously set for this list.
 int hashCode()
           
 int indexOf(Object o)
           
 boolean isEmpty()
           
 Iterator<E> iterator()
           
 int lastIndexOf(Object o)
           
 ListIterator<E> listIterator()
           
 ListIterator<E> listIterator(int s)
           
 E remove(int i)
           
 boolean remove(Object o)
           
 boolean removeAll(Collection<?> coll)
           
 boolean retainAll(Collection<?> coll)
           
 E set(int i, Object o)
           
 void setProperty(Object key, Object value)
          Sets a property for this list.
 int size()
           
 void sort()
          Sorts this list according to a default sort order.
 void sort(Comparator<? super E> comparator)
          Sorts this list according to a specified sort order
 BridgeList<E> subList(int fromIndex, int toIndex)
           
 Object[] toArray()
           
<T> T[]
toArray(T[] a)
           
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

c

final List<E> c

parent

final BridgeList<E> parent
Constructor Detail

BridgeCollections.UnmodifiableBridgeList

BridgeCollections.UnmodifiableBridgeList()

BridgeCollections.UnmodifiableBridgeList

BridgeCollections.UnmodifiableBridgeList(BridgeList<E> c)

BridgeCollections.UnmodifiableBridgeList

BridgeCollections.UnmodifiableBridgeList(List<E> c,
                                         BridgeList<E> parent)
Method Detail

size

public int size()
Specified by:
size in interface Collection<E>
Specified by:
size in interface List<E>

isEmpty

public boolean isEmpty()
Specified by:
isEmpty in interface Collection<E>
Specified by:
isEmpty in interface List<E>

contains

public boolean contains(Object o)
Specified by:
contains in interface Collection<E>
Specified by:
contains in interface List<E>

toArray

public Object[] toArray()
Specified by:
toArray in interface Collection<E>
Specified by:
toArray in interface List<E>

toArray

public <T> T[] toArray(T[] a)
Specified by:
toArray in interface Collection<E>
Specified by:
toArray in interface List<E>

toString

public String toString()
Overrides:
toString in class Object

listIterator

public ListIterator<E> listIterator(int s)
Specified by:
listIterator in interface List<E>

listIterator

public ListIterator<E> listIterator()
Specified by:
listIterator in interface List<E>

iterator

public Iterator<E> iterator()
Specified by:
iterator in interface Iterable<E>
Specified by:
iterator in interface Collection<E>
Specified by:
iterator in interface List<E>

add

public boolean add(Object o)
Specified by:
add in interface Collection<E>
Specified by:
add in interface List<E>

add

public void add(int i,
                Object o)
Specified by:
add in interface List<E>

set

public E set(int i,
             Object o)
Specified by:
set in interface List<E>

remove

public boolean remove(Object o)
Specified by:
remove in interface Collection<E>
Specified by:
remove in interface List<E>

remove

public E remove(int i)
Specified by:
remove in interface List<E>

containsAll

public boolean containsAll(Collection<?> coll)
Specified by:
containsAll in interface Collection<E>
Specified by:
containsAll in interface List<E>

addAll

public boolean addAll(Collection<? extends E> coll)
Specified by:
addAll in interface Collection<E>
Specified by:
addAll in interface List<E>

addAll

public boolean addAll(int i,
                      Collection<? extends E> coll)
Specified by:
addAll in interface List<E>

removeAll

public boolean removeAll(Collection<?> coll)
Specified by:
removeAll in interface Collection<E>
Specified by:
removeAll in interface List<E>

retainAll

public boolean retainAll(Collection<?> coll)
Specified by:
retainAll in interface Collection<E>
Specified by:
retainAll in interface List<E>

clear

public void clear()
Specified by:
clear in interface Collection<E>
Specified by:
clear in interface List<E>

get

public E get(int i)
Specified by:
get in interface List<E>

getProperty

public Object getProperty(Object key)
Description copied from interface: BridgeList
Retrieves a property previously set for this list. Use this to store and retrieve meta data on how the list was created (such as what sort-order was specified)

Specified by:
getProperty in interface BridgeList<E>
Parameters:
key - the key of the property
Returns:
the property value

getProperties

public Map<Object,Object> getProperties()
Description copied from interface: BridgeList
Returns an (unmodifiable) view on all properties of this list (See BridgeList.getProperty(java.lang.Object)).

Specified by:
getProperties in interface BridgeList<E>

setProperty

public void setProperty(Object key,
                        Object value)
Description copied from interface: BridgeList
Sets a property for this list. Use this to store and retrieve meta data on how the list was created (such as what sort-order was specified)

Specified by:
setProperty in interface BridgeList<E>
Parameters:
key - the key of the property
value - the property value

sort

public void sort()
Description copied from interface: BridgeList
Sorts this list according to a default sort order.

Specified by:
sort in interface BridgeList<E>

sort

public void sort(Comparator<? super E> comparator)
Description copied from interface: BridgeList
Sorts this list according to a specified sort order

Specified by:
sort in interface BridgeList<E>
Parameters:
comparator - the comparator defining the sort order

subList

public BridgeList<E> subList(int fromIndex,
                             int toIndex)
Specified by:
subList in interface List<E>
Specified by:
subList in interface BridgeList<E>

lastIndexOf

public int lastIndexOf(Object o)
Specified by:
lastIndexOf in interface List<E>

indexOf

public int indexOf(Object o)
Specified by:
indexOf in interface List<E>

equals

public boolean equals(Object o)
Specified by:
equals in interface Collection<E>
Specified by:
equals in interface List<E>
Overrides:
equals in class Object

hashCode

public int hashCode()
Specified by:
hashCode in interface Collection<E>
Specified by:
hashCode in interface List<E>
Overrides:
hashCode in class Object


MMBase 2.0-SNAPSHOT - null