activemq-cpp-3.4.0

decaf::util::List< E > Class Template Reference

An ordered collection (also known as a sequence). More...

#include <src/main/decaf/util/List.h>

Inheritance diagram for decaf::util::List< E >:

Public Member Functions

 List ()
virtual ~List ()
virtual ListIterator< E > * listIterator ()=0
virtual ListIterator< E > * listIterator () const =0
virtual ListIterator< E > * listIterator (int index)=0
virtual ListIterator< E > * listIterator (int index) const =0
virtual int indexOf (const E &value) const =0
 Returns the index of the first occurrence of the specified element in this list, or -1 if this list does not contain the element.
virtual int lastIndexOf (const E &value) const =0
 Returns the index of the last occurrence of the specified element in this list, or -1 if this list does not contain the element.
virtual E get (int index) const =0
 Gets the element contained at position passed.
virtual E set (int index, const E &element)=0
 Replaces the element at the specified position in this list with the specified element.
virtual void add (int index, const E &element)=0
 Inserts the specified element at the specified position in this list.
virtual bool addAll (int index, const Collection< E > &source)=0
 Inserts all of the elements in the specified collection into this list at the specified position (optional operation).
virtual E removeAt (int index)=0
 Removes the element at the specified position in this list.

Detailed Description

template<typename E>
class decaf::util::List< E >

An ordered collection (also known as a sequence).

The user of this interface has precise control over where in the list each element is inserted. The user can access elements by their integer index (position in the list), and search for elements in the list.

Unlike sets, lists typically allow duplicate elements. More formally, lists typically allow pairs of elements e1 and e2 such that e1.equals(e2), and they typically allow multiple null elements if they allow null elements at all. It is not inconceivable that someone might wish to implement a list that prohibits duplicates, by throwing runtime exceptions when the user attempts to insert them, but we expect this usage to be rare.


Constructor & Destructor Documentation

template<typename E>
decaf::util::List< E >::List ( ) [inline]
template<typename E>
virtual decaf::util::List< E >::~List ( ) [inline, virtual]

Member Function Documentation

template<typename E>
virtual void decaf::util::List< E >::add ( int  index,
const E &  element 
) [pure virtual]

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).

Parameters:
indexThe index at which the specified element is to be inserted.
elementThe element to be inserted in this List.
Exceptions:
IndexOutOfBoundsExceptionif the index is greater than size of the List.
UnsupportedOperationExceptioif this is an unmodifiable collection.
NullPointerExceptionif the Collection is a container of pointers and does not allow NULL values.
IllegalArgumentExceptionif some property of the element prevents it from being added to this collection
IllegalStateExceptionif the element cannot be added at this time due to insertion restrictions.

Implemented in decaf::util::AbstractSequentialList< E >, decaf::util::ArrayList< E >, decaf::util::concurrent::CopyOnWriteArrayList< E >, decaf::util::LinkedList< E >, decaf::util::StlList< E >, decaf::util::AbstractSequentialList< Pointer< Transport > >, decaf::util::AbstractSequentialList< cms::MessageConsumer * >, decaf::util::AbstractSequentialList< CompositeTask * >, decaf::util::AbstractSequentialList< URI >, decaf::util::AbstractSequentialList< Pointer< MessageDispatch > >, decaf::util::AbstractSequentialList< Pointer< DestinationInfo > >, decaf::util::AbstractSequentialList< PrimitiveValueNode >, decaf::util::AbstractSequentialList< Pointer< Command > >, decaf::util::AbstractSequentialList< Pointer< BackupTransport > >, decaf::util::AbstractSequentialList< cms::MessageProducer * >, decaf::util::AbstractSequentialList< cms::Destination * >, decaf::util::AbstractSequentialList< cms::Session * >, decaf::util::AbstractSequentialList< cms::Connection * >, decaf::util::concurrent::CopyOnWriteArrayList< ServiceListener * >, decaf::util::LinkedList< Pointer< Transport > >, decaf::util::LinkedList< cms::MessageConsumer * >, decaf::util::LinkedList< CompositeTask * >, decaf::util::LinkedList< URI >, decaf::util::LinkedList< Pointer< MessageDispatch > >, decaf::util::LinkedList< Pointer< DestinationInfo > >, decaf::util::LinkedList< PrimitiveValueNode >, decaf::util::LinkedList< Pointer< Command > >, decaf::util::LinkedList< Pointer< BackupTransport > >, decaf::util::LinkedList< cms::MessageProducer * >, decaf::util::LinkedList< cms::Destination * >, decaf::util::LinkedList< cms::Session * >, and decaf::util::LinkedList< cms::Connection * >.

template<typename E>
virtual bool decaf::util::List< E >::addAll ( int  index,
const Collection< E > &  source 
) [pure virtual]

Inserts all of the elements in the specified collection into this list at the specified position (optional operation).

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 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. (Note that this will occur if the specified collection is this list, and it's nonempty.)

Parameters:
indexThe index at which to insert the first element from the specified collection
sourceThe Collection containing elements to be added to this list
Returns:
true if this list changed as a result of the call
Exceptions:
IndexOutOfBoundsExceptionif the index given is less than zero or greater than the List size.
UnsupportedOperationExceptioif this is an unmodifiable collection.
NullPointerExceptionif the Collection is a container of pointers and does not allow NULL values.
IllegalArgumentExceptionif some property of the element prevents it from being added to this collection
IllegalStateExceptionif the element cannot be added at this time due to insertion restrictions.

Implemented in decaf::util::AbstractList< E >, decaf::util::AbstractSequentialList< E >, decaf::util::ArrayList< E >, decaf::util::concurrent::CopyOnWriteArrayList< E >, decaf::util::LinkedList< E >, decaf::util::StlList< E >, decaf::util::AbstractList< Pointer< Transport > >, decaf::util::AbstractList< cms::MessageConsumer * >, decaf::util::AbstractList< CompositeTask * >, decaf::util::AbstractList< URI >, decaf::util::AbstractList< Pointer< MessageDispatch > >, decaf::util::AbstractList< Pointer< DestinationInfo > >, decaf::util::AbstractList< PrimitiveValueNode >, decaf::util::AbstractList< Pointer< Command > >, decaf::util::AbstractList< Pointer< BackupTransport > >, decaf::util::AbstractList< cms::MessageProducer * >, decaf::util::AbstractList< cms::Destination * >, decaf::util::AbstractList< cms::Session * >, decaf::util::AbstractList< cms::Connection * >, decaf::util::AbstractSequentialList< Pointer< Transport > >, decaf::util::AbstractSequentialList< cms::MessageConsumer * >, decaf::util::AbstractSequentialList< CompositeTask * >, decaf::util::AbstractSequentialList< URI >, decaf::util::AbstractSequentialList< Pointer< MessageDispatch > >, decaf::util::AbstractSequentialList< Pointer< DestinationInfo > >, decaf::util::AbstractSequentialList< PrimitiveValueNode >, decaf::util::AbstractSequentialList< Pointer< Command > >, decaf::util::AbstractSequentialList< Pointer< BackupTransport > >, decaf::util::AbstractSequentialList< cms::MessageProducer * >, decaf::util::AbstractSequentialList< cms::Destination * >, decaf::util::AbstractSequentialList< cms::Session * >, decaf::util::AbstractSequentialList< cms::Connection * >, decaf::util::concurrent::CopyOnWriteArrayList< ServiceListener * >, decaf::util::LinkedList< Pointer< Transport > >, decaf::util::LinkedList< cms::MessageConsumer * >, decaf::util::LinkedList< CompositeTask * >, decaf::util::LinkedList< URI >, decaf::util::LinkedList< Pointer< MessageDispatch > >, decaf::util::LinkedList< Pointer< DestinationInfo > >, decaf::util::LinkedList< PrimitiveValueNode >, decaf::util::LinkedList< Pointer< Command > >, decaf::util::LinkedList< Pointer< BackupTransport > >, decaf::util::LinkedList< cms::MessageProducer * >, decaf::util::LinkedList< cms::Destination * >, decaf::util::LinkedList< cms::Session * >, and decaf::util::LinkedList< cms::Connection * >.

template<typename E>
virtual E decaf::util::List< E >::get ( int  index) const [pure virtual]

Gets the element contained at position passed.

Parameters:
indexThe position to get.
Returns:
value at index specified.
Exceptions:
IndexOutOfBoundsExceptionif the index given is less than zero or greater than the List size.

Implemented in decaf::util::AbstractSequentialList< E >, decaf::util::ArrayList< E >, decaf::util::concurrent::CopyOnWriteArrayList< E >, decaf::util::LinkedList< E >, decaf::util::StlList< E >, decaf::util::AbstractSequentialList< Pointer< Transport > >, decaf::util::AbstractSequentialList< cms::MessageConsumer * >, decaf::util::AbstractSequentialList< CompositeTask * >, decaf::util::AbstractSequentialList< URI >, decaf::util::AbstractSequentialList< Pointer< MessageDispatch > >, decaf::util::AbstractSequentialList< Pointer< DestinationInfo > >, decaf::util::AbstractSequentialList< PrimitiveValueNode >, decaf::util::AbstractSequentialList< Pointer< Command > >, decaf::util::AbstractSequentialList< Pointer< BackupTransport > >, decaf::util::AbstractSequentialList< cms::MessageProducer * >, decaf::util::AbstractSequentialList< cms::Destination * >, decaf::util::AbstractSequentialList< cms::Session * >, decaf::util::AbstractSequentialList< cms::Connection * >, decaf::util::concurrent::CopyOnWriteArrayList< ServiceListener * >, decaf::util::LinkedList< Pointer< Transport > >, decaf::util::LinkedList< cms::MessageConsumer * >, decaf::util::LinkedList< CompositeTask * >, decaf::util::LinkedList< URI >, decaf::util::LinkedList< Pointer< MessageDispatch > >, decaf::util::LinkedList< Pointer< DestinationInfo > >, decaf::util::LinkedList< PrimitiveValueNode >, decaf::util::LinkedList< Pointer< Command > >, decaf::util::LinkedList< Pointer< BackupTransport > >, decaf::util::LinkedList< cms::MessageProducer * >, decaf::util::LinkedList< cms::Destination * >, decaf::util::LinkedList< cms::Session * >, and decaf::util::LinkedList< cms::Connection * >.

template<typename E>
virtual int decaf::util::List< E >::indexOf ( const E &  value) const [pure virtual]

Returns the index of the first occurrence of the specified element in this list, or -1 if this list does not contain the element.

More formally, returns the lowest index i such that get(i) == value, or -1 if there is no such index.

Parameters:
valueThe element to search for in this List.
Returns:
the index of the first occurrence of the specified element in this list,
Exceptions:
NullPointerExceptionif the Collection is a container of pointers and does not allow NULL values.

Implemented in decaf::util::AbstractList< E >, decaf::util::ArrayList< E >, decaf::util::concurrent::CopyOnWriteArrayList< E >, decaf::util::LinkedList< E >, decaf::util::StlList< E >, decaf::util::AbstractList< Pointer< Transport > >, decaf::util::AbstractList< cms::MessageConsumer * >, decaf::util::AbstractList< CompositeTask * >, decaf::util::AbstractList< URI >, decaf::util::AbstractList< Pointer< MessageDispatch > >, decaf::util::AbstractList< Pointer< DestinationInfo > >, decaf::util::AbstractList< PrimitiveValueNode >, decaf::util::AbstractList< Pointer< Command > >, decaf::util::AbstractList< Pointer< BackupTransport > >, decaf::util::AbstractList< cms::MessageProducer * >, decaf::util::AbstractList< cms::Destination * >, decaf::util::AbstractList< cms::Session * >, decaf::util::AbstractList< cms::Connection * >, decaf::util::concurrent::CopyOnWriteArrayList< ServiceListener * >, decaf::util::LinkedList< Pointer< Transport > >, decaf::util::LinkedList< cms::MessageConsumer * >, decaf::util::LinkedList< CompositeTask * >, decaf::util::LinkedList< URI >, decaf::util::LinkedList< Pointer< MessageDispatch > >, decaf::util::LinkedList< Pointer< DestinationInfo > >, decaf::util::LinkedList< PrimitiveValueNode >, decaf::util::LinkedList< Pointer< Command > >, decaf::util::LinkedList< Pointer< BackupTransport > >, decaf::util::LinkedList< cms::MessageProducer * >, decaf::util::LinkedList< cms::Destination * >, decaf::util::LinkedList< cms::Session * >, and decaf::util::LinkedList< cms::Connection * >.

template<typename E>
virtual int decaf::util::List< E >::lastIndexOf ( const E &  value) const [pure virtual]

Returns the index of the last occurrence of the specified element in this list, or -1 if this list does not contain the element.

More formally, returns the highest index i such that get(i) == value or -1 if there is no such index.

Parameters:
valueThe element to search for in this List.
Returns:
the index of the last occurrence of the specified element in this list.
Exceptions:
NullPointerExceptionif the Collection is a container of pointers and does not allow NULL values.

Implemented in decaf::util::AbstractList< E >, decaf::util::ArrayList< E >, decaf::util::concurrent::CopyOnWriteArrayList< E >, decaf::util::LinkedList< E >, decaf::util::StlList< E >, decaf::util::AbstractList< Pointer< Transport > >, decaf::util::AbstractList< cms::MessageConsumer * >, decaf::util::AbstractList< CompositeTask * >, decaf::util::AbstractList< URI >, decaf::util::AbstractList< Pointer< MessageDispatch > >, decaf::util::AbstractList< Pointer< DestinationInfo > >, decaf::util::AbstractList< PrimitiveValueNode >, decaf::util::AbstractList< Pointer< Command > >, decaf::util::AbstractList< Pointer< BackupTransport > >, decaf::util::AbstractList< cms::MessageProducer * >, decaf::util::AbstractList< cms::Destination * >, decaf::util::AbstractList< cms::Session * >, decaf::util::AbstractList< cms::Connection * >, decaf::util::concurrent::CopyOnWriteArrayList< ServiceListener * >, decaf::util::LinkedList< Pointer< Transport > >, decaf::util::LinkedList< cms::MessageConsumer * >, decaf::util::LinkedList< CompositeTask * >, decaf::util::LinkedList< URI >, decaf::util::LinkedList< Pointer< MessageDispatch > >, decaf::util::LinkedList< Pointer< DestinationInfo > >, decaf::util::LinkedList< PrimitiveValueNode >, decaf::util::LinkedList< Pointer< Command > >, decaf::util::LinkedList< Pointer< BackupTransport > >, decaf::util::LinkedList< cms::MessageProducer * >, decaf::util::LinkedList< cms::Destination * >, decaf::util::LinkedList< cms::Session * >, and decaf::util::LinkedList< cms::Connection * >.

template<typename E>
virtual ListIterator<E>* decaf::util::List< E >::listIterator ( ) [pure virtual]
Returns:
a list iterator over the elements in this list (in proper sequence).

Implemented in decaf::util::AbstractList< E >, decaf::util::AbstractSequentialList< E >, decaf::util::concurrent::CopyOnWriteArrayList< E >, decaf::util::StlList< E >, decaf::util::AbstractList< Pointer< Transport > >, decaf::util::AbstractList< cms::MessageConsumer * >, decaf::util::AbstractList< CompositeTask * >, decaf::util::AbstractList< URI >, decaf::util::AbstractList< Pointer< MessageDispatch > >, decaf::util::AbstractList< Pointer< DestinationInfo > >, decaf::util::AbstractList< PrimitiveValueNode >, decaf::util::AbstractList< Pointer< Command > >, decaf::util::AbstractList< Pointer< BackupTransport > >, decaf::util::AbstractList< cms::MessageProducer * >, decaf::util::AbstractList< cms::Destination * >, decaf::util::AbstractList< cms::Session * >, decaf::util::AbstractList< cms::Connection * >, decaf::util::AbstractSequentialList< Pointer< Transport > >, decaf::util::AbstractSequentialList< cms::MessageConsumer * >, decaf::util::AbstractSequentialList< CompositeTask * >, decaf::util::AbstractSequentialList< URI >, decaf::util::AbstractSequentialList< Pointer< MessageDispatch > >, decaf::util::AbstractSequentialList< Pointer< DestinationInfo > >, decaf::util::AbstractSequentialList< PrimitiveValueNode >, decaf::util::AbstractSequentialList< Pointer< Command > >, decaf::util::AbstractSequentialList< Pointer< BackupTransport > >, decaf::util::AbstractSequentialList< cms::MessageProducer * >, decaf::util::AbstractSequentialList< cms::Destination * >, decaf::util::AbstractSequentialList< cms::Session * >, decaf::util::AbstractSequentialList< cms::Connection * >, and decaf::util::concurrent::CopyOnWriteArrayList< ServiceListener * >.

template<typename E>
virtual ListIterator<E>* decaf::util::List< E >::listIterator ( int  index) const [pure virtual]

Implemented in decaf::util::AbstractList< E >, decaf::util::AbstractSequentialList< E >, decaf::util::concurrent::CopyOnWriteArrayList< E >, decaf::util::LinkedList< E >, decaf::util::StlList< E >, decaf::util::AbstractList< Pointer< Transport > >, decaf::util::AbstractList< cms::MessageConsumer * >, decaf::util::AbstractList< CompositeTask * >, decaf::util::AbstractList< URI >, decaf::util::AbstractList< Pointer< MessageDispatch > >, decaf::util::AbstractList< Pointer< DestinationInfo > >, decaf::util::AbstractList< PrimitiveValueNode >, decaf::util::AbstractList< Pointer< Command > >, decaf::util::AbstractList< Pointer< BackupTransport > >, decaf::util::AbstractList< cms::MessageProducer * >, decaf::util::AbstractList< cms::Destination * >, decaf::util::AbstractList< cms::Session * >, decaf::util::AbstractList< cms::Connection * >, decaf::util::AbstractSequentialList< Pointer< Transport > >, decaf::util::AbstractSequentialList< cms::MessageConsumer * >, decaf::util::AbstractSequentialList< CompositeTask * >, decaf::util::AbstractSequentialList< URI >, decaf::util::AbstractSequentialList< Pointer< MessageDispatch > >, decaf::util::AbstractSequentialList< Pointer< DestinationInfo > >, decaf::util::AbstractSequentialList< PrimitiveValueNode >, decaf::util::AbstractSequentialList< Pointer< Command > >, decaf::util::AbstractSequentialList< Pointer< BackupTransport > >, decaf::util::AbstractSequentialList< cms::MessageProducer * >, decaf::util::AbstractSequentialList< cms::Destination * >, decaf::util::AbstractSequentialList< cms::Session * >, decaf::util::AbstractSequentialList< cms::Connection * >, decaf::util::concurrent::CopyOnWriteArrayList< ServiceListener * >, decaf::util::LinkedList< Pointer< Transport > >, decaf::util::LinkedList< cms::MessageConsumer * >, decaf::util::LinkedList< CompositeTask * >, decaf::util::LinkedList< URI >, decaf::util::LinkedList< Pointer< MessageDispatch > >, decaf::util::LinkedList< Pointer< DestinationInfo > >, decaf::util::LinkedList< PrimitiveValueNode >, decaf::util::LinkedList< Pointer< Command > >, decaf::util::LinkedList< Pointer< BackupTransport > >, decaf::util::LinkedList< cms::MessageProducer * >, decaf::util::LinkedList< cms::Destination * >, decaf::util::LinkedList< cms::Session * >, and decaf::util::LinkedList< cms::Connection * >.

template<typename E>
virtual ListIterator<E>* decaf::util::List< E >::listIterator ( ) const [pure virtual]

Implemented in decaf::util::AbstractList< E >, decaf::util::AbstractSequentialList< E >, decaf::util::concurrent::CopyOnWriteArrayList< E >, decaf::util::StlList< E >, decaf::util::AbstractList< Pointer< Transport > >, decaf::util::AbstractList< cms::MessageConsumer * >, decaf::util::AbstractList< CompositeTask * >, decaf::util::AbstractList< URI >, decaf::util::AbstractList< Pointer< MessageDispatch > >, decaf::util::AbstractList< Pointer< DestinationInfo > >, decaf::util::AbstractList< PrimitiveValueNode >, decaf::util::AbstractList< Pointer< Command > >, decaf::util::AbstractList< Pointer< BackupTransport > >, decaf::util::AbstractList< cms::MessageProducer * >, decaf::util::AbstractList< cms::Destination * >, decaf::util::AbstractList< cms::Session * >, decaf::util::AbstractList< cms::Connection * >, decaf::util::AbstractSequentialList< Pointer< Transport > >, decaf::util::AbstractSequentialList< cms::MessageConsumer * >, decaf::util::AbstractSequentialList< CompositeTask * >, decaf::util::AbstractSequentialList< URI >, decaf::util::AbstractSequentialList< Pointer< MessageDispatch > >, decaf::util::AbstractSequentialList< Pointer< DestinationInfo > >, decaf::util::AbstractSequentialList< PrimitiveValueNode >, decaf::util::AbstractSequentialList< Pointer< Command > >, decaf::util::AbstractSequentialList< Pointer< BackupTransport > >, decaf::util::AbstractSequentialList< cms::MessageProducer * >, decaf::util::AbstractSequentialList< cms::Destination * >, decaf::util::AbstractSequentialList< cms::Session * >, decaf::util::AbstractSequentialList< cms::Connection * >, and decaf::util::concurrent::CopyOnWriteArrayList< ServiceListener * >.

template<typename E>
virtual ListIterator<E>* decaf::util::List< E >::listIterator ( int  index) [pure virtual]
Parameters:
indexindex of first element to be returned from the list iterator (by a call to the next method).
Returns:
a list iterator of the elements in this list (in proper sequence), starting at the specified position in this list. The specified index indicates the first element that would be returned by an initial call to next. An initial call to previous would return the element with the specified index minus one.
Exceptions:
IndexOutOfBoundsExceptionif the index is out of range (index < 0 || index > size())

Implemented in decaf::util::AbstractList< E >, decaf::util::AbstractSequentialList< E >, decaf::util::concurrent::CopyOnWriteArrayList< E >, decaf::util::LinkedList< E >, decaf::util::StlList< E >, decaf::util::AbstractList< Pointer< Transport > >, decaf::util::AbstractList< cms::MessageConsumer * >, decaf::util::AbstractList< CompositeTask * >, decaf::util::AbstractList< URI >, decaf::util::AbstractList< Pointer< MessageDispatch > >, decaf::util::AbstractList< Pointer< DestinationInfo > >, decaf::util::AbstractList< PrimitiveValueNode >, decaf::util::AbstractList< Pointer< Command > >, decaf::util::AbstractList< Pointer< BackupTransport > >, decaf::util::AbstractList< cms::MessageProducer * >, decaf::util::AbstractList< cms::Destination * >, decaf::util::AbstractList< cms::Session * >, decaf::util::AbstractList< cms::Connection * >, decaf::util::AbstractSequentialList< Pointer< Transport > >, decaf::util::AbstractSequentialList< cms::MessageConsumer * >, decaf::util::AbstractSequentialList< CompositeTask * >, decaf::util::AbstractSequentialList< URI >, decaf::util::AbstractSequentialList< Pointer< MessageDispatch > >, decaf::util::AbstractSequentialList< Pointer< DestinationInfo > >, decaf::util::AbstractSequentialList< PrimitiveValueNode >, decaf::util::AbstractSequentialList< Pointer< Command > >, decaf::util::AbstractSequentialList< Pointer< BackupTransport > >, decaf::util::AbstractSequentialList< cms::MessageProducer * >, decaf::util::AbstractSequentialList< cms::Destination * >, decaf::util::AbstractSequentialList< cms::Session * >, decaf::util::AbstractSequentialList< cms::Connection * >, decaf::util::concurrent::CopyOnWriteArrayList< ServiceListener * >, decaf::util::LinkedList< Pointer< Transport > >, decaf::util::LinkedList< cms::MessageConsumer * >, decaf::util::LinkedList< CompositeTask * >, decaf::util::LinkedList< URI >, decaf::util::LinkedList< Pointer< MessageDispatch > >, decaf::util::LinkedList< Pointer< DestinationInfo > >, decaf::util::LinkedList< PrimitiveValueNode >, decaf::util::LinkedList< Pointer< Command > >, decaf::util::LinkedList< Pointer< BackupTransport > >, decaf::util::LinkedList< cms::MessageProducer * >, decaf::util::LinkedList< cms::Destination * >, decaf::util::LinkedList< cms::Session * >, and decaf::util::LinkedList< cms::Connection * >.

template<typename E>
virtual E decaf::util::List< E >::removeAt ( int  index) [pure virtual]

Removes the element at the specified position in this list.

Shifts any subsequent elements to the left (subtracts one from their indices). Returns the element that was removed from the list.

Parameters:
index- the index of the element to be removed.
Returns:
the element previously at the specified position.
Exceptions:
IndexOutOfBoundsExceptionif the index given is less than zero or greater than the List size.
UnsupportedOperationExceptioif this is an unmodifiable collection.

Implemented in decaf::util::AbstractList< E >, decaf::util::AbstractSequentialList< E >, decaf::util::ArrayList< E >, decaf::util::concurrent::CopyOnWriteArrayList< E >, decaf::util::StlList< E >, decaf::util::AbstractList< Pointer< Transport > >, decaf::util::AbstractList< cms::MessageConsumer * >, decaf::util::AbstractList< CompositeTask * >, decaf::util::AbstractList< URI >, decaf::util::AbstractList< Pointer< MessageDispatch > >, decaf::util::AbstractList< Pointer< DestinationInfo > >, decaf::util::AbstractList< PrimitiveValueNode >, decaf::util::AbstractList< Pointer< Command > >, decaf::util::AbstractList< Pointer< BackupTransport > >, decaf::util::AbstractList< cms::MessageProducer * >, decaf::util::AbstractList< cms::Destination * >, decaf::util::AbstractList< cms::Session * >, decaf::util::AbstractList< cms::Connection * >, decaf::util::AbstractSequentialList< Pointer< Transport > >, decaf::util::AbstractSequentialList< cms::MessageConsumer * >, decaf::util::AbstractSequentialList< CompositeTask * >, decaf::util::AbstractSequentialList< URI >, decaf::util::AbstractSequentialList< Pointer< MessageDispatch > >, decaf::util::AbstractSequentialList< Pointer< DestinationInfo > >, decaf::util::AbstractSequentialList< PrimitiveValueNode >, decaf::util::AbstractSequentialList< Pointer< Command > >, decaf::util::AbstractSequentialList< Pointer< BackupTransport > >, decaf::util::AbstractSequentialList< cms::MessageProducer * >, decaf::util::AbstractSequentialList< cms::Destination * >, decaf::util::AbstractSequentialList< cms::Session * >, decaf::util::AbstractSequentialList< cms::Connection * >, and decaf::util::concurrent::CopyOnWriteArrayList< ServiceListener * >.

template<typename E>
virtual E decaf::util::List< E >::set ( int  index,
const E &  element 
) [pure virtual]

Replaces the element at the specified position in this list with the specified element.

Parameters:
indexThe index of the element to replace.
elementThe element to be stored at the specified position.
Returns:
the element previously at the specified position.
Exceptions:
IndexOutOfBoundsExceptionif the index given is less than zero or greater than the List size.
UnsupportedOperationExceptioif this is an unmodifiable collection.
NullPointerExceptionif the Collection is a container of pointers and does not allow NULL values.
IllegalArgumentExceptionif some property of the element prevents it from being added to this collection
IllegalStateExceptionif the element cannot be added at this time due to insertion restrictions.

Implemented in decaf::util::AbstractSequentialList< E >, decaf::util::ArrayList< E >, decaf::util::concurrent::CopyOnWriteArrayList< E >, decaf::util::LinkedList< E >, decaf::util::StlList< E >, decaf::util::AbstractSequentialList< Pointer< Transport > >, decaf::util::AbstractSequentialList< cms::MessageConsumer * >, decaf::util::AbstractSequentialList< CompositeTask * >, decaf::util::AbstractSequentialList< URI >, decaf::util::AbstractSequentialList< Pointer< MessageDispatch > >, decaf::util::AbstractSequentialList< Pointer< DestinationInfo > >, decaf::util::AbstractSequentialList< PrimitiveValueNode >, decaf::util::AbstractSequentialList< Pointer< Command > >, decaf::util::AbstractSequentialList< Pointer< BackupTransport > >, decaf::util::AbstractSequentialList< cms::MessageProducer * >, decaf::util::AbstractSequentialList< cms::Destination * >, decaf::util::AbstractSequentialList< cms::Session * >, decaf::util::AbstractSequentialList< cms::Connection * >, decaf::util::concurrent::CopyOnWriteArrayList< ServiceListener * >, decaf::util::LinkedList< Pointer< Transport > >, decaf::util::LinkedList< cms::MessageConsumer * >, decaf::util::LinkedList< CompositeTask * >, decaf::util::LinkedList< URI >, decaf::util::LinkedList< Pointer< MessageDispatch > >, decaf::util::LinkedList< Pointer< DestinationInfo > >, decaf::util::LinkedList< PrimitiveValueNode >, decaf::util::LinkedList< Pointer< Command > >, decaf::util::LinkedList< Pointer< BackupTransport > >, decaf::util::LinkedList< cms::MessageProducer * >, decaf::util::LinkedList< cms::Destination * >, decaf::util::LinkedList< cms::Session * >, and decaf::util::LinkedList< cms::Connection * >.


The documentation for this class was generated from the following file: