oday
07/06/2021, 11:19 AMcount
, in my code I have override val count = storage.size
and in the interface it’s with a custom getterTom Hermann
07/07/2021, 9:33 PModay
07/08/2021, 9:39 AMTom Hermann
07/09/2021, 9:25 PMcount
or to turn that into a function. You want the size to be re-evaluated every time you query the count.
https://kotlinlang.org/docs/properties.html#getters-and-setters