References Deprecated
JodaSerializerBase is deprecated or references (maybe indirectly) at least one deprecated element.
See corresponding docs for further information.
ReadablePeriod using Joda default formatting.Todo
allow serialization as an array of numbers, for numeric ("timestamp") notation?
| Modifier and Type | Field and Description |
|---|---|
| protected final JacksonJodaPeriodFormat | |
| private static final long |
| Access | Constructor and Description |
|---|---|
| public | |
| protected |
| Modifier and Type | Method and Description |
|---|---|
| public void | acceptJsonFormatVisitor(JsonFormatVisitorWrapper visitor, JavaType
Type of element (entity like property) being visited typeHint)Overrides com. Implements com. Default implementation specifies no format. |
| public JsonSerializer | createContextual(SerializerProvider
Serializer provider to use for accessing config, other serializers prov, BeanProperty Method or field that represents the property
(and is used to access value to serialize).
Should be available; but there may be cases where caller cannot provide it and
null is passed instead (in which case impls usually pass 'this' serializer as is) property)Implements com. Method called to see if a different (or differently configured) serializer is needed to serialize values of specified property. |
| public JsonNode | getSchema(SerializerProvider
The serializer provider. provider, Type A hint about the type. typeHint)Overrides com. Implements com.
Deprecated
Default implementation simply claims type is "string"; usually overriden by custom serializers. |
| public void | serialize(ReadablePeriod
Value to serialize; can not be null. value, JsonGenerator Generator used to output resulting Json content gen, SerializerProvider Provider that can be used to get serializers for
serializing Objects value contains, if any. provider)Implements abstract com. Method that can be called to ask implementation to serialize values of type this serializer handles. |
| _format | back to summary |
|---|---|
| protected final JacksonJodaPeriodFormat _format | |
| serialVersionUID | back to summary |
|---|---|
| private static final long serialVersionUID Hides com. | |
| PeriodSerializer | back to summary |
|---|---|
| public PeriodSerializer() | |
| PeriodSerializer | back to summary |
|---|---|
| protected PeriodSerializer(JacksonJodaPeriodFormat format) | |
| acceptJsonFormatVisitor | back to summary |
|---|---|
| public void acceptJsonFormatVisitor(JsonFormatVisitorWrapper visitor, JavaType typeHint) throws JsonMappingException Overrides com. Implements com. Doc from com. Default implementation specifies no format. This behavior is usually overriden by custom serializers.
| |
| createContextual | back to summary |
|---|---|
| public JsonSerializer Implements com. Doc from com. Method called to see if a different (or differently configured) serializer is needed to serialize values of specified property. Note that instance that this method is called on is typically shared one and as a result method should NOT modify this instance but rather construct and return a new instance. This instance should only be returned as-is, in case it is already suitable for use.
| |
| getSchema | back to summary |
|---|---|
| public JsonNode getSchema(SerializerProvider provider, Type typeHint) Overrides com. Implements com. Doc from com. Deprecated
Default implementation simply claims type is "string"; usually overriden by custom serializers.
| |
| serialize | back to summary |
|---|---|
| public void serialize(ReadablePeriod value, JsonGenerator gen, SerializerProvider provider) throws IOException Implements abstract com. Doc from com. Method that can be called to ask implementation to serialize values of type this serializer handles.
| |