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

samplest.FrontObjetMapperCustomizer.kt Maven / Gradle / Ivy

There is a newer version: 1.2.0-rc2
Show newest version
package samplest

import com.fasterxml.jackson.databind.ObjectMapper
import com.fasterxml.jackson.module.kotlin.registerKotlinModule
import restx.factory.Component
import restx.factory.NamedComponent
import restx.factory.SingleComponentNameCustomizerEngine
import restx.jackson.FrontObjectMapperFactory

@Component
class FrontObjectMapperCustomizer :
    SingleComponentNameCustomizerEngine(5, FrontObjectMapperFactory.NAME) {

    override fun customize(namedComponent: NamedComponent): NamedComponent {
        val objectMapper = namedComponent.component
        objectMapper.registerKotlinModule()
        return namedComponent
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy