классы, управляющие собственной памятью

Эффективная Java: Правило 6: Удалите устаревшие ссылки на объекты.

Вообще говоря, всякий раз, когда класс manages its own memory, the programmer should be alert for memory leaks. Whenever an element is freed, any object references contained in the element should be nulled out.

I don't think I fully understood the description.

What are the examples of a class managing its own memory - I can think of array, list, maybe map.

Could anyone explain the item in somewhat more details it is there in the book? Спасибо

6
задан Atul 31 May 2011 в 05:36
поделиться