DOC PREVIEW
SJSU CMPE 196G - Cataloging of Design Patterns
Pages 23

This preview shows page 1-2-22-23 out of 23 pages.

Save
View full document
View full document
Premium Document
Do you want full access? Go Premium and unlock all 23 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 23 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 23 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 23 pages.
Access to all documents
Download any document
Ad free experience
Premium Document
Do you want full access? Go Premium and unlock all 23 pages.
Access to all documents
Download any document
Ad free experience

Unformatted text preview:

PowerPoint PresentationLesson ObjectivesDesign Patterns Must be Documented in a CatalogDefinition and TemplateDesign Pattern TemplateDesign Pattern Template (cont’d)Slide 7Slide 8Slide 9Slide 10Common Causes of Reuse Errors in OO Software & Design PatternsHow to Select a Design PatternHow to Use a Design PatternDesign Patterns Classification is Based on Two Orthogonal CriteriaDesign Pattern SpaceCreational PatternsStructural PatternsBehavioral PatternsClassification SchemeGranularityFunctionalityStructural PrinciplesDiscussion QuestionsCopyright © 1995-2004 Active Frameworks Inc. - All Rights Reserved - V2.0 Design Pattern Catalog - Page L3-1PS95&96-MEF-L10-1Dr. M.E. FayadCreationalParadigm Shift, Inc.Software FactoryBehavioralStructuralLesson 3:Cataloging of Design PatternsLesson 3:Cataloging of Design PatternsObject-Object-OrientedOrientedDesignDesignPatternPatternssCopyright © 1995-2004 Active Frameworks Inc. - All Rights Reserved - V2.0 Design Pattern Catalog - Page L3-2PS95&96-MEF-L10-2Dr. M.E. FayadLesson ObjectivesLesson ObjectivesShow how to catalog each of the design patterns using a standard template or Gamma’s template .Compare Gamma’s template with other templateShow how to select a Design PatternShow how to use a Design PatternPresent cataloging assumptionsObjectivesCopyright © 1995-2004 Active Frameworks Inc. - All Rights Reserved - V2.0 Design Pattern Catalog - Page L3-3PS95&96-MEF-L10-3Dr. M.E. FayadDesign Patterns Must be Documented in a CatalogPatterns areEverywhere!Copyright © 1995-2004 Active Frameworks Inc. - All Rights Reserved - V2.0 Design Pattern Catalog - Page L3-4PS95&96-MEF-L10-4Dr. M.E. FayadDefinition and Template•Design Patterns are defined in terms of object-oriented concepts.•Design Patterns are sufficiently abstract to avoid specifying implementation details, thereby ensuring wide applicability.•But a pattern may provide hints about potential implementation issues.•Each design pattern in the catalog is described using a standard template.•Three major benefits of the template:–Ensure uniformity between entries in the catalog–Document each pattern in the appropriate level of details–Help compare similar patternsCopyright © 1995-2004 Active Frameworks Inc. - All Rights Reserved - V2.0 Design Pattern Catalog - Page L3-5PS95&96-MEF-L10-5Dr. M.E. FayadDesign Pattern TemplateDesign Pattern’s Name Jurisdiction CharacterizationIntentAlso Known AsMotivationApplicabilityStructureParticipantsCollaborationsConsequencesImplementationSample CodeKnown UsesRelated PatternsObserverCopyright © 1995-2004 Active Frameworks Inc. - All Rights Reserved - V2.0 Design Pattern Catalog - Page L3-6PS95&96-MEF-L10-6Dr. M.E. Fayad•Pattern Name and Classification–The pattern’s name conveys the essence of the pattern succinctly–A good name is vital because it will become part of the design vocabulary.•Intent: a short statement that answers the following questions:–What does the design pattern do?–What is its rationale and intent?–What particular design issue or problem does it address?•Also Known As–Other well-known names for the pattern, if any.Design Pattern Template (cont’d)Copyright © 1995-2004 Active Frameworks Inc. - All Rights Reserved - V2.0 Design Pattern Catalog - Page L3-7PS95&96-MEF-L10-7Dr. M.E. Fayad•Motivation–A scenario that illustrates a design problem and how the class & object structures in the pattern solve the problem. •Applicability–What are the situations in which the design pattern can be applied?–What are examples of poor designs that the pattern can address?–How can you recognize these situations?•Structure–A graphical representation of the classes in the pattern using a notation based on the Object Modeling Technique (OMT) [Rumbaugh 92] and Booch notations [Booch 94].–We also use Interaction diagram [Jacobson 92 & Booch 94] to illustrate sequences of requests and collaborations between objectsDesign Pattern Template (cont’d)Copyright © 1995-2004 Active Frameworks Inc. - All Rights Reserved - V2.0 Design Pattern Catalog - Page L3-8PS95&96-MEF-L10-8Dr. M.E. Fayad•Participants–Classes and objects and their responsibilities•Collaborations–How the participants collaborate to carry out their responsibilities.•Consequences–How does pattern support its objectives?–What are the trade-offs and results of using the pattern?–What aspect of system structure does it let you vary independently?•Implementation–What pitfalls, hints, or technique should you be aware of when implementing the pattern?–Are there language-specific issues?Design Pattern Template (cont’d)Copyright © 1995-2004 Active Frameworks Inc. - All Rights Reserved - V2.0 Design Pattern Catalog - Page L3-9PS95&96-MEF-L10-9Dr. M.E. Fayad•Sample code–Code fragments that illustrate how you can implement the pattern in C++ or smalltalk•Known Uses–Examples of the pattern found in real systems•Related Patterns–What design patterns are closely related to this one?–What are the important differences?–With which other patterns should this one be used?Design Pattern Template (cont’d)Copyright © 1995-2004 Active Frameworks Inc. - All Rights Reserved - V2.0 Design Pattern Catalog - Page L3-10PS95&96-MEF-L10-10Dr. M.E. Fayad•Frank Bushmann added three extra fields to the Gamma’s template:•Dynamic Behavior–The dynamic behavior of a pattern is illustrated•Methodology–The methodology (steps) for constructing a pattern is listed•Variants–Possible variants of the pattern are listed and describedDesign Pattern Template (cont’d)Copyright © 1995-2004 Active Frameworks Inc. - All Rights Reserved - V2.0 Design Pattern Catalog - Page L3-11PS95&96-MEF-L10-11Dr. M.E. FayadCommon Causes of Reuse Errors in OO Software & Design PatternsParticular implementation class when creating an objectParticular operationsOperating environmentSpecific Representation or implementationParticular algorithmsParticular clients and inter-object relationshipsSubclassing as an extension mechanism. Dependence on:Copyright © 1995-2004 Active Frameworks Inc. - All Rights Reserved - V2.0 Design Pattern Catalog - Page L3-12PS95&96-MEF-L10-12Dr. M.E. FayadHow to Select a Design Pattern Consider how design patterns solve design problems Scan intent sections  Study how patterns interrelate Study patterns of like purpose Examine the


View Full Document

SJSU CMPE 196G - Cataloging of Design Patterns

Download Cataloging of Design Patterns
Our administrator received your request to download this document. We will send you the file to your email shortly.
Loading Unlocking...
Login

Join to view Cataloging of Design Patterns 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 Cataloging of Design Patterns 2 2 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?