Asaf Peleg
09/06/2023, 4:11 AMput
on each field. Since my data class would need an empty constructor I'd have to set defaults or make all of my fields optional, but neither seems ideal.
Is there some trick or alternative to data classes that I could use or should I just be using a plain old class for this instead?Szymon Jeziorski
09/06/2023, 8:03 AMno-arg
compiler plugin wouldn't do the trick for you (it would allow you to stick with data classes):
https://kotlinlang.org/docs/no-arg-plugin.htmlAsaf Peleg
09/06/2023, 8:28 PMobject.put(key, value)
where put argument types are (String, Object)