Package org.apache.jena.sys
Class Serializer
java.lang.Object
org.apache.jena.sys.Serializer
The injection points for the Node and Triple
Serializable
process.
This class is public to allow system initialization to inject
handler functions for Node
and Triple
.
See also Quad
.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionReturn the current node serializer replacement function.Return the current triple serializer replacement function.static void
setNodeSerializer
(Function<Node, Object> writeReplaceFunction) Set the node serializer replacement function.static void
setTripleSerializer
(Function<Triple, Object> writeReplaceFunction) Set the triple serializer replacement function.
-
Constructor Details
-
Serializer
public Serializer()
-
-
Method Details
-
setNodeSerializer
Set the node serializer replacement function. This is a function called byNode.writeReplace
during theSerializable
process. The return is an object used in place ofNode
for the serialization.ANY-ACCESS-MODIFIER Object writeReplace() throws ObjectStreamException;
The returned object must provide
ANY-ACCESS-MODIFIER Object readResolve() throws ObjectStreamException;
where "Object" is a
Node
.- See Also:
-
getNodeSerializer
Return the current node serializer replacement function. -
setTripleSerializer
Set the triple serializer replacement function. This is a function called byTriple.writeReplace
during theSerializable
process. The return is an object used in place ofTriple
for the serialization.ANY-ACCESS-MODIFIER Object writeReplace() throws ObjectStreamException;
The returned object must provide
ANY-ACCESS-MODIFIER Object readResolve() throws ObjectStreamException;
where "Object" is a
Triple
.- See Also:
-
getTripleSerializer
Return the current triple serializer replacement function.
-