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

kotlin-client.jvm-common.infrastructure.UUIDAdapter.kt.mustache Maven / Gradle / Ivy

There is a newer version: 7.10.0
Show newest version
package {{packageName}}.infrastructure

import com.squareup.moshi.FromJson
import com.squareup.moshi.ToJson
import java.util.UUID

{{#nonPublicApi}}internal {{/nonPublicApi}}class UUIDAdapter {
    @ToJson
    fun toJson(uuid: UUID) = uuid.toString()

    @FromJson
    fun fromJson(s: String) = UUID.fromString(s)
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy