Search in sources :

Example 16 with ArrayDataSerializableFactory

use of com.hazelcast.internal.serialization.impl.ArrayDataSerializableFactory in project hazelcast by hazelcast.

the class ManagementDataSerializerHook method createFactory.

@Override
@SuppressWarnings("unchecked")
public DataSerializableFactory createFactory() {
    ConstructorFunction<Integer, IdentifiedDataSerializable>[] constructors = new ConstructorFunction[LEN];
    constructors[UPDATE_MAP_CONFIG] = arg -> new UpdateMapConfigOperation();
    constructors[SET_LICENSE] = arg -> new SetLicenseOperation();
    constructors[CHANGE_CLUSTER_STATE] = arg -> new ChangeClusterStateOperation();
    constructors[UPDATE_PERMISSION_CONFIG_OPERATION] = arg -> new UpdatePermissionConfigOperation();
    constructors[RELOAD_CONFIG_OPERATION] = arg -> new ReloadConfigOperation();
    constructors[UPDATE_CONFIG_OPERATION] = arg -> new UpdateConfigOperation();
    return new ArrayDataSerializableFactory(constructors);
}
Also used : UpdatePermissionConfigOperation(com.hazelcast.internal.management.operation.UpdatePermissionConfigOperation) SetLicenseOperation(com.hazelcast.internal.management.operation.SetLicenseOperation) ReloadConfigOperation(com.hazelcast.internal.management.operation.ReloadConfigOperation) UpdateConfigOperation(com.hazelcast.internal.management.operation.UpdateConfigOperation) UpdateMapConfigOperation(com.hazelcast.internal.management.operation.UpdateMapConfigOperation) ArrayDataSerializableFactory(com.hazelcast.internal.serialization.impl.ArrayDataSerializableFactory) ConstructorFunction(com.hazelcast.internal.util.ConstructorFunction) ChangeClusterStateOperation(com.hazelcast.internal.management.operation.ChangeClusterStateOperation)

Example 17 with ArrayDataSerializableFactory

use of com.hazelcast.internal.serialization.impl.ArrayDataSerializableFactory in project hazelcast by hazelcast.

the class UserCodeDeploymentSerializerHook method createFactory.

@Override
public DataSerializableFactory createFactory() {
    ConstructorFunction<Integer, IdentifiedDataSerializable>[] constructors = new ConstructorFunction[LEN];
    constructors[CLASS_DATA] = new ConstructorFunction<Integer, IdentifiedDataSerializable>() {

        @Override
        public IdentifiedDataSerializable createNew(Integer arg) {
            return new ClassData();
        }
    };
    constructors[CLASS_DATA_FINDER_OP] = new ConstructorFunction<Integer, IdentifiedDataSerializable>() {

        @Override
        public IdentifiedDataSerializable createNew(Integer arg) {
            return new ClassDataFinderOperation();
        }
    };
    constructors[DEPLOY_CLASSES_OP] = new ConstructorFunction<Integer, IdentifiedDataSerializable>() {

        @Override
        public IdentifiedDataSerializable createNew(Integer arg) {
            return new DeployClassesOperation();
        }
    };
    return new ArrayDataSerializableFactory(constructors);
}
Also used : IdentifiedDataSerializable(com.hazelcast.nio.serialization.IdentifiedDataSerializable) DeployClassesOperation(com.hazelcast.internal.usercodedeployment.impl.operation.DeployClassesOperation) ClassDataFinderOperation(com.hazelcast.internal.usercodedeployment.impl.operation.ClassDataFinderOperation) ArrayDataSerializableFactory(com.hazelcast.internal.serialization.impl.ArrayDataSerializableFactory) ConstructorFunction(com.hazelcast.internal.util.ConstructorFunction)

Aggregations

ArrayDataSerializableFactory (com.hazelcast.internal.serialization.impl.ArrayDataSerializableFactory)17 ConstructorFunction (com.hazelcast.internal.util.ConstructorFunction)16 IdentifiedDataSerializable (com.hazelcast.nio.serialization.IdentifiedDataSerializable)6 HazelcastExpiryPolicy (com.hazelcast.cache.HazelcastExpiryPolicy)1 CachePartitionLostEventFilter (com.hazelcast.cache.impl.event.CachePartitionLostEventFilter)1 CacheEventJournalSubscribeOperation (com.hazelcast.cache.impl.journal.CacheEventJournalSubscribeOperation)1 InternalEventJournalCacheEvent (com.hazelcast.cache.impl.journal.InternalEventJournalCacheEvent)1 DefaultCacheEntryView (com.hazelcast.cache.impl.merge.entry.DefaultCacheEntryView)1 AddCacheConfigOperation (com.hazelcast.cache.impl.operation.AddCacheConfigOperation)1 CacheBackupEntryProcessorOperation (com.hazelcast.cache.impl.operation.CacheBackupEntryProcessorOperation)1 CacheClearBackupOperation (com.hazelcast.cache.impl.operation.CacheClearBackupOperation)1 CacheClearOperation (com.hazelcast.cache.impl.operation.CacheClearOperation)1 CacheClearOperationFactory (com.hazelcast.cache.impl.operation.CacheClearOperationFactory)1 CacheContainsKeyOperation (com.hazelcast.cache.impl.operation.CacheContainsKeyOperation)1 CacheDestroyOperation (com.hazelcast.cache.impl.operation.CacheDestroyOperation)1 CacheEntryProcessorOperation (com.hazelcast.cache.impl.operation.CacheEntryProcessorOperation)1 CacheExpireBatchBackupOperation (com.hazelcast.cache.impl.operation.CacheExpireBatchBackupOperation)1 CacheFetchEntriesOperation (com.hazelcast.cache.impl.operation.CacheFetchEntriesOperation)1 CacheFetchKeysOperation (com.hazelcast.cache.impl.operation.CacheFetchKeysOperation)1 CacheGetAllOperation (com.hazelcast.cache.impl.operation.CacheGetAllOperation)1