Apache Geode Native C++ Reference 1.15.0
apache::geode::client::TypeRegistry Class Reference

Registry for custom serializable types, both PDXSerializable and DataSerializable. More...

#include <TypeRegistry.hpp>

Public Member Functions

void registerPdxSerializer (std::shared_ptr< PdxSerializer > pdxSerializer)
 Register the PDX serializer which can handle serialization for instances of user domain classes. More...
 
void registerPdxType (TypeFactoryMethodPdx creationFunction)
 register an Pdx instance factory method for a given type. More...
 
void registerType (TypeFactoryMethod creationFunction, int32_t id)
 register an instance factory method for a given type. More...
 

Detailed Description

Registry for custom serializable types, both PDXSerializable and DataSerializable.

Member Function Documentation

◆ registerPdxSerializer()

void apache::geode::client::TypeRegistry::registerPdxSerializer ( std::shared_ptr< PdxSerializer pdxSerializer)

Register the PDX serializer which can handle serialization for instances of user domain classes.

See also
PdxSerializer

◆ registerPdxType()

void apache::geode::client::TypeRegistry::registerPdxType ( TypeFactoryMethodPdx  creationFunction)

register an Pdx instance factory method for a given type.

Exceptions
IllegalStateExceptionif the typeName has already been registered, or there is an error in registering the type; check errno for more information in the latter case.

◆ registerType()

void apache::geode::client::TypeRegistry::registerType ( TypeFactoryMethod  creationFunction,
int32_t  id 
)

register an instance factory method for a given type.

During registration the factory will be invoked to extract the typeId to associate with this function.

Exceptions
IllegalStateExceptionif the typeId has already been registered, or there is an error in registering the type; check errno for more information in the latter case.

Apache Geode C++ Cache API Documentation