Class ContextBuildingNumberSerializer
java.lang.Object
cz.cvut.kbss.jsonld.serialization.serializer.compact.NumberSerializer
cz.cvut.kbss.jsonld.serialization.serializer.context.ContextBuildingNumberSerializer
- All Implemented Interfaces:
Configurable,ValueSerializer<Number>
Serializes numeric values and builds a corresponding context item for them.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionserialize(Number value, SerializationContext<Number> ctx) Serializes the specified value, returning a JSON-LD node representing it.Methods inherited from class cz.cvut.kbss.jsonld.serialization.serializer.compact.NumberSerializer
getDatatype, getSupportedTypesMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface cz.cvut.kbss.jsonld.serialization.serializer.ValueSerializer
configure
-
Constructor Details
-
ContextBuildingNumberSerializer
public ContextBuildingNumberSerializer()
-
-
Method Details
-
serialize
Description copied from interface:ValueSerializerSerializes the specified value, returning a JSON-LD node representing it.Note that if the value is a singular, the returned node should also contain the identifier of the serialized attribute (available through the provided serialization context).
- Specified by:
serializein interfaceValueSerializer<Number>- Overrides:
serializein classNumberSerializer- Parameters:
value- Value to serializectx- Serialization context- Returns:
- Serialization result
-