SOEN 343 Software Design Computer Science and Software Engineering Department Concordia University Fall 2004 Instructor: Patrice Chalin.

Slides:



Advertisements
Similar presentations
STRING AN EXAMPLE OF REFERENCE DATA TYPE. 2 Primitive Data Types  The eight Java primitive data types are:  byte  short  int  long  float  double.
Advertisements

Lecture 27 Exam outline Boxing of primitive types in Java 1.5 Generic types in Java 1.5.
CSE 115 / 503 Introduction to Computer Science For Majors I Carl Alphonce 219 Bell Hall.
Fall 2005CSE 115/503 Introduction to Computer Science I1 Lecture #4 Agenda Announcements Review Questions? Classes and objects UML class diagrams Creating.
XP and Refactoring David Talby. Development Methodologies The Software Crisis – 84% of software projects are not on time – 31% of software projects never.
CSE 115 / 503 Introduction to Computer Science For Majors I Carl Alphonce 219 Bell Hall.
13-Jul-15 Refactoring II. Books Design Patterns is the classic book by Erich Gamma, Richard Helm, Ralph Johnson, and John Vlissides Basically a catalog.
Comp 248 Introduction to Programming Chapter 4 - Defining Classes Part A Dr. Aiman Hanna Department of Computer Science & Software Engineering Concordia.
Lecture 6 Software Testing and jUnit CS140 Dick Steflik.
Sadegh Aliakbary Sharif University of Technology Fall 2011.
Advanced Programing practices
Software Refactoring Part I: Introduction Bartosz Walter Advanced Object-Oriented Design Lecture 5.
Sadegh Aliakbary Sharif University of Technology Spring 2012.
© ALEXANDRE CUVA  VERSION 2.00 Test Driven Design.
SOEN 343 Software Design Section H Fall 2006 Dr Greg Butler
Spring 2008 Mark Fontenot CSE 1341 Principles of Computer Science I Note Set 2.
Refactoring1 Refactoring DEPARTMENT OF COMPUTER SCIENCE AND SOFTWARE ENGINEERING CONCORDIA UNIVERSITY February 6, 2009.
Refactoring An Automated Tool for the Tiger Language Leslie A Hensley
Refactoring Deciding what to make a superclass or interface is difficult. Some of these refactorings are helpful. Some research items include Inheritance.
Advanced Programming in Java
SOEN 343 Software Design Section H Fall 2006 Dr Greg Butler
BEGINNING PROGRAMMING.  Literally – giving instructions to a computer so that it does what you want  Practically – using a programming language (such.
Sadegh Aliakbary Sharif University of Technology Spring 2011.
Salman Marvasti Sharif University of Technology Winter 2015.
School of Computer Science & Information Technology G6DICP - Lecture 4 Variables, data types & decision making.
SOEN 343 Software Design Section H Fall 2006 Dr Greg Butler
Refactoring Agile Development Project. Lecture roadmap Refactoring Some issues to address when coding.
Sadegh Aliakbary Sharif University of Technology Fall 2010.
Review A program is… a set of instructions that tell a computer what to do. Programs can also be called… software. Hardware refers to… the physical components.
Basic Data Types อ. ยืนยง กันทะเนตร คณะเทคโนโลยีสารสนเทศและการสื่อสาร มหาวิทยาลัยพะเยา Chapter 4.
UMass Lowell Computer Science Java and Distributed Computing Prof. Karen Daniels Fall, 2000 Lecture 10 Java Fundamentals Objects/ClassesMethods.
CSC 222: Object-Oriented Programming
CSC 222: Object-Oriented Programming
Objects as a programming concept
CS 153: Concepts of Compiler Design August 29 Class Meeting
CSC 221: Computer Programming I Fall 2005
SOEN 343 Software Design Computer Science and Software Engineering Department Concordia University Fall 2005 Instructor: Patrice Chalin.
Refactoring II 21-Sep-18.
SOEN 343 Software Design Computer Science and Software Engineering Department Concordia University Fall 2004 Instructor: Patrice Chalin.
Relational Algebra 461 The slides for this text are organized into chapters. This lecture covers relational algebra, from Chapter 4. The relational calculus.
SOEN 343 Software Design Computer Science and Software Engineering Department Concordia University Fall 2004 Instructor: Patrice Chalin.
SOEN 343 Software Design Computer Science and Software Engineering Department Concordia University Fall 2004 Instructor: Patrice Chalin.
SOEN 343 Software Design Computer Science and Software Engineering Department Concordia University Fall 2005 Instructor: Patrice Chalin.
SOEN 343 Software Design Computer Science and Software Engineering Department Concordia University Fall 2004 Instructor: Patrice Chalin.
SOEN 343 Software Design Computer Science and Software Engineering Department Concordia University Fall 2004 Instructor: Patrice Chalin.
SOEN 343 Software Design Computer Science and Software Engineering Department Concordia University Fall 2005 Instructor: Patrice Chalin.
SOEN 343 Software Design Computer Science and Software Engineering Department Concordia University Fall 2004 Instructor: Patrice Chalin.
SOEN 343 Software Design Computer Science and Software Engineering Department Concordia University Fall 2004 Instructor: Patrice Chalin.
eXtreme Programming (XP) and eXtreme Modeling (XM)
SOEN 343 Software Design Computer Science and Software Engineering Department Concordia University Fall 2004 Instructor: Patrice Chalin.
SOEN 343 Software Design Computer Science and Software Engineering Department Concordia University Fall 2005 Instructor: Patrice Chalin.
SOEN 343 Software Design Computer Science and Software Engineering Department Concordia University Fall 2004 Instructor: Patrice Chalin.
SOEN 343 Software Design Computer Science and Software Engineering Department Concordia University Fall 2004 Instructor: Patrice Chalin.
SWE 619 Software Construction Last Modified, Fall 2015 Paul Ammann
Advanced Programming Behnam Hatami Fall 2017.
From C++ to Java Java history: Oak, toaster-ovens, internet language, panacea What it is O-O language, not a hybrid (cf. C++) compiled to byte-code, executed.
SOEN 343 Software Design Computer Science and Software Engineering Department Concordia University Fall 2005 Instructor: Patrice Chalin.
SOEN 343 Software Design Computer Science and Software Engineering Department Concordia University Fall 2005 Instructor: Patrice Chalin.
SOEN 343 Software Design Computer Science and Software Engineering Department Concordia University Fall 2004 Instructor: Patrice Chalin.
SOEN 343 Software Design Computer Science and Software Engineering Department Concordia University Fall 2004 Instructor: Patrice Chalin.
Refactoring II 5-Feb-19.
SOEN 343 Software Design Computer Science and Software Engineering Department Concordia University Fall 2004 Instructor: Patrice Chalin.
Introduction to Data Structure
SOEN 343 Software Design Computer Science and Software Engineering Department Concordia University Fall 2004 Instructor: Patrice Chalin.
SOEN 343 Software Design Computer Science and Software Engineering Department Concordia University Fall 2004 Instructor: Patrice Chalin.
SOEN 343 Software Design Computer Science and Software Engineering Department Concordia University Fall 2004 Instructor: Patrice Chalin.
Software Design Lecture : 39.
SOEN 343 Software Design Computer Science and Software Engineering Department Concordia University Fall 2004 Instructor: Patrice Chalin.
Refactoring.
Presentation transcript:

SOEN 343 Software Design Computer Science and Software Engineering Department Concordia University Fall 2004 Instructor: Patrice Chalin

Reminders Hand in your solutions to Exercise Set 1 (they will be returned). Homework is given in this lecture (see last slide). 4/7/2019 SOEN 343, © P.Chalin,

Agenda – Lecture 2a OO fundamentals continued. Design Delegation, polymorphism. Design “Levels” Methods UML flash: a language for expressing designs. Test Drive Development (TDD) and refactoring – a first demonstration – skipped, ran out of time due to room change delay. 4/7/2019 SOEN 343, © P.Chalin,

Java – some details to be read on your own. Primitive types: include Floating point : float, double. Integral : byte,short,int,long,char. boolean, is not assignment compatible with integral types; explicit conversion required. boolean b = (i == 0 ? false : true); Class types for “boxing”: Float, Double, Byte, … Boolean. E.g. Boolean o = new Boolean(b); 4/7/2019 SOEN 343, © P.Chalin,

java.util.Vector Vector class Example of use Implements a growable array of objects. Example of use String s = …; Vector v = new Vector(); v.add(s); // adds to end String t = v.elementAt(0); v.remove(s); int i = v.size(); List interface ArrayList class 4/7/2019 SOEN 343, © P.Chalin,

OO Fundamentals (Exercise Set 2) Answer Q1 and Q2 of Exercise Set 2 Delegation. Polymorphism. 4/7/2019 SOEN 343, © P.Chalin,

Design vs. Requirements and Implementation. Architectural Detailed 4/7/2019 SOEN 343, © P.Chalin,

Design Levels Architectural design Detailed design . Detailed design Implementation (executable designs) 4/7/2019 SOEN 343, © P.Chalin,

Two complimentary approaches to design Planned Design vs. Evolutionary Design Can we get away with only planned design? 4/7/2019 SOEN 343, © P.Chalin,

Evolutionary Design Practices Important characteristics XP Test driven development (TDD) Do not add code unless you have a test failing … Important characteristics “Full” automated test suites Refactoring Help us learn detailed design idioms, patterns, … 4/7/2019 SOEN 343, © P.Chalin,

Refactoring A refactoring is a change made to the internal structure of S/W to make it easier to understand and less expensive to modify, without changing its observable behavior. 4/7/2019 SOEN 343, © P.Chalin,

Can you pick out a good design? What is a good design? Satisfies user needs. Is a simple as possible. Kent Beck: Runs all tests Reveals intention. No duplication. Fewest number of classes or methods … can you smell bad design choices? 4/7/2019 SOEN 343, © P.Chalin,

“Bad Smells” Duplication. Long method. … we will be learning more. 4/7/2019 SOEN 343, © P.Chalin,

Further Reading Martin Fowler’s, “Is Design Dead”? martinfowler.com/articles/designDead.html 4/7/2019 SOEN 343, © P.Chalin,

UML Class Diagram – Class Parts named in class 4/7/2019 SOEN 343, © P.Chalin,

UML Class Diagram Generalization (inheritance) Dependency 4/7/2019 SOEN 343, © P.Chalin,

[Homework] Exercise Set 2 Complete the exercise set 2. 4/7/2019 SOEN 343, © P.Chalin,