Cedric Beust

Results 186 comments of Cedric Beust

Looking into this. Right now I'm struggling trying to recover the fact that `T`'s effective type is `A`, and I can't seem to be able to get this from `kotlin-reflect`...

First of all, this is a change that would break a lot of existing code, so not one I'd make lightly. Second... I don't quite understand what that pain in...

Oversight, this file should probably be compiled with Java 8...

I see. Right now, the only way would be to stream and manually switch on the key "properties", or "forecasts". Which is not great. I'll think about whether Klaxon could...

Can you include the JSON and also `PacketHeader` so I can build and run this?

You can already do this: val j = json { obj("colors" to obj( "grey" to "#333", "red" to listOf(255, 0, 0), "green" to listOf(0, 255, 0), "others" to obj("white" to...

Not following. Can you show an example of what you'd like to do?

Fair point. I just implemented this, take a look and let me know if this addresses your suggestion: https://github.com/cbeust/klaxon/commit/0179fedab54bb9f5824d5008d6f6faedcdcf17e1

The reason why this is a bit harder than it looks is because in order for this to work, I need to alter the `Converter` interface so that its `toJson():...

No, if you add parameters to an interface, implementers of that interface will have to add these parameters too, whether they have a default value or not.