Package com.hazelcast.multimap.operations

Examples of com.hazelcast.multimap.operations.CountOperation


    public CountRequest(String name, Data key) {
        super(name, key);
    }

    protected Operation prepareOperation() {
        return new CountOperation(name, key);
    }
View Full Code Here


    protected int valueCountInternal(Data key){
        throwExceptionIfNull(key);
        Collection<MultiMapRecord> coll = txMap.get(key);
        if (coll == null){
            CountOperation operation = new CountOperation(name, key);
            try {
                int partitionId = getNodeEngine().getPartitionService().getPartitionId(key);
                Future<Integer> f = getNodeEngine().getOperationService().invokeOnPartition(MultiMapService.SERVICE_NAME, operation, partitionId);
                return f.get();
            } catch (Throwable t) {
View Full Code Here

                return new ContainsEntryOperation();
            }
        };
        constructors[COUNT] = new ConstructorFunction<Integer, IdentifiedDataSerializable>() {
            public IdentifiedDataSerializable createNew(Integer arg) {
                return new CountOperation();
            }
        };
        constructors[ENTRY_SET] = new ConstructorFunction<Integer, IdentifiedDataSerializable>() {
            public IdentifiedDataSerializable createNew(Integer arg) {
                return new EntrySetOperation();
View Full Code Here

    protected int valueCountInternal(Data key) {
        throwExceptionIfNull(key);
        Collection<MultiMapRecord> coll = txMap.get(key);
        if (coll == null) {
            CountOperation operation = new CountOperation(name, key);
            try {
                int partitionId = getNodeEngine().getPartitionService().getPartitionId(key);
                final OperationService operationService = getNodeEngine().getOperationService();
                Future<Integer> f = operationService
                        .invokeOnPartition(MultiMapService.SERVICE_NAME, operation, partitionId);
View Full Code Here

    public CountRequest(String name, Data key) {
        super(name, key);
    }

    protected Operation prepareOperation() {
        return new CountOperation(name, key);
    }
View Full Code Here

        getService().publishMultiMapEvent(name, eventType, numberOfAffectedEntries);
    }

    protected Integer countInternal(Data dataKey) {
        try {
            CountOperation operation = new CountOperation(name, dataKey);
            return invoke(operation, dataKey);
        } catch (Throwable throwable) {
            throw ExceptionUtil.rethrow(throwable);
        }
    }
View Full Code Here

TOP

Related Classes of com.hazelcast.multimap.operations.CountOperation

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.