1、BRITISH STANDARD BS ISO/IEC 19501:2005 Information technology Open Distributed Processing Unified Modeling Language (UML) Version 1.4.2 ICS 35.080 BS ISO/IEC 19501:2005 This British Standard was published under the authority of the Standards Policy and Strategy Committee on 30 September 2005 BSI 30
2、September 2005 ISBN 0 580 46046 0 National foreword This British Standard reproduces verbatim ISO/IEC 19501:2005 and implements it as the UK national standard. The UK participation in its preparation was entrusted to Technical Committee IST/15, Software engineering, which has the responsibility to:
3、A list of organizations represented on this committee can be obtained on request to its secretary. Cross-references The British Standards which implement international publications referred to in this document may be found in the BSI Catalogue under the section entitled “International Standards Corr
4、espondence Index”, or by using the “Search” facility of the BSI Electronic Catalogue or of British Standards Online. This publication does not purport to include all the necessary provisions of a contract. Users are responsible for its correct application. Compliance with a British Standard does not
5、 of itself confer immunity from legal obligations. aid enquirers to understand the text; present to the responsible international/European committee any enquiries on the interpretation, or proposals for change, and keep UK interests informed; monitor related international and European developments a
6、nd promulgate them in the UK. Summary of pages This document comprises a front cover, an inside front cover, the ISO/IEC title page, pages ii to xxi, a blank page, pages 1 to 432, an inside back cover and a back cover. The BSI copyright notice displayed in this document indicates when the document w
7、as last issued. Amendments issued since publication Amd. No. Date CommentsReference number ISO/IEC 19501:2005(E) INTERNATIONAL STANDARD ISO/IEC 19501 First edition 2005-04-01 Information technology Open Distributed Processing Unified Modeling Language (UML) Version 1.4.2 Technologies de linformation
8、 Traitement distribu ouvert Langage de modlisation unifi (UML), version 1.4.2 ii iii 1 Scope. 1 2 Normative references .1 2.1 Identical Recommendations | International Standards 1 3 General Information .2 3.1 Description 2 3.2 Outside the Scope of the UML 33.2.1 Programming Languages. 33.2.2 Tools 3
9、3.2.3 Process . 3 3.3 Primary Artifacts of the UML . 43.3.1 UML-defining Artifacts . 43.3.2 Development Project Artifacts . 4 3.4 Motivation to Define the UML 53.4.1 Why We Model 53.4.2 Industry Trends in Software 53.4.3 Prior to Industry Convergence 6 3.5 Goals of the UML 63.5.1 Comparing UML to Ot
10、her Modeling Languages 83.5.2 Features of the UML . 8 3.6 UML - Past, Present, and Future . 103.6.1 UML 0.8 - 0.91 103.6.2 UML Partners. 113.6.3 UML - Present and Future . 11 4 UML Semantics 13 Part 1 - Background 4.1 Introduction . 134.1.1 Purpose and Scope 134.1.2 Approach . 13 4.2 Language Archit
11、ecture 144.2.1 Four-Layer Metamodel Architecture 144.2.2 Package Structure 15 4.3 Language Formalism 174.3.1 Levels of Formalism. 174.3.2 Package Specification Structure . 184.3.3 Use of a Constraint Language 194.3.4 Use of Natural Language 194.3.5 Naming Conventions and Typography 20 Part 2 - Found
12、ation 4.4 Foundation Package . 20 4.5 Core 214.5.1 Overview 214.5.2 Abstract Syntax . 214.5.3 Well-Formedness Rules 514.5.4 Detailed Semantics . 63 BS ISO/IEC 19501:2005iv 4.6 Extension Mechanisms . 694.6.1 Overview . 694.6.2 Abstract Syntax . 714.6.3 Well-Formedness Rules 744.6.4 Detailed Semantics
13、 . 764.6.5 Notes . 77 4.7 Data Types 784.7.1 Overview . 784.7.2 Abstract Syntax . 78 Part 3 - Behavioral Elements 4.8 Behavioral Elements Package . 85 4.9 Common Behavior 854.9.1 Overview . 854.9.2 Abstract Syntax . 854.9.3 Well-Formedness Rules. 964.9.4 Detailed Semantics . 101 4.10 Collaborations
14、. 1034.10.1 Overview . 1034.10.2 Abstract Syntax . 1044.10.3 Well-Formedness Rules 1114.10.4 Detailed Semantics . 1154.10.5 Notes . 118 4.11 Use Cases . 1194.11.1 Overview . 1194.11.2 Abstract Syntax . 1194.11.3 Well-Formedness Rules 1224.11.4 Detailed Semantics 1244.11.5 Notes . 128 4.12 State Mach
15、ines 1284.12.1 Overview . 1284.12.2 Abstract Syntax . 1284.12.3 Well-FormednessRules . 1364.12.4 Detailed Semantics . 1404.12.5 Notes . 148 4.13 Activity Graphs 1524.13.1 Overview . 1524.13.2 Abstract Syntax . 1524.13.3 Well-Formedness Rules 1564.13.4 Detailed Semantics . 1594.13.5 Notes . 160 Part
16、4 - General Mechanisms 4.14 Model Management . 1614.14.1 Overview . 1614.14.2 Abstract Syntax . 1614.14.3 Well-Formedness Rules 1654.14.4 Semantics . 1704.14.5 Notes . 174 BS ISO/IEC 19501:2005 v 5 UML Notation Guide 177 Part 1 - Background 5.1 Introduction . 177 Part 2 - Diagram Elements 5.2 Graphs
17、 and Their Contents . 178 5.3 Drawing Paths . 178 5.4 Invisible Hyperlinks and the Role of Tools 179 5.5 Background Information 1795.5.1 Presentation Options . 179 5.6 String . 1795.6.1 Semantics . 1795.6.2 Notation . 1795.6.3 Presentation Options . 1805.6.4 Examples 1805.6.5 Mapping 180 5.7 Name .
18、1805.7.1 Semantics . 1805.7.2 Notation . 1805.7.3 Example 1805.7.4 Mapping 181 5.8 Label . 1815.8.1 Semantics . 1815.8.2 Notation . 1815.8.3 Presentation Options. 1815.8.4 Example . 181 5.9 Keywords 181 5.10 Expression 1825.10.1 Semantics . 1825.10.2 Notation . 1825.10.3 Examples 1825.10.4 Mapping 1
19、825.10.5 OCL Expressions 1825.10.6 Selected OCL Notation . 1835.10.7 Examples 183 5.11 Note . 1835.11.1 Semantics . 1835.11.2 Notation . 1835.11.3 Presentation Options . 1835.11.4 Example 1845.11.5 Mapping 184 5.12 Type-Instance Correspondence 184 Part 3 - Model Management 5.13 Package 1865.13.1 Sem
20、antics . 1865.13.2 Notation . 186 BS ISO/IEC 19501:2005vi5.13.3 Presentation Options. 1865.13.4 Style Guidelines 1875.13.5 Example . 1875.13.6 Mapping 188 5.14 Subsystem . 1885.14.1 Semantics 1885.14.2 Notation . 1885.14.3 Presentation Options . 1895.14.4 Example 1905.14.5 Mapping 193 5.15 Model . 1
21、935.15.1 Semantics . 1935.15.2 Notation . 1935.15.3 Presentation Options . 1935.15.4 Example 1945.15.5 Mapping 194 Part 4 - General Extension Mechanisms 5.16 Constraint and Comment 1955.16.1 Semantics . 1955.16.2 Notation . 1955.16.3 Example 1965.16.4 Mapping 196 5.17 Element Properties 1975.17.1 Se
22、mantics . 1975.17.2 Notation . 1975.17.3 Presentation Options . 1985.17.4 Style Guidelines . 1985.17.5 Example 1985.17.6 Mapping 198 5.18 Stereotypes . 1995.18.1 Semantics . 1995.18.2 Notation . 1995.18.3 Examples . 2005.18.4 Mapping 200 Part 5 - Static Structure Diagrams 5.19 Class Diagram . 2015.1
23、9.1 Semantics . 2015.19.2 Notation. 2015.19.3 Mapping 201 5.20 Object Diagram . 201 5.21 Classifier 201 5.22 Class . 2025.22.1 Semantics . 2025.22.2 Basic Notation 2025.22.3 Presentation Options . 2025.22.4 Style Guidelines 2035.22.5 Example 203 BS ISO/IEC 19501:2005 vii5.22.6 Mapping 203 5.23 Name
24、Compartment 2045.23.1 Notation . 2045.23.2 Mapping 204 5.24 List Compartment 2045.24.1 Notation . 2045.24.2 Presentation Options. 2055.24.3 Example 2065.24.4 Mapping 206 5.25 Attribute . 2075.25.1 Semantics . 2075.25.2 Notation . 2075.25.3 Presentation Options . 2085.25.4 Style Guidelines 2095.25.5
25、Example 2095.25.6 Mapping 209 5.26 Operation 2095.26.1 Semantics . 2095.26.2 Notation . 2095.26.3 Presentation Options . 2105.26.4 Style Guidelines 2115.26.5 Example 2115.26.6 Mapping 211 5.27 Nested Class Declarations 2125.27.1 Semantics 2125.27.2 Notation . 2125.27.3 Mapping 212 5.28 Type and Impl
26、ementation Class 2125.28.1 Semantics . 2125.28.2 Notation . 2135.28.3 Example 2135.28.4 Mapping 213 5.29 Interfaces 2145.29.1 Semantics . 2145.29.2 Notation . 2145.29.3 Example 2145.29.4 Mapping 215 5.30 Parameterized Class (Template. 2155.30.1 Semantics . 2155.30.2 Notation . 2155.30.3 Presentation
27、 Options 2165.30.4 Example 2165.30.5 Mapping 216 5.31 Bound Element 2175.31.1 Semantics . 2175.31.2 Notation . 2175.31.3 Style Guidelines 2175.31.4 Example 2175.31.5 Mapping 217 5.32 Utility . 218 BS ISO/IEC 19501:2005viii5.32.1 Semantics 2185.32.2 Notation . 2185.32.3 Example 2185.32.4 Mapping 218
28、5.33 Metaclass 2185.33.1 Semantics . 2185.33.2 Notation. 2185.33.3 Mapping 219 5.34 Enumeration 2195.34.1 Semantics 2195.34.2 Notation . 2195.34.3 Mapping 219 5.35 Stereotype Declaration 2195.35.1 Semantics 2195.35.2 Notation . 2195.35.3 Mapping . 222 5.36 Powertype . 2225.36.1 Semantics . 2225.36.2
29、 Notation. 2225.36.3 Mapping 222 5.37 Class Pathnames 2235.37.1 Notation 2235.37.2 Example 2235.37.3 Mapping . 223 5.38 Accessing or Importing a Package. 2235.38.1 Semantics . 2235.38.2 Notation. 2245.38.3 Example 2245.38.4 Mapping 224 5.39 Object 2255.39.1 Semantics 2255.39.2 Notation . 2255.39.3 P
30、resentation Options. 2255.39.4 Style Guidelines 2265.39.5 Variations 2265.39.6 Example 2265.39.7 Mapping 226 5.40 Composite Object 2265.40.1 Semantics . 2265.40.2 Notation. 2275.40.3 Example 2275.40.4 Mapping 227 5.41 Association 227 5.42 Binary Association 2285.42.1 Semantics . 2285.42.2 Notation 2
31、285.42.3 Presentation Options. 2295.42.4 Style Guidelines 2295.42.5 Options 2295.42.6 Example 229 BS ISO/IEC 19501:2005 ix5.42.7 Mapping . 230 5.43 Association End 2305.43.1 Semantics . 2305.43.2 Notation 2305.43.3 Presentation Options. 2325.43.4 Style Guidelines 2325.43.5 Example 2325.43.6 Mapping
32、233 5.44 Multiplicity 2335.44.1 Semantics . 2335.44.2 Notation. 2335.44.3 Style Guidelines 2335.44.4 Example 2335.44.5 Mapping 234 5.45 Qualifier 2345.45.1 Semantics . 2345.45.2 Notation . 2345.45.3 Presentation Options. 2345.45.4 Style Guidelines 2345.45.5 Example 2355.45.6 Mapping 235 5.46 Associa
33、tion Class 2355.46.1 Semantics . 2355.46.2 Notation . 2355.46.3 Presentation Options 2355.46.4 Style Guidelines 2355.46.5 Example 2365.46.6 Mapping 236 5.47 N-ary Association 2365.47.1 Semantics 2365.47.2 Notation . 2365.47.3 Style Guidelines 2375.47.4 Example 2375.47.5 Mapping 237 5.48 Composition
34、2375.48.1 Semantics . 2375.48.2 Notation 2385.48.3 Design Guidelines . 2385.48.4 Example 2395.48.5 Mapping 240 5.49 Link 2405.49.1 Semantics . 2405.49.2 Notation . 2405.49.3 Example 2415.49.4 Mapping 241 5.50 Generalization . 2415.50.1 Semantics . 2415.50.2 Notation . 2415.50.3 Presentation Options
35、. 2425.50.4 Mapping 244 BS ISO/IEC 19501:2005x 5.51 Dependency 2455.51.1 Semantics . 2455.51.2 Notation 2455.51.3 Presentation Options. 2465.51.4 Example 2465.51.5 Mapping 247 5.52 Derived Element 2475.52.1 Semantics . 2475.52.2 Notation . 2475.52.3 Style Guidelines 247 5.53 InstanceOf . 2475.53.1 S
36、emantics . 2475.53.2 Notation. 2485.53.3 Mapping 248 Part 6 - Use Case Diagrams 5.54 Use Case Diagram 2485.54.1 Semantics . 2485.54.2 Notation. 2485.54.3 Example 2495.54.4 Mapping . 249 5.55 Use Case . 2495.55.1 Semantics . 2495.55.2 Notation . 2505.55.3 Presentation Options. 2505.55.4 Style Guideli
37、nes 2505.55.5 Mapping 250 5.56 Actor 2505.56.1 Semantics . 2505.56.2 Notation . 2505.56.3 Presentation Options. 2505.56.4 Style Guidelines 2515.56.5 Mapping 251 5.57 Use Case Relationships 2515.57.1 Semantics . 2515.57.2 Notation. 2515.57.3 Example 2525.57.4 Mapping 252 5.58 Actor Relationships . 25
38、25.58.1 Semantics . 2525.58.2 Notation . 2525.58.3 Example 2535.58.4 Mapping 253 Part 7 - Interaction Diagrams 5.59 Collaboration . 2535.59.1 Semantics . 253 5.60 Sequence Diagram 2545.60.1 Semantics . 254 BS ISO/IEC 19501:2005 xi5.60.2 Notation . 2545.60.3 Presentation Options . 2555.60.4 Example 2
39、565.60.5 Mapping 258 5.61 Object Lifeline . 2605.61.1 Semantics . 2605.61.2 Notation . 2605.61.3 Presentation Options . 2605.61.4 Example 2615.61.5 Mapping 261 5.62 Activation. 2615.62.1 Semantics . 2615.62.2 Notation . 2615.62.3 Example 2625.62.4 Mapping 262 5.63 Message and Stimulus 2625.63.1 Sema
40、ntics . 2625.63.2 Notation . 2625.63.3 Presentation options . 2625.63.4 Example 2645.63.5 Mapping . 264 5.64 Transition Times 2645.64.1 Semantics . 2645.64.2 Notation . 2645.64.3 Presentation Options. 2645.64.4 Example 2645.64.5 Mapping . 264 Part 8 - Collaboration Diagrams 5.65 Collaboration Diagra
41、m 2645.65.1 Semantics . 2645.65.2 Notation . 2655.65.3 Example 2665.65.4 Mapping 267 5.66 Pattern Structure . 2675.66.1 Semantics 2675.66.2 Notation . 2685.66.3 Mapping 270 5.67 Collaboration Contents 2705.67.1 Semantics . 2715.67.2 Notation 2715.67.3 Mapping 272 5.68 Interactions. 2725.68.1 Semanti
42、cs . 2725.68.2 Notation . 2735.68.3 Mapping 2735.68.4 Example 273 5.69 Collaboration Roles . 2735.69.1 Semantics . 2735.69.2 Notation . 273 BS ISO/IEC 19501:2005xii5.69.3 Presentation options . 2745.69.4 Example 2755.69.5 Mapping 275 5.70 Multiobject . 2755.70.1 Semantics . 2755.70.2 Notation . 2755
43、.70.3 Example 2765.70.4 Mapping 276 5.71 Active object 2765.71.1 Semantics . 2765.71.2 Notation . 2765.71.3 Example 2775.71.4 Mapping 277 5.72 Message and Stimulus 2775.72.1 Semantics . 2775.72.2 Notation . 2785.72.3 Presentation Options . 2805.72.4 Example 2805.72.5 Mapping 280 5.73 Creation/Destru
44、ction Markers 2815.73.1 Semantics . 2815.73.2 Notation . 2815.73.3 Presentation options . 2815.73.4 Example 2815.73.5 Mapping 282 Part 9 - Statechart Diagrams 5.74 Statechart Diagram . 2825.74.1 Semantics . 2825.74.2 Notation. 2825.74.3 Mapping 283 5.75 State 2835.75.1 Semantics . 2835.75.2 Notation
45、. 2835.75.3 Mapping 285 5.76 Composite States 2855.76.1 Semantics . 2855.76.2 Notation. 2855.76.3 Examples 2865.76.4 Mapping 287 5.77 Events 2875.77.1 Semantics . 2875.77.2 Notation . 2885.77.3 Example 2895.77.4 Mapping 289 5.78 Simple Transitions . 2895.78.1 Semantics . 2895.78.2 Notation 2905.78.3
46、 Example 2905.78.4 Mapping 290 BS ISO/IEC 19501:2005 xiii 5.79 Transitions to and from Concurrent States 2915.79.1 Semantics . 2915.79.2 Notation . 2915.79.3 Example 2915.79.4 Mapping 291 5.80 Transitions to and from Composite States 2915.80.1 Semantics . 2915.80.2 Notation . 2925.80.3 Presentation
47、Options . 2925.80.4 Example 2925.80.5 Mapping 293 5.81 Factored Transition Paths . 2945.81.1 Semantics . 2945.81.2 Notation . 2945.81.3 Examples 294 5.82 Submachine States . 2955.82.1 Semantics . 2955.82.2 Notation . 2965.82.3 Example 2965.82.4 Mapping 297 5.83 Synch States . 2975.83.1 Semantics . 2
48、975.83.2 Notation. 2975.83.3 Example 2975.83.4 Mapping 297 Part 10 - Activity Diagrams 5.84 Activity Diagram 2985.84.1 Semantics . 2985.84.2 Notation . 2985.84.3 Example 2995.84.4 Mapping 300 5.85 Action State . 3005.85.1 Semantics . 3005.85.2 Notation . 3005.85.3 Presentation options . 3005.85.4 Example 3005.85.5 Mapping 300 5.86 Subactivity state 3005.86.1 Semantics . 3005.86.2 Notation. 3015.86.3 Example 3015.86.4 Mapping 301 5.87 Decisions 3015.87.1 Semantics . 3015.87.2 Notation . 3015.87.3 Example 3025.87.4 Mapping 302 5.88 Call States 302 BS ISO/IEC 19501:2005