Search in sources :

Example 1 with EntryProcessor

use of com.hazelcast.map.EntryProcessor in project hazelcast by hazelcast.

the class MapExecuteOnAllKeysMessageTask method createOperationFactory.

@Override
protected OperationFactory createOperationFactory() {
    MapOperationProvider operationProvider = getOperationProvider(parameters.name);
    EntryProcessor entryProcessor = serializationService.toObject(parameters.entryProcessor);
    return operationProvider.createPartitionWideEntryOperationFactory(parameters.name, entryProcessor);
}
Also used : EntryProcessor(com.hazelcast.map.EntryProcessor) MapOperationProvider(com.hazelcast.map.impl.operation.MapOperationProvider)

Example 2 with EntryProcessor

use of com.hazelcast.map.EntryProcessor in project hazelcast by hazelcast.

the class MapExecuteOnKeysMessageTask method createOperationFactory.

@Override
protected OperationFactory createOperationFactory() {
    EntryProcessor entryProcessor = serializationService.toObject(parameters.entryProcessor);
    Set<Data> keys = new HashSet<Data>(parameters.keys);
    return new MultipleEntryOperationFactory(parameters.name, keys, entryProcessor);
}
Also used : EntryProcessor(com.hazelcast.map.EntryProcessor) MultipleEntryOperationFactory(com.hazelcast.map.impl.operation.MultipleEntryOperationFactory) Data(com.hazelcast.nio.serialization.Data) HashSet(java.util.HashSet)

Example 3 with EntryProcessor

use of com.hazelcast.map.EntryProcessor in project hazelcast by hazelcast.

the class MapExecuteWithPredicateMessageTask method createOperationFactory.

@Override
protected OperationFactory createOperationFactory() {
    MapOperationProvider operationProvider = getOperationProvider(parameters.name);
    EntryProcessor entryProcessor = serializationService.toObject(parameters.entryProcessor);
    Predicate predicate = serializationService.toObject(parameters.predicate);
    return operationProvider.createPartitionWideEntryWithPredicateOperationFactory(parameters.name, entryProcessor, predicate);
}
Also used : EntryProcessor(com.hazelcast.map.EntryProcessor) MapOperationProvider(com.hazelcast.map.impl.operation.MapOperationProvider) Predicate(com.hazelcast.query.Predicate)

Example 4 with EntryProcessor

use of com.hazelcast.map.EntryProcessor in project hazelcast by hazelcast.

the class MapSubmitToKeyMessageTask method prepareOperation.

@Override
protected Operation prepareOperation() {
    EntryProcessor processor = serializationService.toObject(parameters.entryProcessor);
    MapOperationProvider operationProvider = getMapOperationProvider(parameters.name);
    MapOperation op = operationProvider.createEntryOperation(parameters.name, parameters.key, processor);
    op.setThreadId(parameters.threadId);
    return op;
}
Also used : EntryProcessor(com.hazelcast.map.EntryProcessor) MapOperationProvider(com.hazelcast.map.impl.operation.MapOperationProvider) MapOperation(com.hazelcast.map.impl.operation.MapOperation)

Example 5 with EntryProcessor

use of com.hazelcast.map.EntryProcessor in project hazelcast by hazelcast.

the class MapExecuteOnKeyMessageTask method prepareOperation.

@Override
protected Operation prepareOperation() {
    EntryProcessor processor = serializationService.toObject(parameters.entryProcessor);
    MapOperationProvider operationProvider = getMapOperationProvider(parameters.name);
    MapOperation op = operationProvider.createEntryOperation(parameters.name, parameters.key, processor);
    op.setThreadId(parameters.threadId);
    return op;
}
Also used : EntryProcessor(com.hazelcast.map.EntryProcessor) MapOperationProvider(com.hazelcast.map.impl.operation.MapOperationProvider) MapOperation(com.hazelcast.map.impl.operation.MapOperation)

Aggregations

EntryProcessor (com.hazelcast.map.EntryProcessor)5 MapOperationProvider (com.hazelcast.map.impl.operation.MapOperationProvider)4 MapOperation (com.hazelcast.map.impl.operation.MapOperation)2 MultipleEntryOperationFactory (com.hazelcast.map.impl.operation.MultipleEntryOperationFactory)1 Data (com.hazelcast.nio.serialization.Data)1 Predicate (com.hazelcast.query.Predicate)1 HashSet (java.util.HashSet)1