napperley
05/02/2019, 6:53 AMorg.example.battery_info.model.http.SensorDataTimestampRangeBody
(although at least one Creator exists): no String-argument constructor/factory method to deserialize from String value ('{"owner":"Joe Bloggs","site":"House","timestampRange":{"endDay":3,"endHour":12,"endMinute":0,"endMonth":5,"endYear":2019,"startDay":2,"startHour":12,"startMinute":0,"startMonth":5,"startYear":2019}}'
Upon inspection the JSON structure matches correctly to the data classes yet deserialization fails when the Android client makes a HTTP request. The CLI client works fine without any issues. Is there a way to fix the JSON deserialization issue? Is the issue related to this GitHub issue ( https://github.com/FasterXML/jackson-module-kotlin/issues/91 )?napperley
05/02/2019, 6:57 AMdata class SensorDataTimestampRangeBody(val owner: String, val site: String, val timestampRange: TimestampRange)
napperley
05/02/2019, 6:58 AMdata class TimestampRange(
val startYear: Int,
val startMonth: Int,
val startDay: Int,
val endYear: Int,
val endMonth: Int,
val endDay: Int,
val startHour: Int,
val startMinute: Int,
val endHour: Int,
val endMinute: Int
)
mp
05/03/2019, 1:22 PMmp
05/03/2019, 1:23 PMmp
05/03/2019, 1:23 PMnapperley
05/03/2019, 10:55 PM