ssm.sdk.json.JSONConverterObjectMapper.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of ssm-sdk-json Show documentation
Show all versions of ssm-sdk-json Show documentation
Aggregate all ssm data source to optimize request
The newest version!
package ssm.sdk.json
import com.fasterxml.jackson.core.type.TypeReference
class JSONConverterObjectMapper : JSONConverter {
override fun toCompletableObjects(clazz: Class, value: String): List {
val type: TypeReference> = object : TypeReference>() {}
return JsonUtils.toObject(value, type)
}
override fun toCompletableObject(clazz: Class, value: String): T? {
return toObject(clazz, value)
}
override fun toObject(clazz: Class, value: String): T? {
return if (value.isBlank()) {
null
} else {
JsonUtils.toObject(value, clazz)
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy