ITI 1121 Lecture Notes - Lecture 2: Tandem Bicycle

132 views2 pages

Document Summary

Objects define their interaction with the outside world through the methods that they expose. Objects might have things in common but may have somethings different about them. Ex/ a bicycle can have many different types of types (mountain bike, tandem bike, road bike) Methods form the object"s interface with the outside world; the buttons on front of the t. v, for example are the interface between you and the wires on the other side of its plastic casing. Object oriented programming allows classes to inherit commonly used state and behaviors from another class. In the most common form, an interface is a group of related methods with empty bodies. A bicycle"s behavior, if specified as an interface: Now in this class, the class bicycle will become the super class of the 3 different bikes. In java, a class can only have one direct superclass and each super class can have unlimited subclasses.

Get access

Grade+20% off
$8 USD/m$10 USD/m
Billed $96 USD annually
Grade+
Homework Help
Study Guides
Textbook Solutions
Class Notes
Textbook Notes
Booster Class
40 Verified Answers
Class+
$8 USD/m
Billed $96 USD annually
Class+
Homework Help
Study Guides
Textbook Solutions
Class Notes
Textbook Notes
Booster Class
30 Verified Answers

Related Documents