Litote / kmongo

[deprecated] KMongo - a Kotlin toolkit for Mongo
https://litote.org/kmongo/
Apache License 2.0
781 stars 74 forks source link

id serialization #359

Open Lewik opened 2 years ago

Lewik commented 2 years ago

I have make interface for entities (kotlinx serialization)

interface WithId {
    val id: String //I use value class here actually
}

All other entities inherits it How to deal with _id globally without @SerialName("_id") everywhere ?

zigzago commented 2 years ago

I would say this is more a kotlinx.serialization question (see https://github.com/Kotlin/kotlinx.serialization/issues/33). I think it's not feasible for now.