Skip to content

Instantly share code, notes, and snippets.

View RaphaelTarita's full-sized avatar
🫂

Raphael Tarita RaphaelTarita

🫂
  • 04:38 (UTC +01:00)
View GitHub Profile
@RaphaelTarita
RaphaelTarita / ConvertEngine.kt
Last active February 6, 2021 22:38
kotlinx.serialization.properties StringFormat backend (Write maps generated by KXS-properties to strings)
import kotlinx.serialization.ExperimentalSerializationApi
import kotlinx.serialization.InternalSerializationApi
import kotlinx.serialization.descriptors.SerialDescriptor
import kotlinx.serialization.descriptors.StructureKind
import kotlinx.serialization.encoding.CompositeDecoder
import kotlinx.serialization.internal.NamedValueDecoder
@ExperimentalSerializationApi
@InternalSerializationApi
class ConvertEngine(private val map: Map<String, String>, descriptor: SerialDescriptor) : NamedValueDecoder() {