I'm learning Android and i don't understand how how memory and garbage collector working and communicate "in general". I tell you my vision, correct me if wrong or give me good link to write about it.
We have an Android OS with installes apps. Android have it's own memory location, called "heap". Apps have nothing.
When some application launching, Android gives part of own heap to application. And it's hapenning with all apps, so some part of OS heap is distributed between apps. OS can give more memory to application if needed.
When memory become low, OS running it's own instrument, called Garbage Collector, to take some memory back from apps. He search objects without external links into distributed parts of memory and destroy object if no one refer on it. If memory is critical low, garbage collector can kill the process of some apps.
Is i correct or it's a rave of low skilled Junior?