Java removing class from arraylist -


if have array list classes in , remove class list, class removed/deleted , memory used freed up?

thanks

i think mean have objects in arraylist, not classes.

objects instances of classes, example integer class, when integer = new integer(1), a object of class integer).

java garbage collected, means don't have explicitly tell compiler when free memory (like in c example), garbage collector periodically check if instance not referenced anywhere else, , if that's case, means object can no longer accessed , memory freed.

what can call system.gc() tell garbage collector want perform collection. hint, there no way force immediate collection.


Comments

Popular posts from this blog

java - How to specify maven bin in eclipse maven plugin? -

single sign on - Logging into Plone site with credentials passed through HTTP -

php - Why does AJAX not process login form? -