Advertisement
Guest User

Untitled

a guest
Oct 24th, 2016
60
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.76 KB | None | 0 0
  1. summary of Key Concepts
  2. ■ Inheritance is the process of deriving a new class from an existing one.
  3. ■ One purpose of inheritance is to reuse existing software.
  4. ■ Inheritance creates an is-a relationship between the parent and child classes.
  5. ■ Protected visibility provides the best possible encapsulation that permits inheritance.
  6. ■ A parent’s constructor can be invoked using the super reference.
  7. ■ A child class can override (redefine) the parent’s definition of an inherited
  8. method.
  9. ■ The child of one class can be the parent of one or more other classes, cre- ating a class hierarchy.
  10. ■ Common features should be located as high in a class hierarchy as is rea- sonably possible.
  11. ■ All Java classes are derived, directly or indirectly, from the Object class.
  12. ■ The toString and equals methods are inherited by every class in every
  13. Java program.
  14. ■ An abstract class cannot be instantiated. It represents a concept on which other classes can build their definitions.
  15. ■ A class derived from an abstract parent must override all of its parent’s abstract methods, or the derived class will also be considered abstract.
  16. ■ Inheritance can be applied to interfaces so that one interface can be derived from another.
  17. ■ Private members are inherited by the child class, but cannot be referenced directly by name. They may be used indirectly, however.
  18. ■ Software design must carefully and specifically address inheritance.
  19. ■ The final modifier can be used to restrict inheritance.
  20. ■ The classes that represent Java GUI components are organized into a class hierarchy.
  21. ■ A listener class can be created by deriving it from an event adapter class.
  22. ■ A Timer object generates action events at regular intervals and can be used to control an animation.
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement