Download presentation
Presentation is loading. Please wait.
Published byKevin Chase Modified over 9 years ago
1
Copyright © 2002, Systems and Computer Engineering, Carleton University. 94.204-01-Intro.ppt 1 94.204* Object-Oriented Software Development Unit 1 Course Introduction : Goals and Overview revised January 2002
2
Copyright © 2002, Systems and Computer Engineering, Carleton University. 94.204-01-Intro.ppt 2 94.204 Goals Course Title is “Object-Oriented Software Development” The Objectives are : –Software Development …. Beyond learning the syntax of a programming language Setting our eyes on the whole life cycle of a program –… Using Object-Orientation A Development Paradigm (as opposed to the functional paradigm)
3
Copyright © 2002, Systems and Computer Engineering, Carleton University. 94.204-01-Intro.ppt 3 Software Development Software development involves the following activities –Requirements Gathering Informally describe, in plain English, all that the software (S/W) must do –Requirements Analysis (OOA) Formally specify the S/W behaviour –Design (OOD) Formally specify the S/W architecture, S/W components (classes) and component behaviours –Implementation (programming) (OOP) Code the S/W Our focus in this course –Testing, Verification and Validation Ensure S/W was done "right" –Maintenance Misunderstood requirements, upgrades 94.202 94.204
4
Copyright © 2002, Systems and Computer Engineering, Carleton University. 94.204-01-Intro.ppt 4 Software Development What makes a good program ? Obviously, a program should be : –Correct –Reliable High Availability Graceful failures when they do occur –Efficient – in time and memory usage
5
Copyright © 2002, Systems and Computer Engineering, Carleton University. 94.204-01-Intro.ppt 5 Software Development But, more ambiguous yet equally important measures of a good program are : –Maintainable Readable by others that come after you. Easy to make corrections (localised) –Reusable If designed as a general solution, rather for just one context, a good program can be adapted to other contexts. –Extensible The customer always wants more One little change shouldn’t collapse the whole design.
6
Copyright © 2002, Systems and Computer Engineering, Carleton University. 94.204-01-Intro.ppt 6 Software Development In this course, we shall introduce mechanisms for making good “industrial-strength” programs, including : –Re-using Code via Software Libraries –Incorporating Reuse, Extensibility & Maintainability, using Object Orientation –Re-use with Design Patterns : Learning from others’ design experiences.
7
Copyright © 2002, Systems and Computer Engineering, Carleton University. 94.204-01-Intro.ppt 7 Object-Orientation You’ve met objects before but now you will learn it as a development paradigm. Why object-oriented ? – Because it promotes all the goals identified before : Reuse/Extensible/Maintainable –How ? Encapsulation Polymorphism Abstraction
8
Copyright © 2002, Systems and Computer Engineering, Carleton University. 94.204-01-Intro.ppt 8 Abstraction Abstraction is the process of capturing the essential while suppressing the detail –Procedural abstraction allow actions to be described in high-level terms –Data abstraction allows to information to be described in high-level terms
9
Copyright © 2002, Systems and Computer Engineering, Carleton University. 94.204-01-Intro.ppt 9 Procedural Abstraction Divide and conquer –Procedural programming is essentially the process of taking a large problem and successively breaking it up into procedures that are easier to solve This is called top-down refinement –The smallest of the procedures may require a few lines or a page of programming statements Visit friend in Vancouver Go to Ottawa airportFlyGo to friend's house Go outsideTake taxiGo outsideTake taxiGo inside...
10
Copyright © 2002, Systems and Computer Engineering, Carleton University. 94.204-01-Intro.ppt 10 Group and encapsulate information A Pair is an abstraction –It could represents many possible things x, y position coordinates A = x B = y Name and number A = name B = number –It could have many possible representations It could even have additional hidden (?) attributes Data Abstraction Pair AB?
11
Copyright © 2002, Systems and Computer Engineering, Carleton University. 94.204-01-Intro.ppt 11 Abstraction Without abstraction, the programmer must face an overwhelming level of detail –Cannot form a mental model of the top- level structure and behaviour of the program –We can describe how to get from location A to B can be done without describing how to operate a car, … how car engines work, how fuel is burned by the engine, etc.. "Abstraction" is both a verb and a noun –The activity of abstraction is about creating abstractions
12
Copyright © 2002, Systems and Computer Engineering, Carleton University. 94.204-01-Intro.ppt 12 Encapsulation Programming languages enforce abstraction via encapsulation Encapsulation is an information hiding mechanism that hides detailed internal information about an abstraction –The mechanical devices of your car are encapsulated (hidden) by the chassis of the car An abstraction is encapsulated by a well- defined interface, which defines how the abstraction can be used –A car's interface consists of steering wheel, accelerator, brake, etc We do not need to continually adjust the fuel/air mixture to drive the car - it is hidden from us
13
Copyright © 2002, Systems and Computer Engineering, Carleton University. 94.204-01-Intro.ppt 13 Information Hiding in ADTs Example : Recall from 94.202 : An ADT forces a separation between how a class of objects is used and how that class of objects is internally implemented –Separation of these concerns was a big step forward in S/W development –Keep data (state) private so there can be no interference: –State hiding (information hiding) State Interface Methods
14
Copyright © 2002, Systems and Computer Engineering, Carleton University. 94.204-01-Intro.ppt 14 Polymorphism Basic Idea : Allowing object classes to respond differently, depending on their type. Example : Send a message to a shape object to request its area. Polymorphism is a most powerful mechanism, and is at the heart of inheritance. Yet, beyond this, we must defer for now.
15
Copyright © 2002, Systems and Computer Engineering, Carleton University. 94.204-01-Intro.ppt 15 Object-Oriented Software Development To recap : Our goal is to introduce you to the design and implementation of object-oriented programs. To learn OO as a general programming paradigm To learn Java as a particular OO language To learn UML as a OO design notation UML Unified Modeling Language A graphical notation for OO software design Diagrams depict the architecture and behaviour of an OO system
16
Copyright © 2002, Systems and Computer Engineering, Carleton University. 94.204-01-Intro.ppt 16 Course Overview Part I : Introduction and Practical Matters –Object Oriented Design –Industrial Strength Software Essentially establishes the expectations for your assignments –Advanced Java : static, exceptions Part II : Software Development Using Libraries –Example : Vector ADT
17
Copyright © 2002, Systems and Computer Engineering, Carleton University. 94.204-01-Intro.ppt 17 Course Overview Part III : Software Development with Object Orientation –Inheritance –Using … Class Object Example : Hashtable –Case Study : The Exception Hierarchy –Re-Using Classes : Inheritance and Composition –Polymorphism –Abstract Classes and Interfaces –Case Study : JDK I/O Streams
18
Copyright © 2002, Systems and Computer Engineering, Carleton University. 94.204-01-Intro.ppt 18 Course Overview Part IV : Software Development Using Patterns –Introduction Example : Iterator –Selected Patterns : Example : Observable Example : States and FSMs –Case Study : JDK Collection Classes –Case Study : GUI Building with Swing
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.