Class JacksonJsonUtils

java.lang.Object
org.springframework.integration.support.json.JacksonJsonUtils

public final class JacksonJsonUtils
extends java.lang.Object
Utility methods for Jackson.
Since:
3.0
  • Field Summary

    Fields 
    Modifier and Type Field Description
    static java.util.List<java.lang.String> DEFAULT_TRUSTED_PACKAGES
    The packages to trust on JSON deserialization by default.
  • Method Summary

    Modifier and Type Method Description
    static com.fasterxml.jackson.databind.ObjectMapper messagingAwareMapper​(java.lang.String... trustedPackages)
    Return an ObjectMapper if available, supplied with Message specific serializers and deserializers.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • DEFAULT_TRUSTED_PACKAGES

      public static final java.util.List<java.lang.String> DEFAULT_TRUSTED_PACKAGES
      The packages to trust on JSON deserialization by default.
  • Method Details

    • messagingAwareMapper

      public static com.fasterxml.jackson.databind.ObjectMapper messagingAwareMapper​(java.lang.String... trustedPackages)
      Return an ObjectMapper if available, supplied with Message specific serializers and deserializers. Also configured to store typo info in the @class property.
      Parameters:
      trustedPackages - the trusted Java packages for deserialization.
      Returns:
      the mapper.
      Throws:
      java.lang.IllegalStateException - if an implementation is not available.
      Since:
      4.3.10