Can an unreachable object become reachable again?

Answer Posted / rakesh kumar jha

YES, Finalization is a feature of the Java programming
language that allows you to perform postmortem cleanup on
objects that the garbage collector has found to be
unreachable. It is typically used to reclaim native
resources associated with an object.
When the garbage collector determines that obj is
unreachable, it notices that obj is finalizable -- as it
had been recorded upon allocation -- and adds it to the
JVM's finalization queue. It also ensures that all objects
reachable from obj are retained, even if they are otherwise
unreachable, as they might be accessed by the finalizer.

So, we can say that it can be reachable.

Is This Answer Correct ?    10 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What will be the output of round(3.7) and ceil(3.7)?

675


Can a class extend 2 classes in java?

554


How do you add an arraylist to an array in java?

505


Why to use nested classes in java? (Or) what is the purpose of nested class in java?

521


What are "class access modifiers" in Java?

604






What is the right data type to represent a price in java?

564


What is a ternary operator in java? What is an interface?

546


Can a main method be overloaded?

567


How do you create a first line indent?

505


Which class cannot be a subclass in java?

537


Can a vector contain heterogenous objects?

592


Can static methods be inherited?

533


What is string immutability?

535


What is a line break example?

575


Name container classes in java programming?

591