




版權說明:本文檔由用戶提供并上傳,收益歸屬內容提供方,若內容存在侵權,請進行舉報或認領
文檔簡介
1、軟件工程實踐者的研究方法課件軟件工程實踐者的研究方法課件 牛牛文庫文檔分享2DesignMitch Kapor, the creator of Lotus 1-2-3, presented a “software design manifesto” in Dr. Dobbs Journal. He said:Good software design should exhibit:Firmness: A program should not have any bugs that inhibit its function. Commodity: A program should be suitab
2、le for the purposes for which it was intended. Delight: The experience of using the program should be pleasurable one. 牛牛文庫文檔分享4DesignM 牛牛文庫文檔分享3Analysis Model - Design Model 牛牛文庫文檔分享5Analysi 牛牛文庫文檔分享4Design and Qualitythe design must implement all of the explicit requirements contained in the analy
3、sis model, and it must accommodate all of the implicit requirements desired by the customer.the design must be a readable, understandable guide for those who generate code and for those who test and subsequently support the software.the design should provide a complete picture of the software, addre
4、ssing the data, functional, and behavioral domains from an implementation perspective. 牛牛文庫文檔分享6Design 牛牛文庫文檔分享5Quality GuidelinesA design should exhibit an architecture that (1) has been created using recognizable architectural styles or patterns, (2) is composed of components that exhibit good des
5、ign characteristics and (3) can be implemented in an evolutionary fashion For smaller systems, design can sometimes be developed linearly.A design should be modular; that is, the software should be logically partitioned into elements or subsystemsA design should contain distinct representations of d
6、ata, architecture, interfaces, and components.A design should lead to data structures that are appropriate for the classes to be implemented and are drawn from recognizable data patterns.A design should lead to components that exhibit independent functional characteristics.A design should lead to in
7、terfaces that reduce the complexity of connections between components and with the external environment.A design should be derived using a repeatable method that is driven by information obtained during software requirements analysis.A design should be represented using a notation that effectively c
8、ommunicates its meaning. 牛牛文庫文檔分享7Quality 牛牛文庫文檔分享6Design PrinciplesThe design process should not suffer from tunnel vision. The design should be traceable to the analysis model. The design should not reinvent the wheel. The design should “minimize the intellectual distance” DAV95 between the softwa
9、re and the problem as it exists in the real world. The design should exhibit uniformity and integration. The design should be structured to accommodate change. The design should be structured to degrade gently, even when aberrant data, events, or operating conditions are encountered. Design is not c
10、oding, coding is not design. The design should be assessed for quality as it is being created, not after the fact. The design should be reviewed to minimize conceptual (semantic) errors.From Davis DAV95 牛牛文庫文檔分享8Design 牛牛文庫文檔分享7Fundamental ConceptsAbstractiondata, procedure, controlArchitecturethe o
11、verall structure of the softwarePatterns”conveys the essence” of a proven design solutionSeparation of concernsany complex problem can be more easily handled if it is subdivided into piecesModularitycompartmentalization of data and functionHidingcontrolled interfacesFunctional independencesingle-min
12、ded function and low couplingRefinementelaboration of detail for all abstractionsAspectsa mechanism for understanding how global requirements affect designRefactoringa reorganization technique that simplifies the designOO design conceptsAppendix IIDesign Classesprovide design detail that will enable
13、 analysis classes to be implemented 牛牛文庫文檔分享9Fundame 牛牛文庫文檔分享8Data Abstractiondoorimplemented as a data structuremanufacturermodel numbertypeswing directioninsertslights type numberweightopening mechanism 牛牛文庫文檔分享10Data A 牛牛文庫文檔分享9Procedural Abstractionopenimplemented with a knowledge of the object
14、that is associated with enterdetails of enter algorithm 牛牛文庫文檔分享11Proced 牛牛文庫文檔分享10Architecture“The overall structure of the software and the ways in which that structure provides conceptual integrity for a system.” SHA95aStructural properties. This aspect of the architectural design representation
15、defines the components of a system (e.g., modules, objects, filters) and the manner in which those components are packaged and interact with one another. For example, objects are packaged to encapsulate both data and the processing that manipulates the data and interact via the invocation of methods
16、 Extra-functional properties. The architectural design description should address how the design architecture achieves requirements for performance, capacity, reliability, security, adaptability, and other system characteristics.Families of related systems. The architectural design should draw upon
17、repeatable patterns that are commonly encountered in the design of families of similar systems. In essence, the design should have the ability to reuse architectural building blocks. 牛牛文庫文檔分享12Archit 牛牛文庫文檔分享11PatternsDesign Pattern TemplatePattern namedescribes the essence of the pattern in a short
18、 but expressive name Intentdescribes the pattern and what it doesAlso-known-aslists any synonyms for the patternMotivationprovides an example of the problem Applicabilitynotes specific design situations in which the pattern is applicableStructuredescribes the classes that are required to implement t
19、he patternParticipantsdescribes the responsibilities of the classes that are required to implement the patternCollaborationsdescribes how the participants collaborate to carry out their responsibilitiesConsequencesdescribes the “design forces” that affect the pattern and the potential trade-offs tha
20、t must be considered when the pattern is implementedRelated patternscross-references related design patterns 牛牛文庫文檔分享13Patter 牛牛文庫文檔分享12Separation of ConcernsAny complex problem can be more easily handled if it is subdivided into pieces that can each be solved and/or optimized independentlyA concern
21、 is a feature or behavior that is specified as part of the requirements model for the softwareBy separating concerns into smaller, and therefore more manageable pieces, a problem takes less effort and time to solve. 牛牛文庫文檔分享14Separa 牛牛文庫文檔分享13Modularitymodularity is the single attribute of software
22、that allows a program to be intellectually manageable Mye78. Monolithic software (i.e., a large program composed of a single module) cannot be easily grasped by a software engineer. The number of control paths, span of reference, number of variables, and overall complexity would make understanding c
23、lose to impossible. In almost all instances, you should break the design into many modules, hoping to make understanding easier and as a consequence, reduce the cost required to build the software. 牛牛文庫文檔分享15Modula 牛牛文庫文檔分享14Modularity: Trade-offsWhat is the right number of modules for a specific so
24、ftware design?optimal number of modules cost of softwarenumber of modulesmoduleintegrationcostmodule development cost 牛牛文庫文檔分享16Modula 牛牛文庫文檔分享15Information Hidingmodulecontrolledinterfacesecret algorithm data structure details of external interface resource allocation policyclientsa specific design
25、 decision 牛牛文庫文檔分享17Inform 牛牛文庫文檔分享16Why Information Hiding?reduces the likelihood of “side effects”limits the global impact of local design decisionsemphasizes communication through controlled interfacesdiscourages the use of global dataleads to encapsulationan attribute of high quality designresul
26、ts in higher quality software 牛牛文庫文檔分享18Why In 牛牛文庫文檔分享17Stepwise Refinementopenwalk to door;reach for knob;open door;walk through;close door.repeat until door opensturn knob clockwise;if knob doesnt turn, then take key out; find correct key; insert in lock;endifpull/push doormove out of way;end rep
27、eat 牛牛文庫文檔分享19Stepwi 牛牛文庫文檔分享18Sizing Modules: Two Views 牛牛文庫文檔分享20Sizing 牛牛文庫文檔分享19Functional IndependenceFunctional independence is achieved by developing modules with single-minded function and an aversion to excessive interaction with other modules.Cohesion is an indication of the relative funct
28、ional strength of a module.A cohesive module performs a single task, requiring little interaction with other components in other parts of a program. Stated simply, a cohesive module should (ideally) do just one thing. Coupling is an indication of the relative interdependence among modules.Coupling d
29、epends on the interface complexity between modules, the point at which entry or reference is made to a module, and what data pass across the interface. 牛牛文庫文檔分享21Functi 牛牛文庫文檔分享20AspectsConsider two requirements, A and B. Requirement A crosscuts requirement B “if a software decomposition refinement
30、has been chosen in which B cannot be satisfied without taking A into account. Ros04An aspect is a representation of a cross-cutting concern. 牛牛文庫文檔分享22Aspect 牛牛文庫文檔分享21AspectsAn ExampleConsider two requirements for the SafeHomeA WebApp. Requirement A is described via the use-case Access camera surve
31、illance via the Internet. A design refinement would focus on those modules that would enable a registered user to access video from cameras placed throughout a space. Requirement B is a generic security requirement that states that a registered user must be validated prior to using SafeHomeA. This r
32、equirement is applicable for all functions that are available to registered SafeHome users. As design refinement occurs, A* is a design representation for requirement A and B* is a design representation for requirement B. Therefore, A* and B* are representations of concerns, and B* cross-cuts A*. An
33、 aspect is a representation of a cross-cutting concern. Therefore, the design representation, B*, of the requirement, a registered user must be validated prior to using SafeHomeA, is an aspect of the SafeHome WebApp. 牛牛文庫文檔分享23Aspect 牛牛文庫文檔分享22RefactoringFowler FOW99 defines refactoring in the follo
34、wing manner: Refactoring is the process of changing a software system in such a way that it does not alter the external behavior of the code design yet improves its internal structure.”When software is refactored, the existing design is examined for redundancyunused design elementsinefficient or unn
35、ecessary algorithmspoorly constructed or inappropriate data structuresor any other design failure that can be corrected to yield a better design. 牛牛文庫文檔分享24Refact 牛牛文庫文檔分享23OO Design ConceptsDesign classesEntity classesBoundary classesController classesInheritanceall responsibilities of a superclass
36、 is immediately inherited by all subclassesMessagesstimulate some behavior to occur in the receiving objectPolymorphisma characteristic that greatly reduces the effort required to extend the design 牛牛文庫文檔分享25OO Des 牛牛文庫文檔分享24Design ClassesAnalysis classes are refined during design to become entity c
37、lassesBoundary classes are developed during design to create the interface (e.g., interactive screen or printed reports) that the user sees and interacts with as the software is used. Boundary classes are designed with the responsibility of managing the way entity objects are represented to users. Controller classes are designed to manage the creation or update of entity objects; the instantiation of boundary objects as they obtain information from entity objects; complex communication between sets of objects; val
溫馨提示
- 1. 本站所有資源如無特殊說明,都需要本地電腦安裝OFFICE2007和PDF閱讀器。圖紙軟件為CAD,CAXA,PROE,UG,SolidWorks等.壓縮文件請下載最新的WinRAR軟件解壓。
- 2. 本站的文檔不包含任何第三方提供的附件圖紙等,如果需要附件,請聯系上傳者。文件的所有權益歸上傳用戶所有。
- 3. 本站RAR壓縮包中若帶圖紙,網頁內容里面會有圖紙預覽,若沒有圖紙預覽就沒有圖紙。
- 4. 未經權益所有人同意不得將文件中的內容挪作商業或盈利用途。
- 5. 人人文庫網僅提供信息存儲空間,僅對用戶上傳內容的表現方式做保護處理,對用戶上傳分享的文檔內容本身不做任何修改或編輯,并不能對任何下載內容負責。
- 6. 下載文件中如有侵權或不適當內容,請與我們聯系,我們立即糾正。
- 7. 本站不保證下載資源的準確性、安全性和完整性, 同時也不承擔用戶因使用這些下載資源對自己和他人造成任何形式的傷害或損失。
最新文檔
- 深圳商場場地租賃合同范本
- 二手住宅交付合同
- 人音版八年級音樂下冊第二單元《A大調(鱒魚)鋼琴五重奏》教學設計
- Brand KPIs for ready-made-food Haldirams in India-外文版培訓課件(2025.2)
- 采納公司執行力-經銷商成敗的關鍵因素
- 合同質量保證協議范本
- 商業空間裝飾分包合同編號091234
- 人教版小學二年級上冊數學 第7單元 第1課時 認識時間(1) 教案
- 2025版貨運物流承包經營合同終止協議范本
- 2025現代家居室內裝修設計合同
- 2025年河南測繪職業學院高職單招職業技能測試近5年常考版參考題庫含答案解析
- 2025-2030年中國抗哮喘市場現狀調研及投資發展潛力分析報告
- 2024年河南藝術職業學院高職單招職業適應性測試歷年參考題庫含答案解析
- 貝殼好贊服務協議書
- 大數據與人工智能營銷知到智慧樹章節測試課后答案2024年秋南昌大學
- 2024中國互聯網養車市場發展報告
- UL2267標準中文版-2020工業電動卡車安裝的燃料電池動力系統UL中文版標準
- 【MOOC】化工安全(下)-華東理工大學 中國大學慕課MOOC答案
- 【MOOC】大學生創新與創業實踐-西南交通大學 中國大學慕課MOOC答案
- 【MOOC】電動力學-同濟大學 中國大學慕課MOOC答案
- 《數控車削編程與加工》項目6 酒杯的數控加工工藝文件
評論
0/150
提交評論