I’ve been working on a custom kotlinx-serialization format for a while now. Currently, I’m looking for a good way to detect primitive array types in the encoding process. The problem is:
- KXS handles all collection-like formats as
StructureKind.LIST, which is fine so far because it handles the serialization / deserialization from / into the actual type for you.
- The format I’m implementing has dedicated types for Byte, Int and Long Arrays.
- Therefore, I’d like to treat
StructureKind.LISTelements differently if they are actually representing one of
So: What is the best way to get that kind of information out of a