Hey all! I'm wondering how I can have kotlin "auto...
# getting-started
h
Hey all! I'm wondering how I can have kotlin "automagically" include a val from a data class in it's generated code? Pseudo code: https://paste.ubuntu.com/p/5tVKgwNTvM/
r
This works fine…
toString()
prints everything.
Copy code
data class Sensor(val timestamp: Date, val tempC: Double, val rh: Double) {
    val getTempF = (tempC * 9) / 5 + 32
}