Oracle Fusion Middleware Java API Reference for Oracle Extension SDK Reference
11g Release 1 (11.1.1)

E13403-03

oracle.javatools.util
Class ImmutableList<E>

java.lang.Object
  extended by java.util.AbstractCollection<E>
      extended by java.util.AbstractList<E>
          extended by oracle.javatools.util.ImmutableList<E>
All Implemented Interfaces:
java.lang.Iterable<E>, java.util.Collection<E>, java.util.List<E>

public class ImmutableList<E>
extends java.util.AbstractList<E>

An immutable list which wraps an array without copying.


Field Summary
 
Fields inherited from class java.util.AbstractList
modCount
 
Constructor Summary
ImmutableList(E... elements)
           
ImmutableList(E element)
           
 
Method Summary
 boolean add(java.lang.Object o)
           
 boolean addAll(java.util.Collection c)
           
 void clear()
           
 boolean contains(java.lang.Object o)
           
 boolean containsAll(java.util.Collection<?> collection)
           
 E get(int index)
           
 boolean isEmpty()
           
 java.util.Iterator<E> iterator()
           
 boolean remove(java.lang.Object o)
           
 boolean removeAll(java.util.Collection c)
           
 boolean retainAll(java.util.Collection c)
           
 int size()
           
 java.lang.Object[] toArray()
           
<T> T[]
toArray(T[] array)
           
 
Methods inherited from class java.util.AbstractList
add, addAll, equals, hashCode, indexOf, lastIndexOf, listIterator, listIterator, remove, removeRange, set, subList
 
Methods inherited from class java.util.AbstractCollection
toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ImmutableList

public ImmutableList(E element)

ImmutableList

public ImmutableList(E... elements)
Method Detail

size

public int size()
Specified by:
size in interface java.util.Collection<E>
Specified by:
size in interface java.util.List<E>
Specified by:
size in class java.util.AbstractCollection<E>

isEmpty

public boolean isEmpty()
Specified by:
isEmpty in interface java.util.Collection<E>
Specified by:
isEmpty in interface java.util.List<E>
Overrides:
isEmpty in class java.util.AbstractCollection<E>

contains

public boolean contains(java.lang.Object o)
Specified by:
contains in interface java.util.Collection<E>
Specified by:
contains in interface java.util.List<E>
Overrides:
contains in class java.util.AbstractCollection<E>

containsAll

public boolean containsAll(java.util.Collection<?> collection)
Specified by:
containsAll in interface java.util.Collection<E>
Specified by:
containsAll in interface java.util.List<E>
Overrides:
containsAll in class java.util.AbstractCollection<E>

get

public E get(int index)
Specified by:
get in interface java.util.List<E>
Specified by:
get in class java.util.AbstractList<E>

iterator

public java.util.Iterator<E> iterator()
Specified by:
iterator in interface java.lang.Iterable<E>
Specified by:
iterator in interface java.util.Collection<E>
Specified by:
iterator in interface java.util.List<E>
Overrides:
iterator in class java.util.AbstractList<E>

toArray

public java.lang.Object[] toArray()
Specified by:
toArray in interface java.util.Collection<E>
Specified by:
toArray in interface java.util.List<E>
Overrides:
toArray in class java.util.AbstractCollection<E>

toArray

public <T> T[] toArray(T[] array)
Specified by:
toArray in interface java.util.Collection<E>
Specified by:
toArray in interface java.util.List<E>
Overrides:
toArray in class java.util.AbstractCollection<E>

add

public boolean add(java.lang.Object o)
Specified by:
add in interface java.util.Collection<E>
Specified by:
add in interface java.util.List<E>
Overrides:
add in class java.util.AbstractList<E>

remove

public boolean remove(java.lang.Object o)
Specified by:
remove in interface java.util.Collection<E>
Specified by:
remove in interface java.util.List<E>
Overrides:
remove in class java.util.AbstractCollection<E>

addAll

public boolean addAll(java.util.Collection c)
Specified by:
addAll in interface java.util.Collection<E>
Specified by:
addAll in interface java.util.List<E>
Overrides:
addAll in class java.util.AbstractCollection<E>

removeAll

public boolean removeAll(java.util.Collection c)
Specified by:
removeAll in interface java.util.Collection<E>
Specified by:
removeAll in interface java.util.List<E>
Overrides:
removeAll in class java.util.AbstractCollection<E>

retainAll

public boolean retainAll(java.util.Collection c)
Specified by:
retainAll in interface java.util.Collection<E>
Specified by:
retainAll in interface java.util.List<E>
Overrides:
retainAll in class java.util.AbstractCollection<E>

clear

public void clear()
Specified by:
clear in interface java.util.Collection<E>
Specified by:
clear in interface java.util.List<E>
Overrides:
clear in class java.util.AbstractList<E>

Oracle Fusion Middleware Java API Reference for Oracle Extension SDK Reference
11g Release 1 (11.1.1)

E13403-03

Copyright © 1997, 2009, Oracle. All rights reserved.