Java OOP: Understanding Overriding & Hiding in Inheritance
Java
| Intermediate
- 12 videos | 1h 22m 50s
- Includes Assessment
- Earns a Badge
In this course, you will learn about method overriding, including the use of the super keyword from contexts other than within constructions, and also examine the behavior of static methods. To start, participants learn how to apply method overriding and recognize the concept of hiding, and use the super keyword inside any method invocation in the derived class. This follows on to the use of advanced forms of overriding, combining method overriding with complex inheritance hierarchies. Study static methods and static binding, recognizing that static methods do not support run-time polymorphism. Examine pitfalls to avoid with static methods by learning to recognize how static methods are bound using compile-time rather than run-time binding. Learn how to correctly override the method .toString, which is inherited from java.lang.Object, and describe how the .equals method and the == operator are related. Explore how to correctly override the .hashCode method and write the code to correctly override the .equals method, inherited from java.lang.Object. Finally, after studying the link between equals and hashCode, discover how to implement the .hashCode contract.
WHAT YOU WILL LEARN
-
Discover the key concepts covered in this courseApply method overriding and recognize the concept of hidingUse the super keyword inside any method invocation in the derived classUse advanced forms of overridingCombine method overriding with fairly complex inheritance hierarchiesRecognize that static methods don't support run-time polymorphism
-
Recognize how static methods are bound using compile-time rather than run-time bindingOverride the method .tostring, which is inherited from java.lang.objectDescribe how the .equals method and the == operator are relatedCorrectly override the .hashcode method and write the code to correctly override the .equals method, which is inherited from java.lang.objectCompletely and correct implement the .hashcode contractSummarize the key concepts covered in this course
IN THIS COURSE
-
2m 21s
-
8m 10sIn this video, you will learn how to apply method overriding and recognize the concept of hiding. FREE ACCESS
-
9m 14sTo use the super keyword inside any method invocation in the derived class, find out how. FREE ACCESS
-
6m 6sIn this video, learn how to use advanced forms of overriding. FREE ACCESS
-
6mDuring this video, you will learn how to combine method overriding with complex inheritance hierarchies. FREE ACCESS
-
8m 9sUpon completion of this video, you will be able to recognize that static methods don't support polymorphism at runtime. FREE ACCESS
-
6m 16sUpon completion of this video, you will be able to recognize how static methods are bound using compile-time rather than run-time binding. FREE ACCESS
-
8m 56sFind out how to override the .toString method, which is inherited from java.lang.Object. FREE ACCESS
-
8m 22sAfter completing this video, you will be able to describe how the .equals method and the == operator are related to each other. FREE ACCESS
-
7m 21sIn this video, learn how to correctly override the .hashCode method and write the code to correctly override the .equals method, which is inherited from java.lang.Object. FREE ACCESS
-
10m 17sIn this video, you will learn how to correctly and completely implement the .hashCode contract. FREE ACCESS
-
1m 37s
EARN A DIGITAL BADGE WHEN YOU COMPLETE THIS COURSE
Skillsoft is providing you the opportunity to earn a digital badge upon successful completion on some of our courses, which can be shared on any social network or business platform.
Digital badges are yours to keep, forever.