A More Formal Definition Attributes ◆ An object is an entity with a well-defined boundary and identity that encapsulates state and behavior. State is represented by ■ attributes and relationships. Behavior is represented by operations,methods and state machines. Object Operations Object Oriented Analysis and Design 11
Object Oriented Analysis and Design 11 A More Formal Definition An object is an entity with a well-defined boundary and identity that encapsulates state and behavior. ▪ State is represented by attributes and relationships. ▪ Behavior is represented by operations, methods, and state machines. Object Operations Attributes
An Object Has State State is a condition or situation during the life of an object,which satisfies some condition, performs some activity,or waits for some event. ◆ The state of an object normally changes over time. Name:J Clark Employee ID:567138 HireDate:07/25/1991 Status:Tenured O Discipline:Finance ☐MaxLoad:3 Name:J Clark Employee ID:567138 Date Hired:July 25,1991 Status:Tenured Discipline:Finance Professor Clark Maximum Course Load:3 classes Object Oriented Analysis and Design 12
Object Oriented Analysis and Design 12 An Object Has State State is a condition or situation during the life of an object, which satisfies some condition, performs some activity, or waits for some event. The state of an object normally changes over time. Name: J Clark Employee ID: 567138 Date Hired: July 25, 1991 Status: Tenured Discipline: Finance Maximum Course Load: 3 classes Name: J Clark Employee ID: 567138 HireDate: 07/25/1991 Status: Tenured Discipline: Finance MaxLoad: 3 Professor Clark
An Object Has Behavior Behavior determines how an object acts and reacts. The visible behavior of an object is modeled by a set of messages it can respond to (operations that the object can perform). SubmitFinalGrades() AcceptCourseOffering() 0 SetMaxLoad() Professor Clark's behavior Submit Final Grades TakeSabbatical() Accept Course Offering Take Sabbatical Professor Clark Maximum Course Load:3 classes Object Oriented Analysis and Design 13
Object Oriented Analysis and Design 13 An Object Has Behavior Behavior determines how an object acts and reacts. The visible behavior of an object is modeled by a set of messages it can respond to (operations that the object can perform). Professor Clark’s behavior Submit Final Grades Accept Course Offering Take Sabbatical Maximum Course Load: 3 classes TakeSabbatical() Professor Clark