CENG 535/410 Design Patterns

Home

 

Fatih University, Computer Engineering Department
Fall Semester 2003
Thursday 9:00 - 12:00, E303

 
Instructor: Halûk Gümüşkaya Teaching Assistant: Engin Tozal
Office: EA301 Office: ....
Office Hours: Mon, Tue, Wed: 13:00-14:00 Office Hours: ...
Office Phone: 0.212.889 0810-1036 Office Phone: ....
E-mail: haluk@fatih.edu.tr E-mail: engintozal@fatih.edu.tr
   
Mostly Static Information: Mostly Dynamic Information:
bulletCourse Description
bullet Lecture Announcements
bullet Prerequisites
bullet

Course Materials

bullet Lecture Schedule
bullet

References

bullet Textbooks
bullet Project
bullet Tools and Development Environments
bullet Grades
bullet Grading
 
bullet Academic Integrity
 

Course Description

The course will cover the rationale and benefits of object-oriented design patterns. Several example problems will be studied to investigate the development of good design patterns. Specific patterns, such as Observer, State, Adapter and Abstract Factory, will be discussed. Programming assignments will provide experience in the use of these patterns.

Details

Designing object-oriented software is hard. Designing flexible, extensible, and reusable object-oriented software is even harder. Over the years, expert object-oriented designers have discovered solutions to many design problems that reoccur again and again. Now, some of these solutions, called Design Patterns, have been analyzed and documented. This course provides an introduction to these design patterns which will allow you to apply the knowledge of experts in your project.

Design patterns are reusable solutions to common software problems. They are distilled design lessons, learned the hard way by vast numbers of developers over decades. They capture successful experiences and convey expert insight to beginners; a good alternate name might be "learn from my pain." Design patterns are the hottest new development in the object-oriented design world.

An experienced software architect knows many patterns. A large part of the job of an architect is teaching those patterns to the software development team, and ensuring that the patterns are used correctly. Writing them down makes it easier for the architect to teach them, having standard names for patterns makes it easier for architects to communicate with each other, and developing an industry-wide set of standard patterns will raise the quality of our profession.

This course is an in-depth introduction to design patterns. It is design and programming intensive, and uses UML and Java for presentation and analysis of design patterns and for assignments and projects. This course is intended for experienced programmers and software engineers who want to better understand object-oriented design and make the transition from software engineer to software architect.

The course begins with an overview of standard O-O concepts before moving to design patterns in depth. The best selling object-oriented book is "Design Patterns" by Erich Gamma, Richard Helm, Ralph Johnson, and John Vlisssides (the famous "Gang of Four - GoF" book). All the currently popular patterns covered by the GoF book are reviewed. Students will learn more than 30 object-oriented patterns, including most of the 23 micro-architectures in GoF book. Application examples and code snippets are provided to illustrate the patterns and the rationale for using that pattern in a given situation.

Goals

This course will help students:
bullet

familiarity with the situations and motivations that call for using a wide range of design patterns,

bullet

ability to use design patterns appropriately,

bullet

make your software reusable and maintainable from the beginning,

bullet

develop advanced object-oriented design and programming insight, and

bullet

apply modern software engineering development principles---focusing on extreme programming, unit testing, and refactoring.

After the first weeks devoted to covering the basics of design patterns, extreme programming, unit testing, and refactoring, students will apply design patterns to a real software project and be expected to deliver a working product. Students must be committed to delivering an elegant design, robust code, well-written documentation, ( and be able to present their work to an audience concisely and intelligibly ).

Prerequisites

Courses: CENG 217 Object Oriented Programming, CENG 102 Computer Programming II, CENG 302 Software Engineering.

This course assumes considerable experience in object-oriented analysis, design and programming.  It will use UML and Java, so familiarity with these languages is required.

Philosophy

Developing high quality communication software is hard; developing high quality reusable communication software is even harder. The principles, methods, and skills required to develop reusable software cannot be learned by generalities. Instead, developers must learn through experience how reusable software components and frameworks can be designed, implemented, optimized, validated, maintained, and enhanced by applying good development practices and patterns.  (Douglas C. Schmidt)

Lecture Schedule

This is the tentative schedule. Please check it once before the lecture.

Week Topic(s) Covered

1

Course Overview, Motivation for Patterns and Frameworks, Types of Software Patterns, Introduction to GoF Design Patterns

2

First GoF Pattern Observer and an Architectural Pattern: Model View Controller (MVC)

3

Encapsulating Object Creation: Creational Patterns (1): Simple Factory, Factory Method, Abstract Factory, Singleton.

4

Encapsulating Object Creation: Creational Patterns (2): Builder, Prototype.

5

Structural Patterns (1): Adapter, Bridge, Unit Testing and JUnit

6

Structural Patterns (2): Composite, Decorator

7

Structural Patterns (3): Facade, Flyweight, Proxy, and Design Patterns in Together

8

Behavioral Patterns (1): Introduction to Behavioral Patterns, Chain of Responsibility, Command, Interpreter, Iterator
9 Behavioral Patterns (2): Mediator, Memento, Observer (covered before), State
10 Behavioral Patterns (3): Strategy, Template

Some Other Possible Subjects

Basic Patterns
  Delegation vs. Inheritance
  Interface
  Immutable
  Null Object
  Marker Interface
  General Responsibility Assignment Patterns

Other Micro-Architecture Patterns
  Object Pool
  Dynamic Linkage
  Cache Management
  Snapshot
  Type Object
  Extension Object
  Smart Pointer (C++)

Concurrency Patterns
  Single Threaded Execution
  Guarded Suspension
  Balking
  Scheduler
  Read/Write Lock
  Producer/Consumer
  Two-Phase Termination
  Double-Checked Locking
  Patterns-Oriented Software Architecture

Architectural Patterns
  Layers Architect
  Pipes & Filters Architect
  Blackboard Architect
  Broker
  Model-View-Controller
  Presentation-Abstraction-Control
  Reflection
  Microkernel
  Summary: How to Select an Architecture

Catalog of J2EE Patterns
  J2EE Pattern Relationships
  Process Patterns
  The Selfish Class
  Patterns for Evolving Frameworks
  Patterns for Designing in Teams
  Patterns for System Testing

Textbooks

   Required

bullet

Design Patterns, Elements of Reusable Object-Oriented Software, Erich Gamma, Richard Helm, Ralph Johnson, and John Vlissides (The Gang of Four), Addison Wesley. 1995.

bullet

The Design Patterns Java Companion, James Cooper, Addison Wesley, October 2, 1998. (you can donwload)

bullet

Thinking in Patterns, Problem-Solving Techniques using Java, Bruce Eckel, President, MindView, Inc. (you can donwload)
 

   Recommended

bullet

Applied Java Patterns, 1st edition, S. A. Stelting, O. Maassen, Prentice Hall, 608 pages, 2001.

bullet

Refactoring: Improving the Design of Existing Code, Martin Fowler, Kent Beck (Contributor), John Brant (Contributor), William Opdyke, Don Roberts, 464 pages, Addison-Wesley Pub Co; 1st edition, 1999.

bullet

Patterns of Enterprise Application Architecture, Martin Fowler, David Rice, Matthew Foemmel, Edward Hieatt, Robert Mee, Randy Stafford, Addison Wesley, 1st edition, 2002.

Tools and Development Environments

bullet

Together for JBuilder 6.1 (modeling, design and documentation tool)

bullet

Builder 9 (implementation tool)

bullet

MySQL (for database applications)

Grading
25 % : Homework Assignments
35 % : Midterm
40 % : Final Exam (a comprehensive exam at the end of the course)

Homework: There will be homework in every 2 or 3 weeks. The purpose of the homework is to give you a chance to exercise the knowledge gained from the recent class material.

Midterm Exam: There will be one midterm exam that will be given around the mid of the semester.

Final Exam: There will be one final exam that will be given during final exams period of the semester.

Academic Integrity

We will be very careful in grading the projects, homeworks, exams so that everybody gets the grade that he/she deserves. Copying will not be tolerated and will be checked and punished rigorously.

The Fatih University has a very strict policy on academic dishonesty. All work on homeworks and examinations must be strictly individual.  Violations of this policy will result in an F grade for the class and may result in suspension/expulsion from the university.

 

Home