Purdue ECE 462 - Object-Oriented Programming (178 pages)

Previewing pages 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 167, 168, 169, 170, 171, 172, 173, 174, 175, 176, 177, 178 of 178 page document View the full content.
View Full Document

Object-Oriented Programming



Previewing pages 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 167, 168, 169, 170, 171, 172, 173, 174, 175, 176, 177, 178 of actual document.

View the full content.
View Full Document
View Full Document

Object-Oriented Programming

102 views

Lecture Notes


Pages:
178
School:
Purdue University
Course:
Ece 462 - Object-Oriented Programming using C++ and Java
Object-Oriented Programming using C++ and Java Documents

Unformatted text preview:

ECE 462 Object Oriented Programming using C and Java Object and Class Yung Hsiang Lu yunglu purdue edu YHL Object and Class 1 What is an Object An object can be a concrete and tangible entity that can be separated with unique properties you your book your car my computer Tom Amy s computer your phone Sam s digital camera Jennifer s cat YHL Object and Class 2 What is an object An object can be abstract and does not have to be tangible Purdue ECE s student database the email sent by Mark at 9 07AM on 2008 03 22 the web page of Purdue ECE 462 the song played in WBAA at 7 02PM last night An object can contain other objects a car wheels engine door windshield a house kitchen bedrooms living room a laptop keyboard display processor YHL Object and Class 3 Objects Three Properties Each object is unique and can be identified using name serial number relationship with another object Each object has a set of attributes such as location speed size address phone number on off Each object has unique behaviors such as ring phone accelerate and move car take picture camera send email computer display caller pager Each object has three important properties unique identity attributes noun behavior action verb YHL Object and Class 4 Objects Interactions You object press action the pedal object of your car object As a result your car accelerate action When your phone object rings action and alerts action you object of an incoming call state you answer action the call state You submit action homework object and it is graded action with a score state YHL Object and Class 5 Object as a Special Case A person is an object A student is also an object A student is a special case of a person A student has all attributes of a person name home address parents A student has all behavior of a person eat sleep talk A student has something that a person may not have attributes student ID list of courses classmates behavior submit homework take exam YHL Object and Class 6 What is a Class A class



View Full Document

Access the best Study Guides, Lecture Notes and Practice Exams

Loading Unlocking...
Login

Join to view Object-Oriented Programming and access 3M+ class-specific study document.

or
We will never post anything without your permission.
Don't have an account?
Sign Up

Join to view Object-Oriented Programming and access 3M+ class-specific study document.

or

By creating an account you agree to our Privacy Policy and Terms Of Use

Already a member?