Hi Guys, I am new to Kotlin. I have a question. Wh...
# android
k
Hi Guys, I am new to Kotlin. I have a question. What would be memory impact if I use object AndroidDTO { data class Request(name: String) data class Response(api: String) } Instead of two different data classes as below: data class Request(name: String) data class Response(api: String) In presenter, I am accessing Android.Request("Lollipop") and getting response. The real question is when view(Fragment) is replaced by another view(Fragment), Android object would be in memory until application gets closed or would be garbage collected when view and associate presenter references are gone.
r
I don’t see a reason to put data classes inside a singleton object…