UML建模技術(shù)第2章_第1頁
UML建模技術(shù)第2章_第2頁
UML建模技術(shù)第2章_第3頁
UML建模技術(shù)第2章_第4頁
UML建模技術(shù)第2章_第5頁
已閱讀5頁,還剩26頁未讀, 繼續(xù)免費閱讀

下載本文檔

版權(quán)說明:本文檔由用戶提供并上傳,收益歸屬內(nèi)容提供方,若內(nèi)容存在侵權(quán),請進行舉報或認領(lǐng)

文檔簡介

1、2021/8/141Chapter 2. Introducing the UMLvOverview of the UMLvThree steps to understanding the UMLvSoftware architecturevThe software development process2021/8/142IntroductionvThe Unified Modeling Language (UML) is a standard language for writing software blueprints. vThe UML is appropriate for model

2、ing systems ranging from enterprise information systems to distributed Web-based applications and even to hard real time embedded systems. 2021/8/143vEven though it is expressive, the UML is not difficult to understand and to use. Learning to apply the UML effectively starts with forming a conceptua

3、l model of the language, which requires learning three major elements: the UMLs basic building blocks, the rules, some common mechanisms.2021/8/144vThe UML is process independent, although optimally it should be used in a process that is use case driven, architecture-centric, iterative, and incremen

4、tal.2021/8/1452.1 An Overview of the UML The UML is a language forvVisualizingvSpecifyingvConstructingvDocumentingthe artifacts of a software-intensive system.2021/8/1462.1.1 The UML Is a LanguagevA language provides a vocabulary and the rules for combining words in that vocabulary for the purpose o

5、f communication. vA modeling language is a language whose vocabulary and rules focus on the conceptual and physical representation of a system. vA modeling language such as the UML is thus a standard language for software blueprints.2021/8/147vModeling yields an understanding of a system. No one mod

6、el is ever sufficient. vThe vocabulary and rules of a language such as the UML tell you how to create and read well-formed models, but they dont tell you what models you should create and when you should create them. Thats the role of the software development process. 2021/8/1482.1.2 The UML Is a La

7、nguage for Visualizing For many programmers, the distance between thinking of an implementation and then pounding it out in code is close to zero. However, there are several problems with this: First, communicating those conceptual models to others is error-prone unless everyone involved speaks the

8、same language. Second, there are some things about a software system you cant understand unless you build models that transcend the textual programming language. Third, if the developer who cut the code never wrote down the models that are in his or her head, that information would be lost forever o

9、r, at best, only partially recreatable from the implementation once that developer moved on. 2021/8/149vWriting models in the UML addresses the third issue: An explicit model facilitates communication. vSome things are best modeled textually; others are best modeled graphically. The UML is such a gr

10、aphical language. vThe UML is more than just a bunch of graphical symbols. Rather, behind each symbol in the UML notation is a well-defined semantics. 2021/8/14102.1.3 The UML Is a Language for SpecifyingvIn this context, specifying means building models that are precise, unambiguous, and complete.v

11、In particular, the UML addresses the specification of all the important analysis, design, and implementation decisions that must be made in developing and deploying a software-intensive system. 2021/8/14112.1.4 The UML Is a Language for Constructing vThe UML is not a visual programming language, but

12、 its models can be directly connected to a variety of programming languages. vThis mapping permits forward engineering the generation of code from a UML model into a programming language. The reverse is also possible: You can reconstruct a model from an implementation back into the UML. 2021/8/14122

13、.1.5 The UML Is a Language for DocumentingA healthy software organization produces all sorts of artifacts in addition to raw executable code. These artifacts include (but are not limited to)vRequirementsvArchitecturevDesignvSource codevProject plansvTestsvPrototypesvReleasesThe UML addresses the doc

14、umentation of a systems architecture and all of its details. 2021/8/14132.1.6 Where Can the UML Be Used? The UML is intended primarily for software-intensive systems. It has been used effectively for such domains asvEnterprise information systemsvBanking and financial servicesvTelecommunicationsvTra

15、nsportationvDefense/aerospacevRetailvMedical electronicsvScientificvDistributed Web-based servicesThe UML is not limited to modeling software.2021/8/14142.2 A Conceptual Model of the UML To understand the UML, you need to form a conceptual model of the language, and this requires learning three majo

16、r elements: vthe UMLs basic building blocks, vthe rules that dictate how those building blocks may be put together, vand some common mechanisms that apply throughout the UML. 2021/8/14152.2.1 Building Blocks of the UMLThe vocabulary of the UML encompasses three kinds of building blocks:vThingsvRelat

17、ionshipsvDiagramsThings are the abstractions that are first-class citizens in a model; relationships tie these things together; diagrams group interesting collections of things.2021/8/14161) Things in the UMLvStructural things: the nouns of UML models vBehavioral things: the dynamic parts of UML mod

18、els vGrouping things: the organizational parts of UML models vAnnotational things: the explanatory parts of UML models 2021/8/14172) Relationships in the UMLv Dependencyv Associationv Generalizationv Realization2021/8/14183) Diagrams in the UML vA diagram is the graphical presentation of a set of el

19、ements, most often rendered as a connected graph of vertices (things) and paths (relationships). vYou draw diagrams to visualize a system from different perspectives, so a diagram is a projection into a system. 2021/8/1419vClass diagramvObject diagramvComponent diagramvComposite structure diagramvUs

20、e case diagramvSequence diagramvCommunication diagramvState diagramvActivity diagramvDeployment diagramvPackage diagramvTiming diagramvInteraction overview diagram2021/8/14202.2.2 Rules of the UML vThe UMLs building blocks cant simply be thrown together in a random fashion. Like any language, the UM

21、L has a number of rules that specify what a well-formed model should look like. vA well-formed model is one that is semantically self-consistent and in harmony with all its related models.2021/8/1421vThe UML has syntactic and semantic rules for Names-What you can call things, relationships, and diag

22、rams Scope-The context that gives specific meaning to a name Visibility-How those names can be seen and used by others Integrity-How things properly and consistently relate to one another Execution-What it means to run or simulate a dynamic modelvThe rules of the UML encourage you but do not force y

23、ou to address the most important analysis, design, and implementation questions that push such models to become well-formed over time. 2021/8/14222.2.3 Common Mechanisms in the UMLvSpecifications vAdornmentsvCommon divisionsclass and object. interface and implementation. type and role. vExtensibilit

24、y mechanismsStereotypesTagged valuesConstraints2021/8/1423Naturally, its important that you do so in controlled ways so that through these extensions, you remain true to the UMLs purpose the communication of information. 2021/8/14242.3 ArchitecturevVisualizing, specifying, constructing, and document

25、ing a software-intensive system demands that the system be viewed from a number of perspectives. vA systems architecture is perhaps the most important artifact that can be used to manage these different viewpoints and thus control the iterative and incremental development of a system throughout its

26、life cycle 2021/8/1425vArchitecture is the set of significant decisions aboutThe organization of a software systemThe selection of the structural elements and their interfaces by which the system is composedTheir behavior, as specified in the collaborations among those elementsThe composition of the

27、se structural and behavioral elements into progressively larger subsystemsThe architectural style that guides this organization: the static and dynamic elements and their interfaces, their collaborations, and their composition2021/8/1426Figure 2-23. Modeling a Systems Architecture 2021/8/14272.4 Software Development Life Cycle vThe UML is largely process-independent, meaning that it is not tied to any particular software development life cycle. vHowever, to get the most benef

溫馨提示

  • 1. 本站所有資源如無特殊說明,都需要本地電腦安裝OFFICE2007和PDF閱讀器。圖紙軟件為CAD,CAXA,PROE,UG,SolidWorks等.壓縮文件請下載最新的WinRAR軟件解壓。
  • 2. 本站的文檔不包含任何第三方提供的附件圖紙等,如果需要附件,請聯(lián)系上傳者。文件的所有權(quán)益歸上傳用戶所有。
  • 3. 本站RAR壓縮包中若帶圖紙,網(wǎng)頁內(nèi)容里面會有圖紙預覽,若沒有圖紙預覽就沒有圖紙。
  • 4. 未經(jīng)權(quán)益所有人同意不得將文件中的內(nèi)容挪作商業(yè)或盈利用途。
  • 5. 人人文庫網(wǎng)僅提供信息存儲空間,僅對用戶上傳內(nèi)容的表現(xiàn)方式做保護處理,對用戶上傳分享的文檔內(nèi)容本身不做任何修改或編輯,并不能對任何下載內(nèi)容負責。
  • 6. 下載文件中如有侵權(quán)或不適當內(nèi)容,請與我們聯(lián)系,我們立即糾正。
  • 7. 本站不保證下載資源的準確性、安全性和完整性, 同時也不承擔用戶因使用這些下載資源對自己和他人造成任何形式的傷害或損失。

評論

0/150

提交評論