Annotation Type SerializedConverter
@Target({TYPE,METHOD,FIELD})
@Retention(RUNTIME)
@Repeatable(SerializedConverters.class)
public @interface SerializedConverter
A SerializedConverter is used to serialize an object's value into a database binary, character, or XML field.
This annotation allows a named converter that can be used in mappings.
A converter must be be uniquely identified by name and can be defined at
the class level and can be specified within an Entity,
MappedSuperclass and Embeddable class.
The usage of a SerializedConverter is always specified via the Converter annotation and
is supported on a Basic, or ElementCollection mapping.
- See Also:
- Author:
- James Sutherland
-
Required Element Summary
-
Optional Element Summary
Modifier and TypeOptional ElementDescriptionClass<? extends Serializer>
The serializer class to be used.Allows a package name to be passed to the serializer.
-
Element Details
-
name
String name(Required) Name this converter. The name should be unique across the whole persistence unit.
-
-
-
serializerPackage
String serializerPackageAllows a package name to be passed to the serializer. This is used by some serializers such as XML, JSON to initialize the JAXB context from the classes in the package or a jaxb.index file.- Default:
- ""
-
serializerClass
Class<? extends Serializer> serializerClassThe serializer class to be used. This class must implement the org.eclipse.persistence.sessions.serializers.Serializer interface.- Default:
- org.eclipse.persistence.sessions.serializers.JavaSerializer.class
-