How can I tell if two Java instances represent the same instance? And what does class equality mean in Java?
The question here is, what does it mean to be the same or different in Java. If you modeled me, maybe two of me had blue shirts and the third had a red shirt. So their shirt color attribute would be the blue for two DJ instances, and red for a third DJ instance. Are they equal because they have the same color shirt, or are they the same me? We're going to clear that up in this lesson as we learn about what it means in Java for two instances to be equal.
#java #programming #tutorial
▼
Like the video? Don't forget to subscribe! ➜ www.deegeu.com/subscribe
▼
Keep up to date with the newsletter! ➜ www.deegeu.com/newsletter/
Full transcript:
www.deegeu.com/overriding-equa...
Concepts: Java, classes, equals, hashcode
Social Links: Don't hesitate to contact me if you have any further questions.
WEBSITE : dj@deegeu.com
TWITTER : / deege
FACEBOOK: / deegeu.programming.tut...
GOOGLE+ : google.com/+Deegeu-programming...
Hosted by DJ Spiess
About Me: www.deegeu.com/about-programmi...
Related Videos:
What are static factory methods in Java? - 036
• What are static factor...
Free Java Course Online
• What important Java Te...
Media credits: All images are owned by DJ Spiess unless listed below:
Music
Cold Funk - Funkorama by Kevin MacLeod is licensed under a Creative Commons Attribution license (creativecommons.org/licenses/...)
Source: incompetech.com/music/royalty-...
Artist: incompetech.com/
21 июл 2024