Gemfire JavaDocs
Class Pdx
- java.lang.Object
-
- org.apache.geode.management.configuration.AbstractConfiguration<PdxInfo>
-
- org.apache.geode.management.configuration.Pdx
-
- All Implemented Interfaces:
java.io.Serializable
,Identifiable<java.lang.String>
,JsonSerializable
@Experimental public class Pdx extends AbstractConfiguration<PdxInfo>
Used to configure PDX serialization for a cache.- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
PDX_ENDPOINT
static java.lang.String
PDX_ID
-
Fields inherited from class org.apache.geode.management.configuration.AbstractConfiguration
CLUSTER
-
-
Constructor Summary
Constructors Constructor Description Pdx()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description AutoSerializer
getAutoSerializer()
java.lang.String
getDiskStoreName()
java.lang.String
getId()
ReturnsPDX_ID
Links
getLinks()
ClassName
getPdxSerializer()
java.lang.Boolean
isIgnoreUnreadFields()
java.lang.Boolean
isReadSerialized()
void
setAutoSerializer(AutoSerializer autoSerializer)
void
setDiskStoreName(java.lang.String diskStoreName)
Setting a non-null diskStoreName causes the Pdx information to be persisted to the named disk store.void
setIgnoreUnreadFields(java.lang.Boolean ignoreUnreadFields)
Setting ignoreUnreadFields to true can save memory during pdx deserialization but if the deserialized object is reserialized then the unread field data will be lost.void
setPdxSerializer(ClassName pdxSerializer)
void
setReadSerialized(java.lang.Boolean readSerialized)
Setting readSerialized to true causes any pdx deserialization to produce instances of org.apache.geode.pdx.PdxInstance interface in the gemfire-core module instead of a domain class instance.-
Methods inherited from class org.apache.geode.management.configuration.AbstractConfiguration
getCreationCommandType, getGroup, getGroupName, isCluster, isGlobalRuntime
-
-
-
-
Field Detail
-
PDX_ID
public static final java.lang.String PDX_ID
- See Also:
- Constant Field Values
-
PDX_ENDPOINT
public static final java.lang.String PDX_ENDPOINT
- See Also:
- Constant Field Values
-
-
Method Detail
-
getId
public java.lang.String getId()
ReturnsPDX_ID
- Specified by:
getId
in interfaceIdentifiable<java.lang.String>
- Specified by:
getId
in classAbstractConfiguration<PdxInfo>
- Returns:
- an identifier uniquely identifying this Object.
-
getLinks
public Links getLinks()
- Specified by:
getLinks
in classAbstractConfiguration<PdxInfo>
-
getAutoSerializer
public AutoSerializer getAutoSerializer()
-
setAutoSerializer
public void setAutoSerializer(AutoSerializer autoSerializer)
- Parameters:
autoSerializer
- theAutoSerializer
to use- Throws:
java.lang.IllegalArgumentException
- if a pdxSerializer has already been set
-
isReadSerialized
public java.lang.Boolean isReadSerialized()
-
setReadSerialized
public void setReadSerialized(java.lang.Boolean readSerialized)
Setting readSerialized to true causes any pdx deserialization to produce instances of org.apache.geode.pdx.PdxInstance interface in the gemfire-core module instead of a domain class instance.- Parameters:
readSerialized
- a Boolean specifying whether Pdx deserialization should produce only instances of org.apache.geode.pdx.PdxInstance
-
getPdxSerializer
public ClassName getPdxSerializer()
-
setPdxSerializer
public void setPdxSerializer(ClassName pdxSerializer)
- Parameters:
pdxSerializer
- the class name given must implement the org.apache.geode.pdx.PdxSerializer interface from the gemfire-core module.- Throws:
java.lang.IllegalArgumentException
- if an autoSerializer has already been set
-
isIgnoreUnreadFields
public java.lang.Boolean isIgnoreUnreadFields()
-
setIgnoreUnreadFields
public void setIgnoreUnreadFields(java.lang.Boolean ignoreUnreadFields)
Setting ignoreUnreadFields to true can save memory during pdx deserialization but if the deserialized object is reserialized then the unread field data will be lost. Unread fields will only exist if a class serialized with pdx has multiple versions.- Parameters:
ignoreUnreadFields
- a Boolean specifying if unread fields should be ignored when deserializing
-
getDiskStoreName
public java.lang.String getDiskStoreName()
-
setDiskStoreName
public void setDiskStoreName(java.lang.String diskStoreName)
Setting a non-null diskStoreName causes the Pdx information to be persisted to the named disk store. To configure Pdx to use the default disk store, set the diskStoreName to "DEFAULT".- Parameters:
diskStoreName
- the name of the disk store to persist Pdx information to
-
-