Table Of Contentffirs.fm Page ii Wednesday, March 21, 2007 11:14 AM
ffirs.fm Page i Wednesday, March 21, 2007 11:14 AM
P A T T E R N - O R I E N T E D
S O F T W A R E
A R C H I T E C T U R E
ffirs.fm Page ii Wednesday, March 21, 2007 11:14 AM
ffirs.fm Page iii Wednesday, March 21, 2007 11:14 AM
PATTERN-ORIENTED
SOFTWARE
ARCHITECTURE
On Patterns and Pattern Languages
Volume 5
Frank Buschmann,
Siemens, Munich, Germany
Kevlin Henney,
Curbralan, Bristol, UK
Douglas C. Schmidt,
Vanderbilt University, Tennessee, USA
ffirs.fm Page iv Wednesday, March 21, 2007 11:14 AM
Copyright © 2007 John Wiley & Sons Ltd, The Atrium, Southern Gate, Chichester,
West Sussex PO19 8SQ, England
Telephone (+44) 1243 779777
Email (for orders and customer service enquiries): cs-books@wiley.co.uk
Visit our Home Page on www.wiley.com
All Rights Reserved. No part of this publication may be reproduced, stored in a retrieval system or transmitted in
any form or by any means, electronic, mechanical, photocopying, recording, scanning or otherwise, except under
the terms of the Copyright, Designs and Patents Act 1988 or under the terms of a licence issued by the Copyright
Licensing Agency Ltd, 90 Tottenham Court Road, London W1T 4LP, UK, without the permission in writing of the
Publisher. Requests to the Publisher should be addressed to the Permissions Department, John Wiley & Sons Ltd,
The Atrium, Southern Gate, Chichester, West Sussex PO19 8SQ, England, or emailed to permreq@wiley.co.uk, or
faxed to (+44) 1243 770620.
Designations used by companies to distinguish their products are often claimed as trademarks. All brand names
and product names used in this book are trade names, service marks, trademarks or registered trademarks of
their respective owners. The Publisher is not associated with any product or vendor mentioned in this book.
This publication is designed to provide accurate and authoritative information in regard to the subject matter
covered. It is sold on the understanding that the Publisher is not engaged in rendering professional services. If
professional advice or other expert assistance is required, the services of a competent professional should be sought.
Other Wiley Editorial Offices
John Wiley & Sons Inc., 111 River Street, Hoboken, NJ 07030, USA
Jossey-Bass, 989 Market Street, San Francisco, CA 94103-1741, USA
Wiley-VCH Verlag GmbH, Boschstr. 12, D-69469 Weinheim, Germany
John Wiley & Sons Australia Ltd, 42 McDougall Street, Milton, Queensland 4064, Australia
John Wiley & Sons (Asia) Pte Ltd, 2 Clementi Loop #02-01, Jin Xing Distripark, Singapore 129809
John Wiley & Sons Canada Ltd, 22 Worcester Road, Etobicoke, Ontario, Canada M9W 1L1
Wiley also publishes its books in a variety of electronic formats. Some content that appears in print may not be
available in electronic books.
British Library Cataloguing in Publication Data
A catalogue record for this book is available from the British Library
ISBN-13: 978-0-471-48648-0
Typeset in 10/13 Bookman-Light by Laserwords Private Limited, Chennai, India
Printed and bound in Great Britain by Antony Rowe Ltd, Chippenham, Wiltshire
This book is printed on acid-free paper responsibly manufactured from sustainable forestry
in which at least two trees are planted for each one used for paper production.
ffirs.fm Page v Wednesday, March 21, 2007 11:14 AM
†
For Anna, Bebé , and Martina
Frank Buschmann
For Carolyn, Stefan, and Yannick
Kevlin Henney
For Lori, Bronson, Mom, and Dad
Douglas C. Schmidt
For John
Frank Buschmann, Kevlin Henney, Douglas C. Schmidt
† Bebé, July 3, 1999
ffirs.fm Page vi Wednesday, March 21, 2007 11:14 AM
ftoc.fm Page vii Wednesday, March 21, 2007 11:12 AM
Table of Contents
Foreword by Richard P. Gabriel . . . . . . . xiii
Foreword by Wayne Cool . . . . . . . . . . . . . xxiii
About the Authors . . . . . . . . . . . . . . . . . . . xxix
About this Book . . . . . . . . . . . . . . . . . . . . . xxxi
Guide to the Reader . . . . . . . . . . . . . . . . . . xxxvii
0 Beyond the Hype . . . . . . . . . . . . . . . . . . . . . . . 1
0.1 Beginnings… . . . . . . . . . . . . . . . . . . . . . . . . . . . 2
0.2 A Story of Success… with Some Exceptions . . . . 3
0.3 Pattern Definitions and their Interpretations . . . 8
0.4 Toward a Deeper Understanding of Patterns . . . . 19
Part I Inside Patterns . . . . . . . . . . . . . . . . . . . . . . . . 25
1 A Solution to a Problem and More . . . . . . . . . . 29
1.1 A Solution to a Problem . . . . . . . . . . . . . . . . . . . 30
1.2 A Process and a Thing . . . . . . . . . . . . . . . . . . . . 32
1.3 Best of Breed . . . . . . . . . . . . . . . . . . . . . . . . . . . 34
1.4 Forces: the Heart of Every Pattern . . . . . . . . . . . 36
1.5 The Context: Part of a Pattern or Not? . . . . . . . . 42
1.6 Genericity . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 47
ftoc.fm Page viii Wednesday, March 21, 2007 11:12 AM
viii Contents
1.7 A Diagram Says More than a Thousand Words…
or Less . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 50
1.8 Evocative Names Help Pattern Recollection . . . . 54
1.9 Patterns are Works in Progress . . . . . . . . . . . . . 57
1.10 A Pattern Tells a Story and Initiates a Dialog . . . 61
1.11 A Pattern Celebrates Human Intelligence . . . . . . 62
1.12 From a Problem–Solution Statement to a
Pattern . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 63
2 A Million Different Implementations . . . . . . . 65
2.1 Does One Size Fit All? . . . . . . . . . . . . . . . . . . . . 66
2.2 Patterns and Frameworks . . . . . . . . . . . . . . . . . 77
2.3 Patterns and Formalisms . . . . . . . . . . . . . . . . . 84
2.4 A Million and One… and then Some . . . . . . . . . 87
3 Notes on Pattern Form . . . . . . . . . . . . . . . . . . 91
3.1 Style and Substance . . . . . . . . . . . . . . . . . . . . . 92
3.2 The Function of Form . . . . . . . . . . . . . . . . . . . . 96
3.3 Elements of Form . . . . . . . . . . . . . . . . . . . . . . . 97
3.4 Details, Details . . . . . . . . . . . . . . . . . . . . . . . . . 102
3.5 Aerial View . . . . . . . . . . . . . . . . . . . . . . . . . . . . 106
3.6 Different Pattern Forms . . . . . . . . . . . . . . . . . . . 110
3.7 Style and Substance (Redux) . . . . . . . . . . . . . . . 116
Part II Between Patterns . . . . . . . . . . . . . . . . . . . . . . 117
4 Pattern Islands? . . . . . . . . . . . . . . . . . . . . . . . 121
4.1 Patterns Connect . . . . . . . . . . . . . . . . . . . . . . . 122
4.2 A Design Experiment: Patterns as Islands . . . . . 123
4.3 A Second Design Experiment: Interwoven
Patterns . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 129
4.4 Pattern Density . . . . . . . . . . . . . . . . . . . . . . . . . 131