Package com.tangosol.util
Class NullImplementation.NullPofContext
java.lang.Object
com.tangosol.util.NullImplementation.NullPofContext
- All Implemented Interfaces:
PofContext,Serializer
- Enclosing class:
NullImplementation
An implementation of PofContext that does nothing.
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final NullImplementation.NullPofContextSingleton instance. -
Method Summary
Modifier and TypeMethodDescriptionDeserialize an object from a ReadBuffer by reading its state using the specified BufferInput object.getClass(int nTypeId) Determine the class associated with the given user type identifier.getClassName(int nTypeId) Determine the name of the class associated with the given user type identifier.getPofSerializer(int nTypeId) Return a PofSerializer that can be used to serialize and deserialize an object of the specified user type to and from a POF stream.intDetermine the user type identifier associated with the given class.intDetermine the user type identifier associated with the given object.intgetUserTypeIdentifier(String sClass) Determine the user type identifier associated with the given class name.booleanisUserType(Class clz) Determine if the given class is a user type known to this PofContext.booleanisUserType(Object o) Determine if the given object is of a user type known to this PofContext.booleanisUserType(String sClass) Determine if the class with the given name is a user type known to this PofContext.voidserialize(WriteBuffer.BufferOutput out, Object o) Serialize an object to a WriteBuffer by writing its state using the specified BufferOutput object.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.tangosol.io.pof.PofContext
isPreferJavaTimeMethods inherited from interface com.tangosol.io.Serializer
deserialize, getName
-
Field Details
-
INSTANCE
Singleton instance.
-
-
Method Details
-
getPofSerializer
Return a PofSerializer that can be used to serialize and deserialize an object of the specified user type to and from a POF stream.- Specified by:
getPofSerializerin interfacePofContext- Parameters:
nTypeId- the type identifier of the user type that can be serialized and deserialized using the returned PofSerializer; must be non-negative- Returns:
- a PofSerializer for the specified user type
-
getUserTypeIdentifier
Determine the user type identifier associated with the given object.- Specified by:
getUserTypeIdentifierin interfacePofContext- Parameters:
o- an instance of a user type; must not be null- Returns:
- the type identifier of the user type associated with the given object
-
getUserTypeIdentifier
Determine the user type identifier associated with the given class.- Specified by:
getUserTypeIdentifierin interfacePofContext- Parameters:
clz- a user type class; must not be null- Returns:
- the type identifier of the user type associated with the given class
-
getUserTypeIdentifier
Determine the user type identifier associated with the given class name.- Specified by:
getUserTypeIdentifierin interfacePofContext- Parameters:
sClass- the name of a user type class; must not be null- Returns:
- the type identifier of the user type associated with the given class name
-
getClassName
Determine the name of the class associated with the given user type identifier.- Specified by:
getClassNamein interfacePofContext- Parameters:
nTypeId- the user type identifier; must be non-negative- Returns:
- the name of the class associated with the specified user type identifier
-
getClass
Determine the class associated with the given user type identifier.- Specified by:
getClassin interfacePofContext- Parameters:
nTypeId- the user type identifier; must be non-negative- Returns:
- the class associated with the specified user type identifier
-
isUserType
Determine if the given object is of a user type known to this PofContext.- Specified by:
isUserTypein interfacePofContext- Parameters:
o- the object to test; must not be null- Returns:
- true iff the specified object is of a valid user type
-
isUserType
Determine if the given class is a user type known to this PofContext.- Specified by:
isUserTypein interfacePofContext- Parameters:
clz- the class to test; must not be null- Returns:
- true iff the specified class is a valid user type
-
isUserType
Determine if the class with the given name is a user type known to this PofContext.- Specified by:
isUserTypein interfacePofContext- Parameters:
sClass- the name of the class to test; must not be null- Returns:
- true iff the class with the specified name is a valid user type
-
serialize
Serialize an object to a WriteBuffer by writing its state using the specified BufferOutput object.Note: Starting with Coherence 12.2.1 classes that need to designate an alternative object to be used by the Serializer when writing the object to the buffer should implement the
SerializationSupport.writeReplace()method.- Specified by:
serializein interfaceSerializer- Parameters:
out- the BufferOutput with which to write the object's stateo- the object to serialize- Throws:
IOException- if an I/O error occurs
-
deserialize
Deserialize an object from a ReadBuffer by reading its state using the specified BufferInput object.Note: Starting with Coherence 12.2.1 classes that need to designate an alternative object to be returned by the Serializer after an object is deserialized from the buffer should implement the
SerializationSupport.readResolve()method.- Specified by:
deserializein interfaceSerializer- Parameters:
in- the BufferInput with which to read the object's state- Returns:
- the deserialized user type instance
- Throws:
IOException- if an I/O error occurs
-