Requirements Modeling principles /
Analysis Modeling principles.
•Principle 3. The behavior of the software (as a
consequence of external events) must be
represented.
–The behavior of computer software is driven by its
interaction with the external environment. Input
provided by end users, control data provided by an
external system, or monitoring data collected over a
network all cause the software to behave in a specific
way.
Requirements Modeling principles /
Analysis Modeling principles.
•Principle4.Themodelsthatdepictinformation,
function,andbehaviormustbepartitionedina
mannerthatuncoversdetailinalayered(or
hierarchical)fashion.
•Principle 5. The analysis task should move from
essential information toward implementation
detail.
What is Requirements analysis /
Analysis modeling
•Requirementsmodelingusesacombinationoftextand
diagrammaticformstodepictrequirementsinawaythat
isrelativelyeasytounderstand,andmoreimportant,
straightforwardtoreviewforcorrectness,completeness,
andconsistency.
•Whodoesit?
–Asoftwareengineer(sometimescalledan“analyst”)
buildsthemodelusingrequirementselicitedfromthe
customer.
•Whyisitimportant?
–Tovalidatesoftwarerequirements,youneedto
examinethemfromanumberofdifferentpointsof
view.
Analysis modeling
•Analysis modeling
focuses on three
attributes of
software:
–information to be
processed
–function to be
delivered
–behavior to be
exhibited.
Itgivesthe
situation to
discoverwhatthe
problemreallyis
Types of Requirements analysis /
Analysis modeling
(It is the first technical representation of systems)
•Scenario-basedmodelsofrequirementsfromthepointof
viewofvarioussystem“actors”
•Datamodelsthatdepicttheinformationdomainforthe
problem
•Class-basedmodelsthatrepresentobject-orientedclasses
(attributesandoperations)andthemannerinwhichclasses
collaboratetoachievesystemrequirements
•Flow-orientedmodelsthatrepresentthefunctionalelements
ofthesystemandhowtheytransformdataasitmoves
throughthesystem3
•Behavioralmodelsthatdepicthowthesoftwarebehavesasa
consequenceofexternal“events”.
–ThemostcommonmethodforcreatingthesediagramsisUML,
UnifiedModelingLanguage.
Elements/Types of Requirements analysis /
Analysis modeling
Use-cases Text
•Thefirststepindefiningausecaseistodefinethename,
usingtheverb-nounnamingconvention.
Sample Use Case Brief
•Use Case Name: Place Order
•Actors:
–Shopper
–Fulfillment System
–Billing System
•UseCaseDescription:Aftertheuserhasselecteditemsto
purchaseandthenordertheitems.Theuserwillprovide
paymentandshippinginformation.Thesystemwillrespond
withconfirmationoftheorderandatrackingnumberthat
theusercanusetocheckonorderstatusinthefuture.The
systemwillalsoprovidetheuserwithanestimateddelivery
datefortheorder,whichwillincludeallselecteditems.The
usermayalreadyhaveanaccountwiththecompanywith
billingandshippinginformation.
Detail/Formal Use Case Example
•You can clarify the use case further by refining the use case into a formal use case.
Example Usecase
•Use Case Name: Place Order
•Actors:
•Registered Shopper (Has an existing account, possibly with billing and shipping
information)
•Non-registered Shopper (Does not have an existing account)
•Fulfillment System (processes orders for delivery to customers)
•Billing System (bills customers for orders that have been placed)
•Triggers:
•The user indicates that she wants to purchase items that she has selected.
•Preconditions:
•User has selected the items to be purchased.
•Post-conditions:
•The order will be placed in the system.
•The user will have a tracking ID for the order.
•The user will know the estimated delivery date for the order.
Detail/Formal Use Case Example
•Normal Flow:
•Theuserwillindicatethatshewantstoordertheitemsthathavealreadybeen
selected.
•Thesystemwillpresentthebillingandshippinginformationthattheuserpreviously
stored.
•Theuserwillconfirmthattheexistingbillingandshippinginformationshouldbeused
forthisorder.
•Thesystemwillpresenttheamountthattheorderwillcost,includingapplicabletaxes
andshippingcharges.
•Theuserwillconfirmthattheorderinformationisaccurate.
•ThesystemwillprovidetheuserwithatrackingIDfortheorder.
•Thesystemwillsubmittheordertothefulfillmentsystemforevaluation.
•Thefulfillmentsystemwillprovidethesystemwithanestimateddeliverydate.
•Thesystemwillpresenttheestimateddeliverydatetotheuser.
•Theuserwillindicatethattheordershouldbeplaced.
•Thesystemwillrequestthatthebillingsystemshouldchargetheuserfortheorder.
•Thebillingsystemwillconfirmthatthechargehasbeenplacedfortheorder.
•Thesystemwillsubmittheordertothefulfillmentsystemforprocessing.
•Thefulfillmentsystemwillconfirmthattheorderisbeingprocessed.
•Thesystemwillindicatetotheuserthattheuserhasbeenchargedfortheorder.
•Thesystemwillindicatetotheuserthattheorderhasbeenplaced.
•Theuserwillexitthesystem.
Use-cases diagrams
•IntheUnifiedModelingLanguage(UML),ausecase
diagramcansummarizethedetailsofyoursystem's
users(alsoknownasactors)andtheirinteractionswith
thesystem.
•Createaprofessionaldiagramforanyusecaseusing
UMLdiagramtool.
•Tobuildone,you'lluseasetofspecializedsymbolsand
connectors.
•Aneffectiveusecasediagramcanhelpprojectteamto
discussandrepresent(useofuse-caseModel):
–Representing the goals of system-user interactions
–Defining and organizing functional requirements in a system
–Specifying the context and requirements of a system
–Modeling the basic flow of events in a use case
–Thescopeofyoursystem
Use case diagram components
•Actors:Theusersthatinteractwithasystem.An
actorcanbeaperson,anorganization,oran
outsidesystemthatinteractswithyourapplication
orsystem.Theymustbeexternalobjectsthat
produceorconsumedata.
•System:Aspecificsequenceofactionsand
interactionsbetweenactorsandthesystem.A
systemmayalsobereferredtoasascenario.
•Goals:Theendresultofmostusecases.A
successfuldiagramshoulddescribetheactivities
andvariantsusedtoreachthegoal.
Example 1
Use case diagram symbols and notation
•Usecases:Horizontallyshapedovalsthatrepresentthe
differentusesthatausermighthave.
•Actors:Stickfiguresthatrepresentthepeopleactually
employingtheusecases.
•Associations:Alinebetweenactorsandusecases.In
complexdiagrams,itisimportanttoknowwhichactors
areassociatedwithwhichusecases.
•Systemboundaryboxes:Aboxthatsetsasystemscope
tousecases.Allusecasesoutsidetheboxwouldbe
consideredoutsidethescopeofthatsystem.For
example,PsychoKillerisoutsidethescopeofoccupations
inthechainsawexamplefoundbelow.
•Packages:AUMLshapethatallowsyoutoputdifferent
elementsintogroups.Justaswithcomponentdiagrams,
thesegroupingsarerepresentedasfilefolders.
How to Draw an Activity Diagram?
•Beforedrawinganactivitydiagram,wemusthaveaclear
understandingabouttheelementsusedinactivity
diagram.
•Themainelementofanactivitydiagramistheactivity
itself.Anactivityisafunctionperformedbythesystem.
•Afteridentifyingtheactivities,weneedtounderstand
howtheyareassociatedwithconstraintsandconditions.
•ComponentsofActivityDiagram:
–Activities
–Association
–Conditions
–Constraints
Example -order management system
•Theactivitydiagramismadetounderstandtheflowof
activitiesandismainlyusedbythebusinessusers.
•Followingdiagramisdrawnwiththefourmainactivities−
–Sendorderbythecustomer
–Receiptoftheorder
–Confirmtheorder
–Dispatchtheorder
•Afterreceivingtheorderrequest,conditionchecksare
performedtocheckifitisnormalorspecialorder.After
thetypeoforderisidentified,dispatchactivityis
performedandthatismarkedastheterminationofthe
process.
Example -order management system
Activity diagram can be used for
•Activitydiagramcanbeusedfor−
–Modelingworkflowbyusingactivities.
–Modelingbusinessrequirements.
–Highlevelunderstandingofthesystem's
functionalities.
–Investigatingbusinessrequirementsata
laterstage.
Swimlane Diagram
•Aswimlanediagramisatypeofflowchartthatdelineateswho
doeswhatinaprocess.
•Activitydiagramstellyouwhathappens,buttheydonottellyou
whodoeswhat.
•Like a flowchart, it diagrams a process from start to finish, but it
also divides these steps into categories(lanes) to help distinguish
which departments or employees are responsible for each set of
actions.
•Itshowsconnections,communicationandhandoffsbetween
theselanes,anditcanservetohighlightwaste,redundancyand
inefficiencyinaprocess.
Why Swimlane Diagrams Are Useful
•Duringanyprocessimprovementinitiative,swimlaneshelpidentifynotjustthe
bottlenecksinaprocess,butalsowhichdepartmentisresponsibleforthem.
•Helpingtoclarifyresponsibilitiesandhelpdepartmentsworktogetherinaworld
wheredepartmentsoftendon'tunderstandwhattheotherdepartmentsdo.
•Youmayfindcostlyredundanciesandduplicationsorgapsandcommunication
problems.
How to Create a Swim Lane Flowchart
•Identifythelanes.Decidewhatdivisionsyouneedrepresentedbyswimlanes
andlabelthem.
•Startyourchart.Definethestartingpointoftheprocess.Addarounded
rectangletothetopoftheappropriateswimlanetoindicateitsstartingpoint
andlabelit.
•Addsteps.Nextaddmorestepstoyourchart.Eachstepshouldbeconnected
totheonebeforeitwithaline.Todrawstepsinthesameswimlane,draw
fromtoptobottom.Toaddastepinanotherdivisiongofromlefttoright.
Witheachstep,describewhatitrepresentsuntilyoureachtheendofthe
process.Thearrowsbetweenthestepsindicatethetransferofinformationor
flow.