UsingUML,Patterns,andJavaObject-OrientedSoftwareEngineeringChapter6SystemDesign:DecomposingtheSystem福州SEOhttp:UsingUML,Patterns,andJava2Design“Therearetwowaysofconstructingasoftwaredesign:Onewayistomakeitsosimplethatthereareobviouslynodeficiencies,andtheotherwayistomakeitsocomplicatedthattherearenoobviousdeficiencies.”-C.A.R.HoareWhichwouldbemoredifficult?BerndBruegge&AllenH.DutoitObject-OrientedSoftwareEngineering:UsingUML,Patterns,andJava3WhyisDesignsoDifficult?Analysis:FocusesontheapplicationdomainDesign:FocusesonthesolutiondomainDesignknowledgeisamovingtargetThereasonsfordesigndecisionsarechangingveryrapidlyHalftimeknowledgeinsoftwareengineering:About3-5yearsWhatIteachtodaywillbeoutofdatein3yearsCostofhardwarerapidlysinking“Designwindow”:TimeinwhichdesigndecisionshavetobemadeTechniqueTime-boxedprototypingThe“evolutionaryrapiddevelopment”processfocusesontheuseofsmallartisan-basedteamsintegratingsoftwareandsystemsengineeringdisciplinesworkingmultiple,oftenparallelshort-durationtimeboxeswithfrequentcustomerinteraction.…reuseofarchitecturalcomponents…BerndBruegge&AllenH.DutoitObject-OrientedSoftwareEngineering:UsingUML,Patterns,andJava4OverviewSystemDesignI(Today)0.OverviewofSystemDesign1.DesignGoals2.SubsystemDecompositionSystemDesignII:AddressingDesignGoals(nextlecture)3.Concurrency4.Hardware/SoftwareMapping5.PersistentDataManagement6.GlobalResourceHandlingandAccessControl7.SoftwareControl8.BoundaryConditionsMoreSelfreadingBerndBruegge&AllenH.DutoitObject-OrientedSoftwareEngineering:UsingUML,Patterns,andJava5SystemDesignSystemDesign2.SystemLayers/PartitionsCohesion/Coupling5.Data1.DesignGoalsDefinitionTrade-offs4.Hardware/SpecialpurposeSoftwareBuyorBuildTrade-offAllocationConnectivity3.ConcurrencyDatastructurePersistentObjectsFilesDatabasesManagementAccesscontrolSecurity6.GlobalResourceHandling8.BoundaryConditionsInitializationTerminationFailureDecompositionMapping7.SoftwareControlIdentificationofThreadsMonolithicEvent-DrivenThreadsConc.ProcessesBerndBruegge&AllenH.DutoitObject-OrientedSoftwareEngineering:UsingUML,Patterns,andJava6HowtousetheresultsfromtheRequirementsAnalysisforSystemDesignNonfunctionalrequirements=Activity1:DesignGoalsDefinitionFunctionalmodel=Activity2:Systemdecomposition(Selectionofsubsystemsbasedonfunctionalrequirements,cohesion,andcoupling)Objectmodel=Activity4:Hardware/softwaremappingActivity5:PersistentdatamanagementDynamicmodel=Activity3:ConcurrencyActivity6:GlobalresourcehandlingActivity7:SoftwarecontrolSubsystemDecompositionActivity8:BoundaryconditionsBerndBruegge&AllenH.DutoitObject-OrientedSoftwareEngineering:UsingUML,Patterns,andJava7ListofDesignGoalsReliabilityModifiabilityMaintainabilityUnderstandabilityAdaptabilityReusabilityEfficiencyPortabilityTraceabilityofrequirementsFaulttoleranceBackward-compatibilityCost-effectivenessRobustnessHigh-performanceGooddocumentationWell-definedinterfacesUser-friendlinessReuseofcomponentsRapiddevelopmentMinimum#oferrorsReadabilityEaseoflearningEaseofrememberingEaseofuseIncreasedproductivityLow-costFlexibilityAretheseexhaustive?Anythingelse?Whatdowedowithallthese?BerndBruegge&AllenH.DutoitObject-OrientedSoftwareEngineering:UsingUML,Patterns,andJava8HowdowegettheDesignGoals?Let’slookatasmallexampleCurrentSituation:ComputersmustbeusedintheofficeWhatwewant:Acomputerthatcanbeusedinmobilesituations.ProblemWhy?Whatarethetechnicaltermsdescribingthetwo?BerndBruegge&AllenH.DutoitObject-OrientedSoftwareEngineering:UsingUML,Patterns,andJava9SingleOutputDevicePreciseInputDirectionwheretheuserlooksisirrelevantFixedNetworkConnectionLocationofuserdoesnotmatterIdentifyCurrentTechnologyConstraintsBerndBruegge&AllenH.DutoitObject-OrientedSoftwareEngineering:UsingUML,Patterns,andJava10SingleOutputDevicePreciseInputDirectionwheretheuserlooksisirrelevantFixedNetworkConnectionLocationofuserdoesnotmatterMultipleOutputDevicesVagueInputDirectionwheretheuserlooksisrelevantDynamicNetworkConnectionLocation-basedGeneralizeConstraintsusingTechnologyEnablersAnyconcretescenarios?BerndBruegge&AllenH.DutoitObject-OrientedSoftwareEngineering:UsingUML,Patterns,andJava11EstablishNewDesignGoalsMobileNetworkConnectionMultipleOutputDevicesLocation-BasedMultimodalInput(UsersGaze,UsersLocation,…)VagueinputAretheseRequirementsorDesign?BerndBruegge&AllenH.DutoitObject-OrientedSoftwareEngineering:UsingUML,Patterns,andJava12SharpentheDesignGoalsLocation-basedinputInputdependsonuserlocationInputdependsonthedirectionwheretheuserlooks(“egocentricsystems”)Multi-modalinputTheinputcomesfrommorethanoneinputdeviceDynamicconnectionContractsareonlyvalidforalimitedtimeIsthereapossibilityoffurthergeneralizations?Example:locationcanbeseenasaspecialcaseofcontextUserpreferenceispartofthecontextInterpretationofcommandsdependsoncontextBerndBruegge&AllenH.DutoitObject-OrientedSoftwareEngineering:UsingUML,Patterns,andJava13RelationshipBetweenDesignGoalsReliab