Package org.apache.drill.common.util
Class JacksonUtils
java.lang.Object
org.apache.drill.common.util.JacksonUtils
Utility class which contain methods for interacting with Jackson.
-
Method Summary
Modifier and TypeMethodDescriptionstatic com.fasterxml.jackson.databind.json.JsonMapper.Builder
Creates a new instance of the JacksonJsonMapper.Builder
.static com.fasterxml.jackson.databind.json.JsonMapper.Builder
createJsonMapperBuilder
(com.fasterxml.jackson.core.JsonFactory factory) Creates a new instance of the JacksonJsonMapper.Builder
.static com.fasterxml.jackson.databind.ObjectMapper
Creates a new instance of the JacksonObjectMapper
.static com.fasterxml.jackson.databind.ObjectMapper
createObjectMapper
(com.fasterxml.jackson.core.JsonFactory factory) Creates a new instance of the JacksonObjectMapper
.
-
Method Details
-
createObjectMapper
public static com.fasterxml.jackson.databind.ObjectMapper createObjectMapper()Creates a new instance of the JacksonObjectMapper
.- Returns:
- an
ObjectMapper
instance
-
createObjectMapper
public static com.fasterxml.jackson.databind.ObjectMapper createObjectMapper(com.fasterxml.jackson.core.JsonFactory factory) Creates a new instance of the JacksonObjectMapper
.- Parameters:
factory
- aJsonFactory
instance- Returns:
- an
ObjectMapper
instance
-
createJsonMapperBuilder
public static com.fasterxml.jackson.databind.json.JsonMapper.Builder createJsonMapperBuilder()Creates a new instance of the JacksonJsonMapper.Builder
.- Returns:
- an
JsonMapper.Builder
instance
-
createJsonMapperBuilder
public static com.fasterxml.jackson.databind.json.JsonMapper.Builder createJsonMapperBuilder(com.fasterxml.jackson.core.JsonFactory factory) Creates a new instance of the JacksonJsonMapper.Builder
.- Parameters:
factory
- aJsonFactory
instance- Returns:
- an
JsonMapper.Builder
instance
-