欢迎来到天天文库
浏览记录
ID:14926457
大小:327.00 KB
页数:15页
时间:2018-07-31
《自动售货机 需求报告》由会员上传分享,免费在线阅读,更多相关内容在教育资源-天天文库。
1、VendingMachine1-ObjectivesTheobjectivesofthisexerciseareto:·BasedonTOODdesignapproach,propose2solutionsforthedesignarchitectureoftheVendingMachinepresentedinspecificationmodule:·Firstsolution:sequential-withoutprocess.Usingasequentialsolution,itisinterestingtoshowthanonem
2、odeoftheStateTransitionDiagram(STD)cannotbereached:“DispensingProduct”.·Secondsolution:concurrent-withprocess(es).Hypothesismustbemadeonthehardware.2-ProblemOverviewThisexampleisanextensionoftheproblempresentedattheForum”StructuredDevelopment”inSanFrancisco,inFebruary1986
3、.Theproblemstatementandtheresultingmodelswereinteractivelydevelopedanddescribedasadialoguebetweenthecustomerandtheanalyst.Thecustomerstartedbyoutliningtotheanalystthatheisfacedwithcrooksascustomerswhotryputtingjunkintothecoinslotsofhisvendingmachineshopingtogetsomethingfo
4、rnothing.Someeventrytoentercoin-likeslugstofoolthemachines.Theyalsotrytovandalizetheselectionregistertogetproductsfree.Thesearemajorproblemsforthevendingmachineoperatorsbecausetheydobusinessonanarrowmargin,whichdisappearsveryquickly.Themachineistodothefollowing:-Acceptobj
5、ectsfromthecustomerinpaymentforhis/herpurchase.-Checkeachobjecttomakesurethatitisnotaslug.Thisistobedonebyvalidatingthesize,weightandthickness.-Acceptnickels,dimesandquarters.Anyothercoinsaretobetreatedasslugsandreturnedtothecustomer.-Onlyinitiatepaymentcomputationorprodu
6、ctselectionprocessafteravalidatedcoinisdetected.-Acceptproductselectionfromthecustomer.-Checktoseewhethertheselectedproductisavailable,ifnotavailable,returncoinsautomaticallyandnotifycustomer.-Acceptavarietyofproducts,whichwillchangefromtimetotime.Hence,theproductpricessh
7、ouldbechangeable.-Returnthecustomer’spaymentonrequestifheorshedecidesnottomakeaselection.-Dispensetheproducttothecustomerifitisavailableandtheamountissufficient.-Returnthecorrectchangetothecustomeriftheamountdepositisgreaterthantheproductprice(initialconditions?).-Disable
8、theproductselectionaftertheproductisdispensedanduntilthenextvalidatedcoinisreceived.Severalextra
此文档下载收益归作者所有