Search in sources :

Example 11 with SerializableList

use of com.hazelcast.spi.impl.SerializableList in project hazelcast by hazelcast.

the class CollectionGetAllOperation method run.

@Override
public void run() throws Exception {
    CollectionContainer collectionContainer = getOrCreateContainer();
    List<Data> all = collectionContainer.getAll();
    response = new SerializableList(all);
}
Also used : SerializableList(com.hazelcast.spi.impl.SerializableList) CollectionContainer(com.hazelcast.collection.impl.collection.CollectionContainer) Data(com.hazelcast.nio.serialization.Data)

Example 12 with SerializableList

use of com.hazelcast.spi.impl.SerializableList in project hazelcast by hazelcast.

the class ListSubOperation method run.

@Override
public void run() throws Exception {
    ListContainer listContainer = getOrCreateListContainer();
    List<Data> sub = listContainer.sub(from, to);
    response = new SerializableList(sub);
}
Also used : SerializableList(com.hazelcast.spi.impl.SerializableList) ListContainer(com.hazelcast.collection.impl.list.ListContainer) Data(com.hazelcast.nio.serialization.Data)

Example 13 with SerializableList

use of com.hazelcast.spi.impl.SerializableList in project hazelcast by hazelcast.

the class QueueProxySupport method drainInternal.

Collection<Data> drainInternal(int maxSize) {
    DrainOperation operation = new DrainOperation(name, maxSize);
    SerializableList collectionContainer = invokeAndGet(operation);
    return collectionContainer.getCollection();
}
Also used : DrainOperation(com.hazelcast.collection.impl.queue.operations.DrainOperation) SerializableList(com.hazelcast.spi.impl.SerializableList)

Example 14 with SerializableList

use of com.hazelcast.spi.impl.SerializableList in project hazelcast by hazelcast.

the class IteratorOperation method run.

@Override
public void run() {
    QueueContainer queueContainer = getContainer();
    List<Data> dataList = queueContainer.getAsDataList();
    response = new SerializableList(dataList);
}
Also used : SerializableList(com.hazelcast.spi.impl.SerializableList) QueueContainer(com.hazelcast.collection.impl.queue.QueueContainer) Data(com.hazelcast.nio.serialization.Data)

Aggregations

SerializableList (com.hazelcast.spi.impl.SerializableList)14 Data (com.hazelcast.nio.serialization.Data)11 ArrayList (java.util.ArrayList)4 QueueContainer (com.hazelcast.collection.impl.queue.QueueContainer)2 NodeEngine (com.hazelcast.spi.NodeEngine)2 UnmodifiableLazyList (com.hazelcast.spi.impl.UnmodifiableLazyList)2 SerializationService (com.hazelcast.spi.serialization.SerializationService)2 CollectionContainer (com.hazelcast.collection.impl.collection.CollectionContainer)1 CollectionGetAllOperation (com.hazelcast.collection.impl.collection.operations.CollectionGetAllOperation)1 ListContainer (com.hazelcast.collection.impl.list.ListContainer)1 ListSubOperation (com.hazelcast.collection.impl.list.operations.ListSubOperation)1 DrainOperation (com.hazelcast.collection.impl.queue.operations.DrainOperation)1 IteratorOperation (com.hazelcast.collection.impl.queue.operations.IteratorOperation)1 HazelcastInstanceNotActiveException (com.hazelcast.core.HazelcastInstanceNotActiveException)1 Member (com.hazelcast.core.Member)1 MemberLeftException (com.hazelcast.core.MemberLeftException)1 ClusterService (com.hazelcast.internal.cluster.ClusterService)1 Address (com.hazelcast.nio.Address)1 InternalCompletableFuture (com.hazelcast.spi.InternalCompletableFuture)1 OperationService (com.hazelcast.spi.OperationService)1