Математика | ||||
Instant UML-© 1997 by Editions, Eyrolles, Paris, France | ||||
Instant UML
© 1997 by Editions, Eyrolles, Paris, France All rights reserved. No part of this book may be reproduced, stored in a retrieval system or transmitted in any form or by any means, without the prior written permission of the publisher, except in the case of brief quotations embodied in critical articles or reviews. The author and publisher have made every effort in the preparation of this book to ensure the accuracy of the information. However, the information contained in this book is sold without warranty either express or implied. Neither the author, Wrox Press nor its dealers or distributors will be held liable for any damages caused or alleged to be caused either directly or indirectly by this book. Table of Contents Introduction.................................................................................1 Who this Book is for...................................................................................1 What You Need to Use This Book................................................................3 Tell Us What You Think...............................................................................3 Chapter 1: The Genesis of UML.....................................................5 Analysis and Design Methods.....................................................................5 What is the Purpose of a Method?................................................................................5 From Functional to Object-Oriented Methods..................................................................6 The Proliferation of Object-Oriented Methods.................................................................8 Booch and OMT Getting Closer.....................................................................................8 Unification of Methods...............................................................................9 Towards a Unified Modeling Language...........................................................................9 Model and Metamodel................................................................................................11 Chapter 2: The Object-Oriented Approach.....................................15 Why the Object-Oriented Approach?...........................................................15 Objects...................................................................................................17 Fundamental Characteristics of an Object....................................................................19 State..................................................................................................................................19 Behavior.............................................................................................................................20 Identity................................................................................................................................21 Implementation Constraints........................................................................................21 Object Persistence...............................................................................................................21 Broadcasting Objects...........................................................................................................21 Proxy Objects ......................................................................................................................22 Object Intercommunication .........................................................................................22 Categories of Behavior.........................................................................................................22 The Concept of Messages...................................................................................................24 Message Categories............................................................................................................24 Message Synchronization Types .....................................................................................25 Simple Message Broadcast............................................................................................26 Synchronous Message Broadcast...................................................................................26 Rendez-vous Message Broadcast....................................................................................26 Timed Message Broadcast.............................................................................................27 Asynchronous Message Broadcast..................................................................................27 Representation of Interactions between Objects ..........................................................28 Collaboration Diagrams........................................................................................................28 Sequence Diagrams ............................................................................................................29 Classes...................................................................................................30 The Process of Abstraction.........................................................................................30 Graphical Representation of Classes...........................................................................31 Description of Classes...............................................................................................33 Relationships Between Classes................................................................36 Association................................................................................................................36 Aggregation ...............................................................................................................38 Parallels between Class and Object Diagrams..............................................................39 Class Hierarchies.....................................................................................40 Generalization and Specialization................................................................................40 From Sets to Classes.................................................................................................43 The Difficulty of Classification.....................................................................................47 Inheritance................................................................................................................50 General Principle.................................................................................................................51 Delegation ..........................................................................................................................53 The Substitution Principle....................................................................................................54 Polymorphism............................................................................................................55 General Principle.................................................................................................................55 Application..........................................................................................................................56 Taking Advantage of the Substitution Principle ......................................................................59 Triggering Operations...........................................................................................................60 The Influence of Typing........................................................................................................62 Summary................................................................................................63 Chapter 3: The UML Notation......................................................65 UML Diagrams.........................................................................................66 Basic Concepts........................................................................................67 Common Elements.....................................................................................................67 Common Mechanisms................................................................................................67 tiii Stereotypes ........................................................................................................................68 Tagged Values.....................................................................................................................69 Notes..................................................................................................................................69 Constraints.........................................................................................................................69 Dependencies.....................................................................................................................69 Type/Instance and Type/Class Dichotomies.........................................................................69 Data Types................................................................................................................69 Packages...................................................................................................................70 Class Diagrams.......................................................................................73 Classes.....................................................................................................................73 Attributes and Operations....................................................................................................74 Visibility of Attributes and Operations...................................................................................75 Interfaces...........................................................................................................................76 Template Classes................................................................................................................76 Utility Classes.....................................................................................................................77 Associations..............................................................................................................77 Association Naming.............................................................................................................77 Role Naming........................................................................................................................78 Multiplicity of Associations...................................................................................................79 Constraints on Associations.................................................................................................80 Association classes.............................................................................................................81 N-ary Associations...............................................................................................................81 Location of Attributes According to Multiplicity Values.............................................................82 Association Qualifiers..........................................................................................................83 Aggregations..............................................................................................................84 Composition........................................................................................................................84 Navigation.................................................................................................................85 Navigation Expressions........................................................................................................85 Generalization............................................................................................................87 Abstract Classes........................................................................................................90 Introduction to the Metamodel....................................................................................90 Relationships......................................................................................................................92 Association....................................................................................................................92 Generalization................................................................................................................93 Dependency...................................................................................................................94 Use Case Diagrams.................................................................................95 The Use Case Model..................................................................................................95 Relationships Between Use Cases..............................................................................97 The Communicates Relationship..........................................................................................97 The Uses Relationship.........................................................................................................98 The Extends Relationship.....................................................................................................98 Object Diagrams......................................................................................98 Representation of Objects..........................................................................................99 Representation of Links..............................................................................................99 Composite Objects...................................................................................................100 Similarities with Class Diagrams...............................................................................101 Collaboration Diagrams..........................................................................102 Representation of Interactions..................................................................................102 The Place of the User.........................................................................................................103 Active Objects....................................................................................................................104 Representation of Messages.............................................................................................104 Synchronization............................................................................................................104 Sequence....................................................................................................................105 Result..........................................................................................................................106 Name ..........................................................................................................................106 Arguments...................................................................................................................106 Collaborations..........................................................................................................107 Interactions.......................................................................................................................107 Sequence Diagrams...............................................................................108 Representation of Interactions..................................................................................108 Control Structures....................................................................................................112 Statechart Diagrams..............................................................................114 State Machines........................................................................................................115 States.....................................................................................................................116 Transitions...............................................................................................................117 Events ..............................................................................................................................118 Guards....................................................................................................................119 Operations, Actions, and Activities............................................................................119 Execution Points of Operations.................................................................................121 Generalization of States...........................................................................................122 Aggregation of States...............................................................................................123 History....................................................................................................................124 Object Intercommunication .......................................................................................125 Object Creation and Destruction................................................................................126 Timed Transitions.....................................................................................................127 Metamodel Introduction.....................................................................................................128 Activity Diagrams...................................................................................129 Representation of Activities......................................................................................129 Component Diagrams.............................................................................133 Components............................................................................................................133 Dependencies Between Components........................................................................133 Subsystems......................................................................................................................134 Processes.........................................................................................................................134 Integration with Development Environments...............................................................135 Deployment Diagrams............................................................................136 Representation of Nodes..........................................................................................136 Summary..............................................................................................138 Chapter 4: Object-Oriented Project Support...............................141 Software Characterization.......................................................................141 The Software Crisis..................................................................................................141 Software Categories.................................................................................................142 Software Complexity.................................................................................................142 Origins of Software Complexity...........................................................................................143 Consequences of Complexity.............................................................................................144 The Scope of the Object-Oriented Approach...............................................................144 Object-Oriented Analysis.....................................................................................................145 Object-Oriented Design ......................................................................................................147 Object-Oriented Programming.............................................................................................149 The Transition to Object-Oriented Technology..............................................................151 Towards a Development Method.............................................................152 Use Cases...............................................................................................................153 Benefits of Use Cases.......................................................................................................154 Construction of Use Cases................................................................................................155 Rules for Setting up Use Cases..........................................................................................155 Elaboration Process for Use Cases.....................................................................................156 Last Pitfalls to Avoid..........................................................................................................158 The Transition to Object-Oriented Technology.......................................................................158 Software Architecture...............................................................................................160 The Architect's Vision ........................................................................................................161 The Logical View...........................................................................................................162 The Implementation View..............................................................................................162 The Process View.........................................................................................................162 The Deployment View...................................................................................................162 The Use Case View.......................................................................................................163 Organization of Models......................................................................................................163 Documentation of Architecture......................................................................................164 Articulation of the Different Diagrams.................................................................................164 Expression of Requirements.........................................................................................165 Transition to Object-Orientation.....................................................................................165 Expressing Behavior.....................................................................................................165 Representing the Structure...........................................................................................166 Implementing Objects and Classes...............................................................................166 Deployment of executable code..........................................................................................167 Organization of Models and Views.................................................................................168 Granularity of Model Elements............................................................................................168 Summary of Elements and Views .......................................................................................170 Patterns............................................................................................................................171 Description of Patterns.................................................................................................172 Idioms.........................................................................................................................172 Frameworks.......................................................................................................................172 The Role of Software, or the Cultural Clash.........................................................................174 Iterative and Incremental Lifecycle ............................................................................176 Linear Lifecycle..................................................................................................................176 vi Цена: 150руб. |
||||