A friendly place for programming greenhorns!
Big Moose Saloon
Register / Login
Win a copy of
Java SE 8 for the Really Impatient
this week in the
Programmer Certification (SCJP/OCPJP)
Finalize Drag and Drop - thoughts?
Joined: Jun 03, 2013
Jun 08, 2013 07:59:47
Thoughts on the following OCPJP 5 mock exam question (Whizlabs practice
The finalize method...
a) May or may not be called just before garbage collection happens.
b) Can be used to resurrect an object.
The correct answer is B, which I understand.
I chose option A, because the finalize method is only called once - if the object is resurrected, it will not be called before GC is called a second time.
Do both answers seem correct? If not, why isn't A correct?
Joined: May 26, 2003
Jun 08, 2013 08:11:49
I agree with you.
How To Ask Questions The Smart Way
Blogging on Certs:
SCEA Part 1
Part 2 & 3
Core Spring 3
TOGAF part 1
I agree. Here's the link:
subject: Finalize Drag and Drop - thoughts?
Calling Bert Bates
GC question on MindQ no. 37
MindQ (Q.37) GC
All times are in JavaRanch time: GMT-6 in summer, GMT-7 in winter
| Powered by
Copyright © 1998-2014