|
Oracle® Fusion Middleware Java API Reference for Oracle Coherence 12c (12.1.3.0.0) E47890-01 |
|||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||
java.lang.Object
com.tangosol.io.pof.ConfigurablePofContext
com.tangosol.io.pof.SafeConfigurablePofContext
public class SafeConfigurablePofContext
SafeConfigurablePofContext is an extension of ConfigurablePofContext that can serialize and deserialize any valid POF user type, even those that have not been explicitly configured, as well as any Java serializable types (Serializable, Externalizable, or ExternalizableLite).
Important note: this PofContext has the following limitations:
For user types that have been explicitly configured, the SafeConfigurablePofContext behaves identical to the ConfigurablePofContext.
| Nested Class Summary | |
|---|---|
class |
SafeConfigurablePofContext.JavaPofSerializerSerializer used for Serializable and ExternalizableLite objects. |
class |
SafeConfigurablePofContext.SafePofSerializerSerializer used for objects implementing the PortableObject interface. |
| Nested classes/interfaces inherited from class com.tangosol.io.pof.ConfigurablePofContext |
|---|
ConfigurablePofContext.PofConfig |
| Field Summary | |
|---|---|
static int |
TYPE_PORTABLEThe type identifier for objects that implement the PortableObject interface. |
static int |
TYPE_SERIALIZABLEThe type identifier for Java Serializable (including the ExternalizableLite format) objects. |
| Fields inherited from class com.tangosol.io.pof.ConfigurablePofContext |
|---|
DEFAULT_RESOURCE, PROPERTY_CONFIG |
| Constructor Summary | |
|---|---|
SafeConfigurablePofContext()Default constructor. |
|
SafeConfigurablePofContext(java.lang.String sLocator)Create a SafeConfigurablePofContext that will load configuration information from the specified locator. |
|
SafeConfigurablePofContext(XmlElement xml)Create a SafeConfigurablePofContext that will use the passed configuration information. |
|
| Method Summary | |
|---|---|
java.lang.Class |
getClass(int nTypeId)Determine the class associated with the given user type identifier. |
protected int |
getGenericTypeId(java.lang.Class clz)For user types that are not registered in the POF configuration used by this PofContext, determine if the user type can be serialized using POF, otherwise determine if the user type can be serialized using the traditional (pre-POF) Coherence Java Serialization format that supports Java Serializable and ExternalizableLite objects. |
PofSerializer |
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. |
int |
getUserTypeIdentifier(java.lang.Class clz)Determine the user type identifier associated with the given class. |
int |
getUserTypeIdentifier(java.lang.String sClass)Determine the user type identifier associated with the given class name. |
boolean |
isUserType(java.lang.Class clz)Determine if the given class is a user type known to this PofContext. |
boolean |
isUserType(java.lang.String sClass)Determine if the class with the given name is a user type known to this PofContext. |
| Field Detail |
|---|
public static final int TYPE_PORTABLE
public static final int TYPE_SERIALIZABLE
| Constructor Detail |
|---|
public SafeConfigurablePofContext()
Create a default SafeConfigurablePofContext that will load configuration information from the locator specified in ConfigurablePofContext.DEFAULT_RESOURCE.
public SafeConfigurablePofContext(java.lang.String sLocator)
sLocator - the locator that specifies the location of the PofContext configuration file; the locator is either a valid path or a URLpublic SafeConfigurablePofContext(XmlElement xml)
xml - an XmlElement containing information in the format of a configuration file used by SafeConfigurablePofContext| Method Detail |
|---|
public PofSerializer getPofSerializer(int nTypeId)
getPofSerializer in interface PofContextgetPofSerializer in class ConfigurablePofContextnTypeId - the type identifier of the user type that can be serialized and deserialized using the returned PofSerializer; must be non-negativepublic java.lang.Class getClass(int nTypeId)
getClass in interface PofContextgetClass in class ConfigurablePofContextnTypeId - the user type identifier; must be non-negativepublic int getUserTypeIdentifier(java.lang.Class clz)
getUserTypeIdentifier in interface PofContextgetUserTypeIdentifier in class ConfigurablePofContextclz - a user type class; must not be nullpublic int getUserTypeIdentifier(java.lang.String sClass)
getUserTypeIdentifier in interface PofContextgetUserTypeIdentifier in class ConfigurablePofContextsClass - the name of a user type class; must not be nullpublic boolean isUserType(java.lang.Class clz)
isUserType in interface PofContextisUserType in class ConfigurablePofContextclz - the class to test; must not be nullpublic boolean isUserType(java.lang.String sClass)
isUserType in interface PofContextisUserType in class ConfigurablePofContextsClass - the name of the class to test; must not be nullprotected int getGenericTypeId(java.lang.Class clz)
clz - a user type class that is not configured in this PofContext
|
Oracle® Fusion Middleware Java API Reference for Oracle Coherence 12c (12.1.3.0.0) E47890-01 |
|||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||