bluelinelabs / LoganSquare

Screaming fast JSON parsing and serialization library for Android.
Apache License 2.0
3.21k stars 306 forks source link

Fix private getter / setters on Boolean fields to support Kotlin #212

Closed agrosner closed 7 years ago

agrosner commented 7 years ago

Kotlin classes that use Boolean types fail on compile. fixing them you have to define:

    @get:JvmName("isonlinePricingActive")
    @set:JvmName("setisOnlinePricingActive")
    var isOnlinePricingActive: Boolean = false,

A seperate getter/setter, which is lowercase. This does not work well with Kotlin. This file change fixes the issue by not using the elementNameLowerCase but instead uses elementName so we don't need the verbose annotation on any Boolean field.

agrosner commented 7 years ago

PS I hope this project finds someone to contribute. if you need someone to help, I can volunteer some time?