I have an Activity which implements an interface, and a AsyncTask using the interface update the status. I understand that if the AyncTask hold an reference of the Activity and outlive the Activity will cause the memory leak, but if the AyncTask just holding part of the memory, ie, the interface, will it also cause memory leak??
Yes it will. The interface is just a definition what methods a certain objects provides. It is still a reference to the original Object.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With