All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.biacode.escommons.toolkit.configuration.EsCommonsJacksonConfiguration.kt Maven / Gradle / Ivy

There is a newer version: 7.3.2_0.1.0
Show newest version
package org.biacode.escommons.toolkit.configuration

import com.fasterxml.jackson.databind.ObjectMapper
import com.fasterxml.jackson.datatype.jdk8.Jdk8Module
import com.fasterxml.jackson.datatype.jsr310.JavaTimeModule
import com.fasterxml.jackson.module.kotlin.KotlinModule
import com.fasterxml.jackson.module.paramnames.ParameterNamesModule
import org.springframework.context.annotation.Bean
import org.springframework.context.annotation.Configuration

/**
 * Created by Arthur Asatryan.
 * Date: 5/17/18
 * Time: 5:22 PM
 */
@Configuration
class EsCommonsJacksonConfiguration {

    //region Public methods
    @Bean
    fun objectMapper(): ObjectMapper {
        return ObjectMapper()
                .registerModule(Jdk8Module())
                .registerModule(KotlinModule())
                .registerModule(JavaTimeModule())
                .registerModule(ParameterNamesModule())
    }
    //endregion

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy