Object-Oriented Programming (OOP) Inheritance - form of software reusability New classes created from existing ones Absorb attributes and behaviors, and add in their own Override methods - redefine inherited methods Subclass inherits from superclass Direct superclass - subclass explicitly inherits Indirect superclass - subclass inherits from two or more levels up the class hierarchy Polymorphism Write programs in a general fashion to handle a wide variety of classes Abstraction - seeing the big picture. | Java Object-Oriented Programming Outline 1 Introduction 2 Superclasses and Subclasses 3 protected Members 4 Relationship between Superclass Objects and Subclass Objects 5 Implicit Subclass-Object-to-Superclass-Object Conversion 6 Software Engineering with Inheritance 7 Composition vs. Inheritance 8 Introduction to Polymorphism 9 Type Fields and switch Statements 10 Dynamic Method Binding 11 final Methods and Classes 12 Abstract Superclasses and Concrete Classes 13 Polymorphism Example 14 New Classes and Dynamic Binding 15 Case Study: Inheriting Interface and Implementation 16 Case Study: Creating and Using Interfaces 17 Inner Class Definitions 18 Notes on Inner Class Definitions 1. Introduction Object-Oriented Programming (OOP) Inheritance - form of software reusability New classes created from existing ones Absorb attributes and behaviors, and add in their own Override methods - redefine inherited methods Subclass inherits from superclass Direct superclass - subclass explicitly . | Java Object-Oriented Programming Outline 1 Introduction 2 Superclasses and Subclasses 3 protected Members 4 Relationship between Superclass Objects and Subclass Objects 5 Implicit Subclass-Object-to-Superclass-Object Conversion 6 Software Engineering with Inheritance 7 Composition vs. Inheritance 8 Introduction to Polymorphism 9 Type Fields and switch Statements 10 Dynamic Method Binding 11 final Methods and Classes 12 Abstract Superclasses and Concrete Classes 13 Polymorphism Example 14 New Classes and Dynamic Binding 15 Case Study: Inheriting Interface and Implementation 16 Case Study: Creating and Using Interfaces 17 Inner Class Definitions 18 Notes on Inner Class Definitions 1. Introduction Object-Oriented Programming (OOP) Inheritance - form of software reusability New classes created from existing ones Absorb attributes and behaviors, and add in their own Override methods - redefine inherited methods Subclass inherits from superclass Direct superclass - subclass explicitly inherits Indirect superclass - subclass inherits from two or more levels up the class hierarchy Polymorphism Write programs in a general fashion to handle a wide variety of classes Abstraction - seeing the big picture 1 Introduction (II) Object-Oriented Programming Introduce protected member access Relationships "is a" - inheritance Object of subclass "is a" object of the superclass "has a" - composition Object "has a" object of another class as a member Class libraries New classes can inherit from them Someday software may be constructed from standardized, reusable components (like hardware) Create more powerful software 2 Superclasses and Subclasses Inheritance example A rectangle "is a" quadrilateral Rectangle is a specific type of quadrilateral Quadrilateral is the superclass, rectangle is the subclass Incorrect to say quadrilateral "is a" rectangle Naming can be confusing because subclass has more features than superclass Subclass more specific than superclass Every subclass "is an" .