Commit 3b2ef9f6 authored by Emmanuel Bourg's avatar Emmanuel Bourg

Imported Upstream version 2.7.3

parent 0244e023
# Do not merge `pom.xml` from older version, as it will typically conflict
pom.xml merge=ours
language: java
jdk:
- oraclejdk7
Project to build [Jackson](http://jackson.codehaus.org) module (jar)
[Jackson](http://jackson.codehaus.org) module (jar)
to support JSON serialization and deserialization of
[Joda](http://joda-time.sourceforge.net/) data types.
## Status
[![Build Status](https://fasterxml.ci.cloudbees.com/job/jackson-datatype-joda-master/badge/icon)](https://fasterxml.ci.cloudbees.com/job/jackson-datatype-joda-master/)
[![Build Status](https://travis-ci.org/FasterXML/jackson-datatype-joda.svg)](https://travis-ci.org/FasterXML/jackson-datatype-joda)
[![Maven Central](https://maven-badges.herokuapp.com/maven-central/com.fasterxml.jackson.datatype/jackson-datatype-joda/badge.svg)](https://maven-badges.herokuapp.com/maven-central/com.fasterxml.jackson.datatype/jackson-datatype-joda/)
[![Javadoc](https://javadoc-emblem.rhcloud.com/doc/com.fasterxml.jackson.datatype/jackson-datatype-joda/badge.svg)](http://www.javadoc.io/doc/com.fasterxml.jackson.datatype/jackson-datatype-joda)
As of version 2.0 module is usable and relatively extensive.
Module has been production-ready since version 2.0, and offers relatively extensive support for Joda datatypes.
Contributions are always welcome -- not all types are yet supported; and we may want to support even wider alternative
formats on input side.
## License
[Apache License 2.0](http://www.apache.org/licenses/LICENSE-2.0.txt)
## Usage
Since this module extends basic [Jackson databind](../../../jackson-databind) functionality, you may want to check out
......
......@@ -4,12 +4,12 @@
<parent>
<groupId>com.fasterxml.jackson</groupId>
<artifactId>jackson-parent</artifactId>
<version>2.4</version>
<version>2.7</version>
</parent>
<groupId>com.fasterxml.jackson.datatype</groupId>
<artifactId>jackson-datatype-joda</artifactId>
<name>Jackson-datatype-Joda</name>
<version>2.4.3</version>
<version>2.7.3</version>
<packaging>bundle</packaging>
<description>Add-on module for Jackson (http://jackson.codehaus.org) to support
Joda (http://joda-time.sourceforge.net/) data types.
......@@ -19,11 +19,15 @@ Joda (http://joda-time.sourceforge.net/) data types.
<connection>scm:git:git@github.com:FasterXML/jackson-datatype-joda.git</connection>
<developerConnection>scm:git:git@github.com:FasterXML/jackson-datatype-joda.git</developerConnection>
<url>http://github.com/FasterXML/jackson-datatype-joda</url>
<tag>jackson-datatype-joda-2.4.3</tag>
<tag>jackson-datatype-joda-2.7.3</tag>
</scm>
<properties>
<version.jackson.annotations>2.4.0</version.jackson.annotations>
<version.jackson.core>2.4.3</version.jackson.core>
<version.jackson.core>2.7.3</version.jackson.core>
<!-- 23-Feb-2016, tatu: Try to keep JDK6 runtime, still -->
<javac.src.version>1.6</javac.src.version>
<javac.target.version>1.6</javac.target.version>
<!-- Generate PackageVersion.java into this directory. -->
<packageVersion.dir>com/fasterxml/jackson/datatype/joda</packageVersion.dir>
<packageVersion.package>${project.groupId}.joda</packageVersion.package>
......@@ -40,7 +44,6 @@ Joda (http://joda-time.sourceforge.net/) data types.
<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-annotations</artifactId>
<version>${version.jackson.annotations}</version>
</dependency>
<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
......@@ -58,17 +61,10 @@ Joda (http://joda-time.sourceforge.net/) data types.
<groupId>joda-time</groupId>
<artifactId>joda-time</artifactId>
<!-- Upgraded to 2.2 for Jackson 2.4: but let's try not to call any 2.2 methods
Similarly 2.4 for Jackson 2.7
-->
<version>2.2</version>
</dependency>
<!-- 26-Jun-2012, tatu: Not sure if this should be included; it appears to be
a transitive dependency. Leaving out for now.
<dependency>
<groupId>org.joda</groupId>
<artifactId>joda-convert</artifactId>
<version>1.2</version>
<version>2.4</version>
</dependency>
-->
</dependencies>
......
......@@ -24,3 +24,41 @@ Brad Kennedy (bkenned4@github)
* Contributed #45: Can't use LocalTime, LocalDate & LocalDateTime as Key type for a Map
(2.4.3)
Charlie La Mothe (clamothe@github)
* Contributed #51: Calling `JodaDateSerializerBase.isEmpty()` results in a `StackOverflowError`.
(2.5.1)
Thorsten Platz (ThorstenPlatz@github)
* Reported #60: Configured date/time format not considered when serializing Joda Instant
(2.5.4)
Michał Ziober (ZioberMichal@github)
* Contributed #62: Allow use of numbers-as-Strings for LocalDate (in array)
(2.6.0)
Jerry Yang (islanerman@github)
* Contributed #68: TimeZone in DeserializationContext is ignored with
`SerializationFeature.WRITE_DATES_WITH_ZONE_ID`
(2.6.0)
jamesmcmillan@github
* Reported #70: Default DateTime parser format is stricter than
previous versions, causing incompatibility
Luke Nezda (nezda@github)
* Contributed #71: Adjust LocalDate / LocalDateTime deserializer to support
`DeserializationFeature.ADJUST_DATES_TO_CONTEXT_TIME_ZONE`
(2.6.2)
Fabian Buch (fabianbuch@github)
* Contributed #73: `SerializationFeature.WRITE_DATES_WITH_ZONE_ID` writes
inconsistent Zone Offset
(2.6.3)
Chris Plummer (strmer15@github)
* Reported #82: Can't deserialize a serialized DateTimeZone with default typing
(2.6.6 / 2.7.3)
Jochen Schalanda (joschi@github)
* Contributed #81: Add key deserializers for `Duration` and `Period` classes
(2.7.2)
Project: jackson-datatype-joda
Version: 2.4.3 (04-Oct-2014)
------------------------------------------------------------------------
=== Releases ===
------------------------------------------------------------------------
2.7.3 (16-Mar-2016)
No changes since 2.7.2
2.7.2 (27-Feb-2016)
#81: Add key deserializers for `Duration` and `Period` classes
(contributed by Jochen S)
- Change build to produce JDK6-compatible jar, to allow use on JDK6 runtime
2.7.1 (02-Feb-2016)
2.7.0 (10-Jan-2016)
No changes since 2.6.
2.6.6 (not yet released)
#82: Can't deserialize a serialized DateTimeZone with default typing
(reported by Chris P)
2.6.5 (19-Jan-2016)
2.6.4 (07-Dec-2015)
2.6.3 (12-Oct-2015)
No changes since 2.6.2.
2.6.2 (15-Sep-2015)
#71: Adjust LocalDate / LocalDateTime deserializer to support
`DeserializationFeature.ADJUST_DATES_TO_CONTEXT_TIME_ZONE`
(contributed by Luke N)
#73: `SerializationFeature.WRITE_DATES_WITH_ZONE_ID` writes
inconsistent Zone Offset
(contributed by Fabian B)
2.6.1 (09-Aug-2015)
- Removed `final` from serializer implementations, to allow sub-class overriding
2.6.0-1 (29-Jul-2015) (micro-patch)
#70: Default DateTime parser format is stricter than previous versions,
causing incompatibility
(reported by jamesmcmillan@github)
2.6.0 (19-Jul-2015)
#49: testDateMidnightSerWithTypeInfo test dependent on $TZ
(contributed by Michal Z)
#58: Support timezone configuration for Interval deserializer
#62: Allow use of numbers-as-Strings for LocalDate (in array)
(contributed by Michal Z)
#64: Support `@JsonFormat(pattern=...)` for deserialization
#66: Support `SerializationFeature.WRITE_DATES_WITH_ZONE_ID`
#68: TimeZone in DeserializationContext is ignored with
`SerializationFeature.WRITE_DATES_WITH_ZONE_ID`
(contributed by Jerry Y, islanderman@github)
2.5.4 (09-Jun-2015)
#60: Configured date/time format not considered when serializing Joda Instant
(reported by Thorsten P)
2.5.3 (24-Apr-2015)
2.5.2 (29-Mar-2015)
No changes since 2.5.1
2.5.1 (06-Feb-2015)
#51: Calling `JodaDateSerializerBase.isEmpty()` results in a `StackOverflowError`.
(reported, fix contributed by Charlie L-M)
2.5.0 (01-Jan-2015)
2.4.6 (23-Apr-2015)
2.4.5 (14-Jan-2015)
2.4.4 (24-Nov-2014)
No changes since 2.4.3
2.4.3 (04-Oct-2014)
#45: Can't use LocalTime, LocalDate & LocalDateTime as Key type for a Map
(contributed by Brad K, reported by Guido M)
#46: Interval deserialization fails for negative start instants
(reported by Dan G, dgrabows@github)
------------------------------------------------------------------------
=== History: ===
------------------------------------------------------------------------
2.4.2 (15-Aug-2014)
No changes since 2.4.0
......
package com.fasterxml.jackson.datatype.joda;
import com.fasterxml.jackson.databind.JsonDeserializer;
import com.fasterxml.jackson.databind.JsonSerializer;
import com.fasterxml.jackson.databind.module.SimpleModule;
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
import com.fasterxml.jackson.datatype.joda.deser.*;
import com.fasterxml.jackson.datatype.joda.deser.key.*;
import com.fasterxml.jackson.datatype.joda.ser.*;
import org.joda.time.*;
public class JodaModule extends SimpleModule
{
private static final long serialVersionUID = 1L;
@SuppressWarnings({ "unchecked", "deprecation" })
public JodaModule()
{
super(PackageVersion.VERSION);
// first deserializers
addDeserializer(DateMidnight.class, new DateMidnightDeserializer());
addDeserializer(DateTime.class, DateTimeDeserializer.forType(DateTime.class));
addDeserializer(DateTimeZone.class, new DateTimeZoneDeserializer());
......@@ -25,18 +27,17 @@ public class JodaModule extends SimpleModule
addDeserializer(LocalDateTime.class, new LocalDateTimeDeserializer());
addDeserializer(LocalDate.class, new LocalDateDeserializer());
addDeserializer(LocalTime.class, new LocalTimeDeserializer());
addDeserializer(Period.class, new PeriodDeserializer());
JsonDeserializer<?> deser = new PeriodDeserializer(true);
addDeserializer(Period.class, (JsonDeserializer<Period>) deser);
addDeserializer(ReadablePeriod.class, new PeriodDeserializer(false));
addDeserializer(ReadableDateTime.class, DateTimeDeserializer.forType(ReadableDateTime.class));
addDeserializer(ReadableInstant.class, DateTimeDeserializer.forType(ReadableInstant.class));
addDeserializer(Interval.class, new IntervalDeserializer());
addDeserializer(MonthDay.class, new MonthDayDeserializer());
addDeserializer(YearMonth.class, new YearMonthDeserializer());
addDeserializer(ReadablePeriod.class, new ReadablePeriodDeserializer());
// then serializers:
final JsonSerializer<Object> stringSer = ToStringSerializer.instance;
addSerializer(DateMidnight.class, new DateMidnightSerializer());
addSerializer(DateTime.class, new DateTimeSerializer());
addSerializer(DateTimeZone.class, new DateTimeZoneSerializer());
addSerializer(Duration.class, new DurationSerializer());
......@@ -54,17 +55,29 @@ public class JodaModule extends SimpleModule
addKeyDeserializer(LocalTime.class, new LocalTimeKeyDeserializer());
addKeyDeserializer(LocalDate.class, new LocalDateKeyDeserializer());
addKeyDeserializer(LocalDateTime.class, new LocalDateTimeKeyDeserializer());
addKeyDeserializer(Duration.class, new DurationKeyDeserializer());
addKeyDeserializer(Period.class, new PeriodKeyDeserializer());
// 26-Dec-2015, tatu: Joda has deprecated following types:
// DateMidnight since at least Joda 2.4:
addDeserializer(DateMidnight.class, new DateMidnightDeserializer());
addSerializer(DateMidnight.class, new DateMidnightSerializer());
}
// yes, will try to avoid duplicate registrations (if MapperFeature enabled)
@Override
public int hashCode()
{
public String getModuleName() {
return getClass().getSimpleName();
}
@Override
public int hashCode() {
return getClass().hashCode();
}
@Override
public boolean equals(Object o)
{
public boolean equals(Object o) {
return this == o;
}
}
package com.fasterxml.jackson.datatype.joda.cfg;
import org.joda.time.DateTimeZone;
import org.joda.time.format.DateTimeFormatter;
import org.joda.time.format.ISODateTimeFormat;
import org.joda.time.format.ISOPeriodFormat;
/**
* Simple container class that holds both default formatter information
* and explicit overrides caller has set for the Joda module to register.
* Note that changes to configuration instance <b>MUST</b> be made before
* registering the module; changes after registration may not have effect
* on actual settings used.
*
* @since 2.5
*/
public class FormatConfig
{
private final static DateTimeZone DEFAULT_TZ = DateTimeZone.getDefault();
// Matching wrappers for more information needed with formatter
public final static JacksonJodaDateFormat DEFAULT_DATEONLY_FORMAT
= createUTC(ISODateTimeFormat.date());
public final static JacksonJodaDateFormat DEFAULT_TIMEONLY_FORMAT
= createUTC(ISODateTimeFormat.time());
/* 28-Jul-2015, tatu: As per [datatype-joda#70], there is difference between
* "dateTime()" and "dateTimeParser()"... so we need to differentiate between
* parser/generator it seems.
*/
public final static JacksonJodaDateFormat DEFAULT_DATETIME_PARSER
= createUTC(ISODateTimeFormat.dateTimeParser());
public final static JacksonJodaDateFormat DEFAULT_DATETIME_PRINTER
= createUTC(ISODateTimeFormat.dateTime());
/**
* @deprecated Since 2.6.1
*/
@Deprecated
public final static JacksonJodaDateFormat DEFAULT_DATETIME_FORMAT = DEFAULT_DATETIME_PRINTER;
// should these differ from ones above? Presumably should use local timezone or... ?
public final static JacksonJodaDateFormat DEFAULT_LOCAL_DATEONLY_FORMAT
= createDefaultTZ(ISODateTimeFormat.date());
public final static JacksonJodaDateFormat DEFAULT_LOCAL_TIMEONLY_PRINTER
= createDefaultTZ(ISODateTimeFormat.time());
public final static JacksonJodaDateFormat DEFAULT_LOCAL_TIMEONLY_PARSER
= createDefaultTZ(ISODateTimeFormat.localTimeParser());
public final static JacksonJodaDateFormat DEFAULT_LOCAL_DATETIME_PRINTER
= createDefaultTZ(ISODateTimeFormat.dateTime());
public final static JacksonJodaDateFormat DEFAULT_LOCAL_DATETIME_PARSER
= createDefaultTZ(ISODateTimeFormat.localDateOptionalTimeParser());
public final static JacksonJodaPeriodFormat DEFAULT_PERIOD_FORMAT
= new JacksonJodaPeriodFormat(ISOPeriodFormat.standard());
// // // And then some wrapper methods for improved diagnostics, and possible
// // // default settings for things like "withOffsetParsed()" (see
// // // [dataformat-joda#75] for more information)
private final static JacksonJodaDateFormat createUTC(DateTimeFormatter f)
{
f = f.withZoneUTC();
return new JacksonJodaDateFormat(f);
}
private final static JacksonJodaDateFormat createDefaultTZ(DateTimeFormatter f)
{
f = f.withZone(DEFAULT_TZ);
return new JacksonJodaDateFormat(f);
}
}
package com.fasterxml.jackson.datatype.joda.ser;
package com.fasterxml.jackson.datatype.joda.cfg;
import java.util.Locale;
import java.util.TimeZone;
......@@ -7,86 +7,66 @@ import org.joda.time.DateTimeZone;
import org.joda.time.format.DateTimeFormat;
import org.joda.time.format.DateTimeFormatter;
import com.fasterxml.jackson.databind.SerializationFeature;
import com.fasterxml.jackson.databind.DeserializationContext;
import com.fasterxml.jackson.databind.DeserializationFeature;
import com.fasterxml.jackson.databind.SerializerProvider;
/**
* Simple container used to encapsulate (some of) gory details of
* customizations related to date/time formatting.
*/
public class JacksonJodaFormat
public class JacksonJodaDateFormat extends JacksonJodaFormatBase
{
private final static String JODA_STYLE_CHARS = "SMLF-";
protected final static Locale DEFAULT_LOCALE;
static {
DEFAULT_LOCALE = Locale.getDefault();
}
protected final DateTimeFormatter _formatter;
/**
* Flag that indicates that serialization must be done as the
* Java timestamp, regardless of other settings.
*/
protected final Boolean _useTimestamp;
protected final TimeZone _jdkTimezone;
protected final boolean _explicitTimezone;
protected transient DateTimeZone _jodaTimezone;
protected final Locale _locale;
protected final boolean _explicitLocale;
protected final boolean _explicitTimezone;
public JacksonJodaFormat(DateTimeFormatter defaultFormatter) {
_useTimestamp = null;
_jdkTimezone = defaultFormatter.getZone().toTimeZone();
_locale = DEFAULT_LOCALE;
public JacksonJodaDateFormat(DateTimeFormatter defaultFormatter)
{
super();
_formatter = defaultFormatter;
DateTimeZone tz = defaultFormatter.getZone();
_jdkTimezone = (tz == null) ? null : tz.toTimeZone();
_explicitTimezone = false;
_explicitLocale = false;
}
public JacksonJodaFormat(JacksonJodaFormat base, Boolean useTimestamp)
public JacksonJodaDateFormat(JacksonJodaDateFormat base, Boolean useTimestamp)
{
_useTimestamp = useTimestamp;
super(base, useTimestamp);
_formatter = base._formatter;
_jdkTimezone = base._jdkTimezone;
_explicitTimezone = base._explicitTimezone;
_locale = base._locale;
_explicitLocale = base._explicitLocale;
}
public JacksonJodaFormat(JacksonJodaFormat base,
public JacksonJodaDateFormat(JacksonJodaDateFormat base,
DateTimeFormatter formatter)
{
_useTimestamp = base._useTimestamp;
super(base);
_formatter = formatter;
_jdkTimezone = base._jdkTimezone;
_explicitTimezone = base._explicitTimezone;
_locale = base._locale;
_explicitLocale = base._explicitLocale;
}
public JacksonJodaFormat(JacksonJodaFormat base, TimeZone jdkTimezone)
public JacksonJodaDateFormat(JacksonJodaDateFormat base, TimeZone jdkTimezone)
{
_useTimestamp = base._useTimestamp;
super(base, jdkTimezone);
_formatter = base._formatter.withZone(DateTimeZone.forTimeZone(jdkTimezone));
_jdkTimezone = jdkTimezone;
_explicitTimezone = true;
_locale = base._locale;
_explicitLocale = base._explicitLocale;
_formatter = base._formatter.withZone(DateTimeZone.forTimeZone(jdkTimezone));
}
public JacksonJodaFormat(JacksonJodaFormat base, Locale locale)
public JacksonJodaDateFormat(JacksonJodaDateFormat base, Locale locale)
{
_useTimestamp = base._useTimestamp;
super(base, locale);
_formatter = base._formatter.withLocale(locale);
_jdkTimezone = base._jdkTimezone;
_explicitTimezone = base._explicitTimezone;
_locale = locale;
_explicitLocale = true;
_formatter = base._formatter.withLocale(locale);
}
/*
......@@ -95,14 +75,14 @@ public class JacksonJodaFormat
/**********************************************************
*/
protected JacksonJodaFormat withUseTimestamp(Boolean useTimestamp) {
public JacksonJodaDateFormat withUseTimestamp(Boolean useTimestamp) {
if (_useTimestamp != null && _useTimestamp.equals(useTimestamp)) {
return this;
}
return new JacksonJodaFormat(this, useTimestamp);
return new JacksonJodaDateFormat(this, useTimestamp);
}
protected JacksonJodaFormat withFormat(String format) {
public JacksonJodaDateFormat withFormat(String format) {
if (format == null || format.isEmpty()) {
return this;
}
......@@ -116,22 +96,49 @@ public class JacksonJodaFormat
if (_locale != null) {
formatter = formatter.withLocale(_locale);
}
// copy TimeZone from previous formatter
formatter = formatter.withZone(_formatter.getZone());
return new JacksonJodaFormat(this, formatter);
return new JacksonJodaDateFormat(this, formatter);
}
protected JacksonJodaFormat withTimeZone(TimeZone tz) {
public JacksonJodaDateFormat withTimeZone(TimeZone tz) {
if ((tz == null) || (_jdkTimezone != null && _jdkTimezone.equals(tz))) {
return this;
}
return new JacksonJodaFormat(this, tz);
return new JacksonJodaDateFormat(this, tz);
}
protected JacksonJodaFormat withLocale(Locale locale) {
public JacksonJodaDateFormat withLocale(Locale locale) {
if ((locale == null) || (_locale != null && _locale.equals(locale))) {
return this;
}
return new JacksonJodaFormat(this, locale);
return new JacksonJodaDateFormat(this, locale);
}
/*
/**********************************************************
/* Accessors
/**********************************************************
*/
/**
* @since 2.6
*/
public DateTimeZone getTimeZone() {
if (_jodaTimezone != null) {
return _jodaTimezone;
}
if (_jdkTimezone == null) {
return null;
}
DateTimeZone tz = DateTimeZone.forTimeZone(_jdkTimezone);
_jodaTimezone = tz;
return tz;
}
public Locale getLocale() {
return _locale;
}
/*
......@@ -140,33 +147,66 @@ public class JacksonJodaFormat
/**********************************************************
*/
public boolean useTimestamp(SerializerProvider provider)
public DateTimeFormatter rawFormatter() {
return _formatter;
}
public DateTimeFormatter createFormatter(SerializerProvider ctxt)
{
if (_useTimestamp != null) {
return _useTimestamp.booleanValue();
DateTimeFormatter formatter = createFormatterWithLocale(ctxt);
if (!_explicitTimezone) {
TimeZone tz = ctxt.getTimeZone();
if ((tz != null) && !tz.equals(_jdkTimezone)) {
formatter = formatter.withZone(DateTimeZone.forTimeZone(tz));
}
}
return provider.isEnabled(SerializationFeature.WRITE_DATES_AS_TIMESTAMPS);
return formatter;
}
public DateTimeFormatter createFormatter(SerializerProvider provider)
public DateTimeFormatter createFormatterWithLocale(SerializerProvider ctxt)
{
DateTimeFormatter formatter = _formatter;
if (!_explicitLocale) {
Locale loc = ctxt.getLocale();
if (loc != null && !loc.equals(_locale)) {
formatter = formatter.withLocale(loc);
}
}
return formatter;
}
/**
* Accessor used during deserialization.
*/
public DateTimeFormatter createParser(DeserializationContext ctxt)
{
DateTimeFormatter formatter = _formatter;
if (!_explicitLocale) {
Locale loc = provider.getLocale();
Locale loc = ctxt.getLocale();
if (loc != null && !loc.equals(_locale)) {
formatter = formatter.withLocale(loc);
}
}
if (!_explicitTimezone) {
TimeZone tz = provider.getTimeZone();
if (tz != null && !tz.equals(_jdkTimezone)) {
formatter = formatter.withZone(DateTimeZone.forTimeZone(tz));
if (ctxt.isEnabled(DeserializationFeature.ADJUST_DATES_TO_CONTEXT_TIME_ZONE)) {
TimeZone tz = ctxt.getTimeZone();
if (tz != null && !tz.equals(_jdkTimezone)) {
formatter = formatter.withZone(DateTimeZone.forTimeZone(tz));
}
} else {
formatter = formatter.withOffsetParsed();
}
}
return formatter;
}
/**
* Differentiate if TimeZone is specified by caller
* @return true if TimeZone is specified by caller; false otherwise.
*/
public boolean isTimezoneExplicit() {
return _explicitTimezone;
}
/*
/**********************************************************
......@@ -181,4 +221,10 @@ public class JacksonJodaFormat
return (JODA_STYLE_CHARS.indexOf(formatStr.charAt(0)) >= 0)
&& (JODA_STYLE_CHARS.indexOf(formatStr.charAt(0)) >= 0);
}
@Override
public String toString() {
return String.format("[JacksonJodaFormat, explicitTZ? %s, JDK tz = %s, formatter = %s]",
_explicitTimezone, _jdkTimezone.getID(), _formatter);
}
}
package com.fasterxml.jackson.datatype.joda.cfg;
import java.util.Locale;
import java.util.TimeZone;
import com.fasterxml.jackson.databind.SerializationFeature;
import com.fasterxml.jackson.databind.SerializerProvider;
/**
* Base object for different formatters (date-time, period, ...)
*/
abstract class JacksonJodaFormatBase
{
protected final static Locale DEFAULT_LOCALE;
static {
DEFAULT_LOCALE = Locale.getDefault();
}