diff options
Diffstat (limited to 'sca-java-2.x/trunk/modules/databinding-json/src/main/java/org/apache/tuscany')
-rw-r--r-- | sca-java-2.x/trunk/modules/databinding-json/src/main/java/org/apache/tuscany/sca/databinding/json/jackson/JacksonHelper.java | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/sca-java-2.x/trunk/modules/databinding-json/src/main/java/org/apache/tuscany/sca/databinding/json/jackson/JacksonHelper.java b/sca-java-2.x/trunk/modules/databinding-json/src/main/java/org/apache/tuscany/sca/databinding/json/jackson/JacksonHelper.java index 895c9e70ce..2307150370 100644 --- a/sca-java-2.x/trunk/modules/databinding-json/src/main/java/org/apache/tuscany/sca/databinding/json/jackson/JacksonHelper.java +++ b/sca-java-2.x/trunk/modules/databinding-json/src/main/java/org/apache/tuscany/sca/databinding/json/jackson/JacksonHelper.java @@ -43,6 +43,7 @@ import org.codehaus.jackson.map.deser.CustomDeserializerFactory; import org.codehaus.jackson.map.deser.StdDeserializerProvider; import org.codehaus.jackson.map.introspect.JacksonAnnotationIntrospector; import org.codehaus.jackson.map.ser.CustomSerializerFactory; +import org.codehaus.jackson.map.util.StdDateFormat; import org.codehaus.jackson.xc.JaxbAnnotationIntrospector; import org.codehaus.jackson.xc.XmlAdapterJsonDeserializer; import org.codehaus.jackson.xc.XmlAdapterJsonSerializer; @@ -99,8 +100,10 @@ public class JacksonHelper { AnnotationIntrospector pair = new AnnotationIntrospector.Pair(primary, secondary); mapper.getDeserializationConfig().setAnnotationIntrospector(pair); mapper.getDeserializationConfig().set(DeserializationConfig.Feature.FAIL_ON_UNKNOWN_PROPERTIES, Boolean.FALSE); + mapper.getDeserializationConfig().setDateFormat(StdDateFormat.getBlueprintISO8601Format()); mapper.getSerializationConfig().setAnnotationIntrospector(pair); mapper.getSerializationConfig().setSerializationInclusion(JsonSerialize.Inclusion.NON_NULL); + mapper.getSerializationConfig().setDateFormat(StdDateFormat.getBlueprintISO8601Format()); return mapper; } |