org.eclipse.emf.common.util
Class BasicEList.UnmodifiableEList

java.lang.Object
  extended byjava.util.AbstractCollection
      extended byjava.util.AbstractList
          extended byorg.eclipse.emf.common.util.BasicEList
              extended byorg.eclipse.emf.common.util.BasicEList.UnmodifiableEList
All Implemented Interfaces:
Cloneable, Collection, EList, List, RandomAccess, Serializable
Direct Known Subclasses:
EcoreEList.UnmodifiableEList
Enclosing class:
BasicEList

public static class BasicEList.UnmodifiableEList
extends BasicEList

An unmodifiable version of BasicEList.

See Also:
Serialized Form

Nested Class Summary
 
Nested classes inherited from class org.eclipse.emf.common.util.BasicEList
BasicEList.BasicIndexOutOfBoundsException, BasicEList.EIterator, BasicEList.EListIterator, BasicEList.FastCompare, BasicEList.NonResolvingEIterator, BasicEList.NonResolvingEListIterator, BasicEList.UnmodifiableEList
 
Field Summary
 
Fields inherited from class org.eclipse.emf.common.util.BasicEList
data, size
 
Fields inherited from class java.util.AbstractList
modCount
 
Constructor Summary
BasicEList.UnmodifiableEList(int size, Object[] data)
          Creates an initialized instance.
 
Method Summary
 void add(int index, Object object)
          Throws an exception.
 boolean add(Object object)
          Throws an exception.
 boolean addAll(Collection collection)
          Throws an exception.
 boolean addAll(int index, Collection collection)
          Throws an exception.
 void clear()
          Throws an exception.
 void grow(int minimumCapacity)
          Throws an exception.
 Iterator iterator()
          Returns the basic iterator.
 ListIterator listIterator()
          Returns the basic list iterator.
 ListIterator listIterator(int index)
          Returns the basic list iterator advanced to the index.
 Object move(int targetIndex, int sourceIndex)
          Throws an exception.
 void move(int index, Object object)
          Throws an exception.
 Object remove(int index)
          Throws an exception.
 boolean remove(Object object)
          Throws an exception.
 boolean removeAll(Collection collection)
          Throws an exception.
 boolean retainAll(Collection collection)
          Throws an exception.
 Object set(int index, Object object)
          Throws an exception.
 void shrink()
          Throws an exception.
 
Methods inherited from class org.eclipse.emf.common.util.BasicEList
addAllUnique, addAllUnique, addAllUnique, addAllUnique, addUnique, addUnique, assign, basicGet, basicIterator, basicList, basicListIterator, basicListIterator, canContainNull, clone, contains, containsAll, data, didAdd, didChange, didClear, didMove, didRemove, didSet, equalObjects, equals, get, getDuplicates, getNonDuplicates, hashCode, indexOf, isEmpty, isUnique, lastIndexOf, newData, resolve, setData, setUnique, size, toArray, toArray, toString, useEquals, validate
 
Methods inherited from class java.util.AbstractList
removeRange, subList
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface java.util.List
subList
 

Constructor Detail

BasicEList.UnmodifiableEList

public BasicEList.UnmodifiableEList(int size,
                                    Object[] data)
Creates an initialized instance.

Parameters:
size - the size of the list.
data - the underlying storage of the list.
Method Detail

set

public Object set(int index,
                  Object object)
Throws an exception.

Specified by:
set in interface List
Overrides:
set in class BasicEList
Parameters:
index - the position in question.
object - the object to set.
Returns:
the old object at the index.
Throws:
UnsupportedOperationException - always because it's not supported.
See Also:
BasicEList.setUnique(int, java.lang.Object)

add

public boolean add(Object object)
Throws an exception.

Specified by:
add in interface List
Overrides:
add in class BasicEList
Parameters:
object - the object to be added.
Returns:
whether the object was added.
Throws:
UnsupportedOperationException - always because it's not supported.
See Also:
BasicEList.addUnique(Object)

add

public void add(int index,
                Object object)
Throws an exception.

Specified by:
add in interface List
Overrides:
add in class BasicEList
Parameters:
object - the object to be added.
Throws:
UnsupportedOperationException - always because it's not supported.
See Also:
BasicEList.addUnique(int, Object)

addAll

public boolean addAll(Collection collection)
Throws an exception.

Specified by:
addAll in interface List
Overrides:
addAll in class BasicEList
Parameters:
collection - the collection of objects to be added.
Throws:
UnsupportedOperationException - always because it's not supported.
See Also:
BasicEList.addAllUnique(Collection)

addAll

public boolean addAll(int index,
                      Collection collection)
Throws an exception.

Specified by:
addAll in interface List
Overrides:
addAll in class BasicEList
Parameters:
index - the index at which to add.
collection - the collection of objects to be added.
Returns:
whether any objects were added.
Throws:
UnsupportedOperationException - always because it's not supported.
See Also:
BasicEList.addAllUnique(int, Collection)

remove

public boolean remove(Object object)
Throws an exception.

Specified by:
remove in interface List
Overrides:
remove in class BasicEList
Parameters:
object - the object to be removed.
Returns:
whether the object was actually contained by the list.
Throws:
UnsupportedOperationException - always because it's not supported.

remove

public Object remove(int index)
Throws an exception.

Specified by:
remove in interface List
Overrides:
remove in class BasicEList
Parameters:
index - the position of the object to remove.
Returns:
the removed object.
Throws:
UnsupportedOperationException - always because it's not supported.

removeAll

public boolean removeAll(Collection collection)
Throws an exception.

Specified by:
removeAll in interface List
Overrides:
removeAll in class BasicEList
Parameters:
collection - the collection of objects to be removed.
Returns:
whether any object was actually contained by the list.
Throws:
UnsupportedOperationException - always because it's not supported.

retainAll

public boolean retainAll(Collection collection)
Throws an exception.

Specified by:
retainAll in interface List
Overrides:
retainAll in class BasicEList
Parameters:
collection - the collection of objects to be retained.
Returns:
whether any object was actually removed.
Throws:
UnsupportedOperationException - always because it's not supported.

clear

public void clear()
Throws an exception.

Specified by:
clear in interface List
Overrides:
clear in class BasicEList
Throws:
UnsupportedOperationException - always because it's not supported.

move

public void move(int index,
                 Object object)
Throws an exception.

Specified by:
move in interface EList
Overrides:
move in class BasicEList
Parameters:
index - the new position for the object in the list.
object - the object to be moved.
Throws:
UnsupportedOperationException - always because it's not supported.

move

public Object move(int targetIndex,
                   int sourceIndex)
Throws an exception.

Specified by:
move in interface EList
Overrides:
move in class BasicEList
Parameters:
targetIndex - the new position for the object in the list.
sourceIndex - the old position of the object in the list.
Returns:
the moved object.
Throws:
UnsupportedOperationException - always because it's not supported.

shrink

public void shrink()
Throws an exception.

Overrides:
shrink in class BasicEList
Throws:
UnsupportedOperationException - always because it's not supported.
See Also:
BasicEList.grow(int)

grow

public void grow(int minimumCapacity)
Throws an exception.

Overrides:
grow in class BasicEList
Throws:
UnsupportedOperationException - always because it's not supported.
See Also:
BasicEList.shrink()

iterator

public Iterator iterator()
Returns the basic iterator.

Specified by:
iterator in interface List
Overrides:
iterator in class BasicEList
Returns:
the basic iterator.
See Also:
BasicEList.EIterator

listIterator

public ListIterator listIterator()
Returns the basic list iterator.

Specified by:
listIterator in interface List
Overrides:
listIterator in class BasicEList
Returns:
the basic list iterator.
See Also:
BasicEList.EListIterator

listIterator

public ListIterator listIterator(int index)
Returns the basic list iterator advanced to the index.

Specified by:
listIterator in interface List
Overrides:
listIterator in class BasicEList
Parameters:
index - the starting index.
Returns:
the basic list iterator.
See Also:
BasicEList.EListIterator

Copyright 2001-2006 IBM Corporation and others.
All Rights Reserved.