Domanda di colloquio di Bolt

How can you avoid memory leaks with an AsyncTask

Risposta di colloquio

Anonimo

24 mag 2019

I talked about using abstraction such as a listener object to avoid direct bi-directionality. They did not like my answer because it still causes the context to be held for some time (they called this a leak, I disagree) - they were looking for 'WeakReference' (which is a good answer)