net.rim.device.api.collection
Interface ChainableCollection

All Superinterfaces:
CollectionEventSource, CollectionListener
All Known Implementing Classes:
BigSortedReadableList, BigUnsortedReadableList, IntSortedReadableList, LongSortedReadableList, ReadableListCombiner, SortedReadableList, UnsortedReadableList

public interface ChainableCollection
extends CollectionEventSource, CollectionListener

Base functionality for a collection that can receive and emit collection events.

Example

    private CollectionListenerManager _listeners = new CollectionListenerManager();

    public void addCollectionListener( Object listener ) {
        _listeners.addCollectionListener( listener ):
    }

    public void removeCollectionListener( Object listener ) {
        _listeners.removeCollectionListener( listener ):
    }

    // To fire events, do something like this:
    _listeners.fireReset( collection );

    // The CollectionListener implementations need to do the special handling
    // of the objects and then propagate the events on.  If the event isn't
    // handled, then it should be propagated, like this:
    public void reset( Collection collection ) {
        _listeners.fireReset( collection );
    }
  

See Also:
CollectionListener, CollectionEventSource

Method Summary
 
Methods inherited from interface net.rim.device.api.collection.CollectionEventSource
addCollectionListener, removeCollectionListener
 
Methods inherited from interface net.rim.device.api.collection.CollectionListener
elementAdded, elementRemoved, elementUpdated, reset
 






Copyright 1999-2011 Research In Motion Limited. 295 Phillip Street, Waterloo, Ontario, Canada, N2L 3W8. All Rights Reserved.
Java is a trademark of Oracle America Inc. in the US and other countries.
Legal