com.hazelcast.core
Interface ICollection<E>

Type Parameters:
E - item
All Superinterfaces:
Collection<E>, DistributedObject, Iterable<E>
All Known Subinterfaces:
IList<E>, IQueue<E>, ISet<E>
All Known Implementing Classes:
AbstractClientCollectionProxy, ClientListProxy, ClientQueueProxy, ClientSetProxy, ListProxyImpl, QueueProxyImpl, SetProxyImpl

public interface ICollection<E>
extends Collection<E>, DistributedObject

Concurrent, distributed, partitioned, listenable collection.


Method Summary
 String addItemListener(ItemListener<E> listener, boolean includeValue)
          Adds an item listener for this collection.
 String getName()
          Returns the name of this collection.
 boolean removeItemListener(String registrationId)
          Removes the specified item listener.
 
Methods inherited from interface java.util.Collection
add, addAll, clear, contains, containsAll, equals, hashCode, isEmpty, iterator, remove, removeAll, retainAll, size, toArray, toArray
 
Methods inherited from interface com.hazelcast.core.DistributedObject
destroy, getId, getPartitionKey, getServiceName
 

Method Detail

getName

String getName()
Returns the name of this collection.

Specified by:
getName in interface DistributedObject
Returns:
the name of this collection

addItemListener

String addItemListener(ItemListener<E> listener,
                       boolean includeValue)
Adds an item listener for this collection. Listener will be notified for all collection add/remove events.

Parameters:
listener - the item listener
includeValue - true if the updated item should be passed to the item listener, false otherwise.
Returns:
returns the registration id.

removeItemListener

boolean removeItemListener(String registrationId)
Removes the specified item listener. Returns silently if the specified listener was not added before.

Parameters:
registrationId - Id of the listener registration.
Returns:
true if the item listener is removed, false otherwise


Copyright © 2015 Hazelcast, Inc.. All Rights Reserved.