https://kotlinlang.org logo
#multiplatform
Title
# multiplatform
m

matej

02/10/2020, 3:47 PM
Am I imagining things, or are there currently no libraries for XML parsing / serialization in kotlin-native?
k

kpgalligan

02/10/2020, 3:55 PM
No XML libraries
m

matej

02/10/2020, 3:59 PM
Thanks, huh, that's sobering. I guess I have to take the interface route and pass a platform specific serializer/parser into the common code instead.
k

Kris Wong

02/10/2020, 4:04 PM
you might also be able to plug in to kotlinx.serializaton, so that you don't have to define the interface
worth looking into
m

matej

02/10/2020, 4:14 PM
Thanks guys!
c

corneil

02/10/2020, 7:58 PM
So after more than 20 years I may be developing another XML parser
k

kpgalligan

02/10/2020, 8:01 PM
Not sure of availability, but will try to help out some on native side if useful
o

olonho

02/11/2020, 4:57 AM
There are many small C XML parsers, like https://dev.yorhel.nl/yxml and it shall be easy to create pure .def klib using it
👍 1
c

corneil

02/11/2020, 5:59 AM
I think until stdlib has common I/O library building XML or JSON support is going to be an ugly process.
k

kpgalligan

02/11/2020, 11:43 AM
There is json support now
k

krtko

02/15/2020, 8:12 PM
Incase you you haven't seen this, https://github.com/Kotlin/kotlinx.serialization/issues/188 I expect once Kotlin Serialization goes stable, we'll see a first party XML extension
👍 2