|
IBM WebSphereTM eXtreme Scale, Release 8.6 API Specification |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface SerializerAccessor
Each BackingMap has a SerializerAccessor associated with it, which includes references to custom DataSerializers that eXtreme Scale uses to serialize, inflate and query data.
The MapSerializerPlugin BackingMap plug-in is the BackingMap's main interface which provides metadata and a DataSerializer for both the map's key and value.
The DataObjectContext associated with a SerializerAccessor provides methods for creating and converting key and value data objects.
A MapSerializerPlugin can be registered programmatically using the registerMapSerializer
when using a local, in-memory ObjectGrid. For a distributed ObjectGrid, a MapSerializer
is configured using the ObjectGrid descriptor XML file as a BackingMap plug-in.
Example MapSerializerPlugin configuration:
<backingMapPluginCollections> <backingMapPluginCollection id="plugin_Order"> <bean id="MapSerializerPlugin" className="com.ibm.websphere.objectgrid.plugins.io.BasicMapSerializer"> <property name="keyDataSerializerClass" type="java.lang.String" value="com.ibm.websphere.samples.xs.serializer.proto.ProtoKeySerializer" /> <property name="keyProperties" type="java.lang.String" value="type=com.ibm.websphere.samples.xs.serializer.proto.DataObjects$OrderKey" /> <property name="valueDataSerializerClass" type="java.lang.String" value="com.ibm.websphere.samples.xs.serializer.proto.ProtoValueSerializer" /> <property name="valueProperties" type="java.lang.String" value="type=com.ibm.websphere.samples.xs.serializer.proto.DataObjects$Order" /> </bean> ...
Method Summary | |
---|---|
BackingMap |
getBackingMap()
Retrieve the BackingMap associated with this SerializerAccessor. |
DataObjectContext |
getDefaultContext()
Retrieve the default DataObjectContext associated with this SerializerAccessor |
MapSerializerPlugin |
getMapSerializerPlugin()
Retrieve the MapSerializerPlugin instance. |
void |
registerMapSerializerPlugin(MapSerializerPlugin mapSerializerPlugin)
Register a new MapSerializerPlugin for the cache entry key for a local, in-memory ObjectGrid instance. |
MapSerializerPlugin |
unregisterMapSerializerPlugin()
Remove the MapSerializerPlugin instance. |
Method Detail |
---|
void registerMapSerializerPlugin(MapSerializerPlugin mapSerializerPlugin)
A MapSerializerPlugin can only be registered before the BackingMap has been initialized.
A MapSerializerPlugin that implements the BackingMapLifecycleListener
is automatically added
as if the BackingMap.addMapEventListener(EventListener)
method was called. Any previous
MapSerializer which implements BackingMapLifecycleListener
is removed as if
the BackingMap.removeMapEventListener(EventListener)
method was called.
mapSerializerPlugin
- the MapSerializerPlugin plug-in.MapSerializerPlugin unregisterMapSerializerPlugin()
BackingMapLifecycleListener
, it is removed as if
the BackingMap.removeMapEventListener(EventListener)
method was called.
MapSerializerPlugin getMapSerializerPlugin()
BackingMap getBackingMap()
DataObjectContext getDefaultContext()
|
IBM WebSphereTM eXtreme Scale, Release 8.6 API Specification |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |