Site Owners Forums - Webmaster Forums

Site Owners Forums - Webmaster Forums (http://siteownersforums.com/index.php)
-   Java (http://siteownersforums.com/forumdisplay.php?f=12)
-   -   what is difference between .. and equal() in java ? (http://siteownersforums.com/showthread.php?t=172614)

Shivangi Panwar 07-05-2016 11:02 PM

what is difference between .. and equal() in java ?
 
what is difference between .. and equal() in java ?

rekhaweb 07-13-2016 11:02 PM

Both == and .equals() refers to the same object if you don't override .equals().

Its your wish what you want to do once you override .equals(). You can compare the invoking object's state with the passed in object's state or you can just call super.equals()


All times are GMT -7. The time now is 11:45 PM.


Powered by vBulletin Copyright © 2020 vBulletin Solutions, Inc.