top button
Flag Notify
    Connect to us
      Facebook Login
      Site Registration

Facebook Login
Site Registration

What is Soft, Weak and Phantom references in java?

+5 votes

What is Soft, Weak and Phantom references in java, please provide explanation with example?

posted Oct 9, 2014 by Vikram Luthra

Share this question
Facebook Share Button Twitter Share Button LinkedIn Share Button

1 Answer

0 votes

Garbage Collector won’t remove a strong reference.

A soft reference will only get removed if memory is low.

A weak reference will get removed on the next garbage collection cycle.

A phantom reference will be finalized but the memory will not be reclaimed. Can be useful when you want to be notified that an object is about to be collected.

answer Jun 23, 2016 by Karthick.c
Similar Questions
+4 votes

Based on my understanding, the concept of phantom cell was proposed by DOCOMO and the concept of dual connectivity was proposed by 3GPP. In phantom cell, control- and user-plane are split. Specifically, control plane is maintained in marcocell and user plane is maintained in small cell. However, in dual connectivity, both control and data plane are maintained in marcocell and only user plane is maintained in small cell. Is it right?

Contact Us
+91 9880187415
#280, 3rd floor, 5th Main
6th Sector, HSR Layout
Karnataka INDIA.