資源描述:
《chap 4 - system design》由會(huì)員上傳分享,免費(fèi)在線閱讀,更多相關(guān)內(nèi)容在教育資源-天天文庫(kù)。
1、2010/1/8ShanghaiJiaoTongUniversityObjtObject-OitdAliOrientedAnalysisandDidDesignChapter4ObjectOrientedSystemDesign上海交通大學(xué)軟件工程中心Chapter4ObjectOrientedSystemDesign4.1OODesignOverview4.2ThePrinciplesofObject-OrientedDesign4.3ArchitecturalDesignandUMLPackageDiagram4.4ComponentDesignandU
2、MLComponentDiagram&CompositeStructurediagram4.5ClassDesignandUMLStateMachineDiagramObjectOrientedAnalysisandDesign212010/1/8OODesignOverviewObjectOrientedAnalysisandDesign35.1OODesignOverview?UnderstandingDesign?AnalysisVersusDesign?ObjectOrientedDesignObjectOrientedAnalysisandDesi
3、gn422010/1/8UnderstandingDesign?Aprocessthatusestheproductsofanalysistoproduceaspecificationforimplementingasystem.?AlogicaldescriptionofhowasystemwillAlogicaldescriptionofhowasystemwillwork.?Emphasizesaconceptualsolution(insoftwareandhardware)thatfulfillstherequirements,ratherthan
4、itsimplementation.?“dotherightthing(analysis),anddothethingright(design)”.ObjectOrientedAnalysisandDesign5AnalysisVersusDesign?Analysis?Design?Focuson?Focusonunderstandingtheunderstandingtheproblemsoltilution?Idealizeddesign?Operationsand?Behaviorattributes?Systemstructure?Performa
5、nce?Functional?Closetorealcoderequirements?Objjyectlifecycles?Asmallmodel?Nonfunctionalrequirements?AlargemodelObjectOrientedAnalysisandDesign632010/1/8ObjectOrientedDesign?Thespecificationofalogicalsoftwaresolutionintermsofsoftwareobjects,?suchastheirclasses,attributes,methods,and
6、collaborations.?Duringobject-orienteddesign(orsimply,objectdesign)thereisanemphasisondefiningsoftwareobjectsandhowtheycollaboratetofulfilltherequirements.ObjectOrientedAnalysisandDesign7ThePrinciplesofObject-OrientedDesignObjectOrientedAnalysisandDesign842010/1/85.2ThePrinciplesofO
7、bject-OrientedDesign?SRP:SingleResponsibilityPrinciple?OCP:TheOpen-ClosedPrinciple?LSP:TheLisoSubsuoskovSubstitutionPrincpeciple?DIP:TheDependencyInversionPrinciple?ISP:TheInterfaceSegregationPrincipleObjectOrientedAnalysisandDesign9SRP:TheSingle–ResponsibilityPrinciple?AClassshoul
8、dhaveonlyonereasontochange