Slides0424 - COP 3330 Slides 4/24 Topics Final Exam Review...

Info iconThis preview shows pages 1–9. Sign up to view the full content.

View Full Document Right Arrow Icon
Slides 4/24 COP 3330
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Topics Final Exam Review
Background image of page 2
Final Exam The final exam is Friday, May 1 st at 10:00 AM in the usual room Don't forget!
Background image of page 3

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Class Basics Instance Variables (Fields) Instance Methods Static Variables (Fields) Static Methods Constructors
Background image of page 4
Inheritance The keyword extends defines an is-a relationship between classes - If Foo extends Bar, then Foo is-a Bar - That means that variables of type Bar can also hold objects of type Foo The keyword implements also defines an is-a relationship, but between classes and interfaces - If Foo implements Comparable<Foo>, then Foo is-a Comparable<Foo> Dynamic binding refers to waiting until runtime to determine what code a method call will go to
Background image of page 5

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Inheritance Interfaces provide a set of methods that must be written in anything that implements the interface Abstract classes provide partial implementations of a class, but it’s left to anything that inherits from it to fill in the gaps
Background image of page 6
instanceof foo instanceof Bar evaluates to - true: only if foo holds an object that can be treated as a Bar - Compile error: if it is illegal for foo to hold something that could be treated as a Bar - false: if foo could hold something that can be treated as a Bar, but doesn’t
Background image of page 7

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
super super refers to the parent class - In a constructor, the very first thing that happens is a call to the super constructor - In any instance method, super is the part of this object that comes from the parent class
Background image of page 8
Image of page 9
This is the end of the preview. Sign up to access the rest of the document.

This note was uploaded on 02/09/2010 for the course CS COP 3330 taught by Professor Douglass during the Spring '09 term at University of Central Florida.

Page1 / 26

Slides0424 - COP 3330 Slides 4/24 Topics Final Exam Review...

This preview shows document pages 1 - 9. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online