Systems Analysis and Design I

Slides:



Advertisements
Similar presentations
Use Case & Use Case Diagram
Advertisements

Solutions to Review Questions
© 2010 Bennett, McRobb and Farmer1 Use Case Description Supplementary material to support Bennett, McRobb and Farmer: Object Oriented Systems Analysis.
UML (Sequence Diagrams, Collaboration and State Chart Diagrams) Presentation By - SANDEEP REDDY CHEEDEPUDI (Student No: ) - VISHNU CHANDRADAS (Student.
© 2010 Bennett, McRobb and Farmer1 Requirements Analysis 1: Requirements and Classes Based on Chapter 7 of Bennett, McRobb and Farmer: Object Oriented.
Information System Design IT60105
Chapter 6 Review Questions
Lecturer: Sebastian Coope Ashton Building, Room G.18 COMP 201 web-page: Lecture.
Object-Oriented Analysis and Design. Priorities in O-O Analysis and Design Understanding a system in terms of objects and associations between them. Representing.
1 © Wolfgang Pelz UML2 UML Part Two. 2 © Wolfgang Pelz UML2 Chapters Four & Twelve Interaction Diagrams.
University of Toronto Department of Computer Science © Steve Easterbrook. This presentation is available free for non-commercial use with attribution.
Requirements Analysis
© Copyright Eliyahu Brutman Programming Techniques Course.
03/12/2001 © Bennett, McRobb and Farmer Use Case Diagrams Based on Chapter 6 of Bennett, McRobb and Farmer: Object Oriented Systems Analysis and.
Unified Modeling Language
Software Engineering EKT 420. What is Activity Diagram Activity diagrams are graphical representations of workflows of stepwise activities and actions.
University of Toronto at Scarborough © Bennett, McRobb and Farmer 2005 CSCC40 classes 1 Use CasesUse Case Model Campaign Management PackageModelSub-system.
Introduction to Sequence Diagrams
SOFTWARE DESIGN AND ARCHITECTURE LECTURE 21. Review ANALYSIS PHASE (OBJECT ORIENTED DESIGN) Functional Modeling – Use case Diagram Description.
1 SAD2 - UML 2 nd Lecture Sequence Diagram and other dynamic views Lecturer: Dr Dimitrios Makris
ECE450 - Software Engineering II1 ECE450 – Software Engineering II Today: An Aside: The Quickest Tour through the UML that you will ever get.
CSC 395 – Software Engineering Lecture 13: Object-Oriented Analysis –or– Let the Pain Begin (At Least I’m Honest!)
© 2007 Pearson Education, Inc. Publishing as Pearson Addison-Wesley 1 UML Sequence Diagrams.
1 Devon M. Simmonds University of North Carolina, Wilmington CSC450 Software Engineering WorkFlow Modeling with Activity Diagrams.
© Bennett, McRobb and Farmer Requirements Analysis Based on Chapter 7 of Bennett, McRobb and Farmer: Object Oriented Systems Analysis and Design.
Activity diagrams. Introduction ● Activity diagrams are a behavioural model that represent the dynamics of the system. ● An activity diagram is essentially.
© 2010 Bennett, McRobb and Farmer1 Object Interaction – Interaction Overview Diagrams Timing Diagrams Based on Chapter 09 Bennett, McRobb and Farmer Object.
Object-Oriented Software Engineering Practical Software Development using UML and Java Chapter 8: Modelling Interactions and Behaviour UML Sequence Diagram.
University of Toronto at Scarborough © Bennett, McRobb and Farmer 2005 CSCC40 communication and sequence diagrams : listCampaigns *[For.
WXGC6102: Object-Oriented Techniques Object Interaction – Interaction Overview Diagrams Timing Diagrams References: Chapter 9 of Bennett, McRobb and Farmer:
Use Case Driven Analysis Requirements Use Case Use Case Description System Sequence Diagram Chapter 5.
Introduction to UML CS A470. What is UML? Unified Modeling Language –OMG Standard, Object Management Group –Based on work from Booch, Rumbaugh, Jacobson.
CS212: Object Oriented Analysis and Design Lecture 34: UML Activity and Collaboration diagram.
CS212: Object Oriented Analysis and Design Lecture 32: Use case and Class diagrams.
22 August, 2007Information System Design IT60105, Autumn 2007 Information System Design IT60105 Lecture 8 Use Case Diagrams.
© Bennett, McRobb and Farmer Object Interaction – Sequence Diagrams Based on Chapter 9 of Bennett, McRobb and Farmer: Object Oriented Systems Analysis.
UML Activity Diagrams.
Chapter 3: Introducing the UML
Use Case Diagrams. Introduction In the previous Lecture, you saw a brief review of the nine UML diagrams. Now that you have the clear, you'll start to.
UML Activity and Sequence Diagrams David Millard
ER Diagrams ● Many different notations are available ● From wikipedia:wikipedia: Entity-relationship modelwikipedia: Entity-relationship model ● How do.
Business Process and Functional Modeling
Activity Diagrams.
Welcome to M301 P2 Software Systems & their Development
Object Interaction – Interaction Overview Diagrams Timing Diagrams
Using Use Case Diagrams
Chapter 4: Business Process and Functional Modeling, continued
Object-Oriented Analysis and Design
Unified Modeling Language
OO Domain Modeling With UML Class Diagrams and CRC Cards
UML Activity Diagrams.
OO Domain Modeling With UML Class Diagrams and CRC Cards
UML Sequence Diagrams.
Use Case Modeling - techniques for detailing use cases
SAD ::: Spring 2018 Sabbir Muhammad Saleh
Week 12: Activity & Sequence Diagrams
Use Cases 1.
BPMN - Business Process Modeling Notations
Practical Software Engineering
Using Use Case Diagrams
Business Analysis More on Classes Chris Russell O2.41
Software Engineering System Modeling Chapter 5 (Part 1) Dr.Doaa Sami
Interaction Modeling Extracted from textbook:
Systems Analysis and Design I
Systems Analysis and Design I
Systems Analysis and Design I
Systems Analysis and Design I
Object Oriented System Design Class Diagrams
Refining the Requirements Model
Presentation transcript:

Systems Analysis and Design I Revision Class May 20th 2019

Contents Level 4, 15 credits Module code: COIY016H4 Lecture Date Lab Remark W1 Introduction, IS development Object-orientation fundamentals Jan 14 None W2 Jan 21 W3 Modelling concepts, activity diagram Jan 28 W4 Requirements, use cases Feb 4 W5 Class diagrams+Project Tutorial Feb 11 Test 1 W6 Sequence diagrams Feb 18 Group Project 1 W7 State diagrams 1+Project Tutorial Feb 25 Group Project 2 W8 State diagrams 2+Project Tutorial Mar 4 Group Project 3 W9 Mar 11 Group Project 4 Test 2 W10 System design+Project Tutorial Mar 18 Group Project 5 Make-up Test 1 W11 Version control+Project Tutorial Mar 25 Group Project 6 Make-up Test 2 Level 4, 15 credits Module code: COIY016H4 All material is available: http://www.dcs.bbk.ac.uk/~taolue/SADI/SADI.htm

Assessment Coursework (20%) Examination (80%) 2 In-Class Tests (5% each) 25 Multiple-Choice Questions (in 25 mins) Test 1 (on Week 5, Feb 11) Test 2 (on Week 9, Mar 11) Both questions and answers have been uploaded to Moodle 1 Group Project (10%) 50 Marks Evaluation Quality of your report: 25 marks. Feedback from your peers: 25 marks. Examination (80%) 3

Examination 2-hour exam, FOUR questions, 100 marks Past papers is available http://www.bbk.ac.uk/library/exam-papers/computer-science [under “information systems concepts”] Two different types of questions: Short-answer questions (Small) case studies with UML modelling

Examples What are the advantages of the traditional waterfall lifecycle (TLC)? (5 marks) Answer: Tasks in phases may be assigned to specialised teams. (1 mark) Project progress is evaluated at the end of each phase. (2 marks) TCL can be used to manage projects with high levels of risks. (2 marks) You will see FIVE short-answer questions in the exam, each of them is worth 5 marks Suggestion: look at the past papers, go through all of those questions and try to answer them Read the slides and textbook please!

UML Modelling UML2 defines 14 types of diagrams Structure Behaviour Class Diagram, Object Diagram Component Diagram, Package Diagram, Profile Diagram Composite Structure Diagram, Deployment Diagram Behaviour Use Case Diagram Activity Diagram, State Machine Diagram Interaction Sequence Diagram, Communication Diagram Timing Diagram, Interaction Overview Diagram 6 6

Activity diagrams Used to model high-level business tasks and system functions action node rectangle with rounded corners and a meaningful name action edge (control flow) open arrow Add a New Client Action exists to carry out some task. Action exists to carry out some task. The flow implies that as soon as the first action is complete, the next action is started. Assign Staff Contact The flow implies that as soon as the first action is complete, the next action is started. 7 7

Notation of Activity Diagrams initial node black circle decision node merge node diamond guard condition in square brackets final node black circle in white circle [campaign to add] [no campaign to add] Add a New Client Assign Staff Contact Add New Campaign The flow of control will follow along the first control flow with a guard condition that evaluates to true. 8 8

Tips on Activity Diagrams [no staff to assign] Add a New Client Assign Staff Contact Add New Campaign [campaign to add] [no campaign to add] Assign Staff to Campaign [staff to assign] Iteration or loop can be represented Multiple flows from an action are implicitly AND-ed Guard conditions do not have to be mutually exclusive, but it is advisable that they should be If they are not, you need to specify the order of evaluation (otherwise the results will be unpredictable) Decisions should be strictly nested, but a merge point can be combined with the following decision point 9 9

Notation of Activity Diagrams fork node join node thick bar actions carried out in parallel Add a New Client Assign Staff Contact Add New Campaign 10 10

Self-Check of activity diagrams Action Nodes action node, decision node, initial node, final node, merge node, fork node, join node Edges: action edge, guard conditions OO related: class name, operation name, object flow, activity partition Interrupting edge is activity edge expressing interruption for regions having interruptions. It is rendered as a lightning-bolt 11 11

Use case diagram Use Cases – descriptions of the functionality of the system from the users’ perspective. Use Case diagrams show which users will communicate with the system define the scope of the system Use Case descriptions specify the interaction between the users (actors) and the system for each use case as the users see it could be further elaborated by communication/sequence diagrams.

System or subsystem boundary Use Case Diagram Four aspects: actors use cases Communication association system/subsystem boundary System or subsystem boundary Actor Use case Communication association Staff Contact Change a client contact 13 13

Extend and Include relationships Use Case Diagrams: Extend and Include relationships The extend and include relationships between Use Cases shown as stereotyped dependencies [a stereotype is a special use of a model element that is constrained to behave in a particular way] Stereotype are shown by using a keywork in match guillemets «extend» and «include» (text strings in guillemets) Warning: easy to confuse extend and include! Dependencies Extend and Include relationships between use cases shown as stereotyped dependencies stereotypes are written as text strings in guillemets: «extend» and «include» 14 14

Use Case Diagrams: «extend» Extend means: One use case provides additional functionality that may be required in another use case “does something over and above what is done” There may be multiple ways of extending a use case represent variations in the way that actors interact with the use case Rather than capturing all variations in one use case, document the core functionality in one and then extend it with other The extension points show when the extension occurs A condition can be placed in a note joined to the dependency arrow 15 15

Use Case Diagrams: «extend» Campaign Manager Check campaign budget summary «extend» Print campaign Summary print extension points Condition {print option selected} extension point: Summary print Note: is not put in square brackets, unlike conditions in other diagrams.) Fig. 6.7 16 16

Use Case Diagrams: «include» When there is a sequence of behaviour that is used frequently in a number of use cases Want to avoid copying the same description everywhere separate out the sequence of behaviour that is used in many use cases One use case includes the functionality of another use case A use case may include more than one other Do not overuse: Should not be used to create a hierarchical functional decomposition of the system 17 17

Assign staff to work on a campaign Use Case Diagrams: «include» Campaign Manager «include» Find campaign Assign staff to work on a campaign Fig 6.8 18 18

Note: you do NOT need to show all the details of the extension points

Use Case Diagrams: Generalisation Between use cases: there may be similar use cases with common functionality best represented by generalising out that functionality in to a “super-use-case” shows that one use case provides all the functionality of the more generalised use case and some additional functionality Between actors: shows that one actor can participate in all the associations with use cases the more specific actor can plus some additional use cases 20 20

Use Case Diagrams: Generalisation Record completion of an advert Staff Contact Change a client contact Fig. 6.10 Super use case Assign individual staff to work on a campaign Assign staff to work on a campaign Assign team of staff to work on a campaign Campaign Manager 21 21

Use Case Descriptions Using a step-by-step breakdown of interaction between actor and system Assign staff to work on a campaign Actor Action System Response 1. The actor enters the client name. 2. Lists all campaigns for that client. 3. Selects the relevant campaign. 4. Displays a list of all staff members not already allocated to this campaign. 5. Highlights the staff members 6.Presents a message confirming to be assigned to this campaign. that staff have been allocated. Alternative Courses Steps 1–3. The actor knows the campaign name and enters it directly. scenario Referred to as scenario 22 22

Class diagrams class name compartment attributes compartment Class (and Object/Instance) Stereotypes Attributes (and State) Associations (and Links) Multiplicity Operations Client companyAddress companyEmail companyFax companyName companyTelephone class name compartment attributes compartment Only staff members in the role of staff contact can participate in this association operations compartment 23

direction in which name should be read (optional) association association role Client StaffMember companyAddress staffContact staffName companyEmail staffNo liaises with companyFax staffStartDate companyName Only staff members in the role of staff contact can participate in this association companyTelephone association name direction in which name should be read (optional) Only staff members in the role of staffContact can participate in this association 24 24

Association End association role Professor "playing the role" of author is associated with textbook end typed as Book. The idea of the role is that the same class can play the same or different roles in other associations. For example, Professor could be an author of some Books or an editor.

Multiplicity The multiplicity of an association is the range of permitted cardinalities of its participating objects (i.e., #objects that can participate in the association) Decided by business rules. for example: any bank customer may have one or more accounts every individual account is for one, and only one, customer n: exactly n *: any number m..n: any number in the range m to n (inclusive) 0..1: optional (i.e., either none or 1) 1..*: at least one 26 26

Aggregation and Composition Two special types of association Aggregation represents a whole-part relationship between classes Composition (or Composition aggregation) is based on the concept of aggregation Composition expresses a similar relationship but differs in showing a stronger form of ownership by the whole Each part may belong to only one whole at a time. When the whole is destroyed, so are all its parts. 27 27

Composition vs aggregation In both aggregation and composition object of one class "owns" object of another class. But there is a subtle difference. In Composition the object of class that is owned by the object of it's owning class cannot live on it's own Also called "death relationship". It will always live as a part of it's owning object In Aggregation the dependent object is standalone and can exist even if the object of the owning class is dead. So in composition if owning object is garbage collected the owned object will also be which is not the case in aggregation. Confused? Composition Example : Consider example of a Car and an engine that is very specific to that car (meaning it cannot be used in any other car). This type of relation ship between Car and SpecificEngine class is called Composition. Object of Car class cannot exist without object of SpecificEngine class and object of SpecificEngine has no significance without Car class. To put in simple words Car class solely "owns" the SpecificEngine class. Aggregation Example : Now consider class Car and class Wheel. Car needs a Wheel object to function. Meaning Car object own Wheel object but we cannot say Wheel object has no significance without Car Object. It can very well be used in a Bike, Truck or different Cars Object. Aggregation and Composition are subsets of association meaning they are specific cases of association.

unfilled diamond denotes aggregation Notation: Aggregation A student could be in a number of modules If a module is cancelled, students are not destroyed Module Student 0..* 1..* unfilled diamond denotes aggregation “Owing” class 29 29

filled diamond denotes composition Notation: Composition An ingredient is in only one meal at a time If you drop your meal on the floor, you probably lose the ingredients too Meal Ingredient 1..* 1 filled diamond denotes composition “Owing” class 30 30

Small trick Trick to remember the difference : has A -- Aggregation Own -- cOmposition So in composition if owning object is garbage collected the owned object will also be which is not the case in aggregation. Confused? Composition Example : Consider example of a Car and an engine that is very specific to that car (meaning it cannot be used in any other car). This type of relation ship between Car and SpecificEngine class is called Composition. Object of Car class cannot exist without object of SpecificEngine class and object of SpecificEngine has no significance without Car class. To put in simple words Car class solely "owns" the SpecificEngine class. Aggregation Example : Now consider class Car and class Wheel. Car needs a Wheel object to function. Meaning Car object own Wheel object but we cannot say Wheel object has no significance without Car Object. It can very well be used in a Bike, Truck or different Cars Object.

Adding Generalization Structure Figure 8.2 32 32

Class Diagrams Checklist Requirements Model → Analysis Model → Design Model To Draw a class diagram Identify Classes Determine Stereotypes Find and Locate Attributes Add Associations Determine Multiplicity Find and Locate Operations Class (and Object/Instance) Stereotypes Attributes (and State) Associations (and Links) Multiplicity Operations 33 33

Sequence diagram Frame label Sequence diagram is enclosed in a frame :Client :Campaign :Advert getName listCampaigns listAdverts Advert newAd:Advert addNewAdvert Lifeline Activation or Execution Object creation :CampaignManager sd Add a new advert to a campaign loop Interaction Operator Interaction Constraint Combined Fragment (loop) [For all client’s campaigns] getCampaignDetails [For all campaign’s adverts] getAdvertDetails Frame label Sequence diagram is enclosed in a frame “sd” is used to determine the interaction diagram; interaction

Sequence Diagrams: Example Figure 9.4 on p. 265 :LifelineA :LifelineB Synchronous (blocking) message sd Interaction Name msg a Send message Event Occurrence (msg.sendEvent) Receive messaged Event Occurrence (msg.recieveEvent) start of Execution Occurrence end of Active State on lifeline showing pre-condition Message reply showing return of control 36 36

Figure 9.16 on p. 275 alt interaction operator shows branching :Client :Campaign :Advert getName listCampaigns ref :CampaignManager Advert addCostedAdvert newAd:Advert newRequest:Request alt [else] sd Add a new advert to a campaign if within budget List client campaigns [totalCost <= budget] Request Get campaign budget alt interaction operator shows branching Two interaction operands, one for each alternative Figure 9.16 on p. 275 38 38

Example Suppose you are developing an online university enrollment system. Create a use case diagram for the following requirements. (a) The system should enable the academic staff to examine the modules offered by their department, add and remove modules, and change the information about them (e.g., the maximum number of students permitted). (6 marks) (b) It should permit students to examine currently available modules, add and drop modules from their schedules and examine the modules for which they are enrolled. (6 marks) (c) Department staff (i.e., academic and administrative staff) should be able to print a variety of reports about the modules and the students enrolled in them. (7 marks) (d) The system should ensure that no student takes too many modules and that students who have any unpaid fees are not permitted to register. (6 marks)

Answer (a) The system should enable the academic staff to examine the modules offered by their department, add and remove modules, and change the information about them (e.g., the maximum number of students permitted). (b) It should permit students to examine currently available modules, add and drop modules from their schedules and examine the modules for which they are enrolled. (c) Department staff (i.e., academic and administrative staff) should be able to print a variety of reports about the modules and the students enrolled in them. (d) The system should ensure that no student takes too many modules and that students who have any unpaid fees are not permitted to register.

Example Suppose you are developing a point-of-sale system that manages the checkout process in a supermarket. Create a class diagram for the following requirements. (a) Each transaction includes at least one item. Date and time of each transaction must be recorded. (4 marks) (b) Items can be coded or weighted. Coded items have code. Weighted items have price per kg and weight. All items have a method of calculating their price. (6 marks) (c) Some customers have loyalty cards. Only one loyalty card may be used in a transaction.(4 marks) (d) No transaction can be completed without a payment and each payment is made for a single transaction. (5 marks) (e) A payment can be made in cash or by debit/credit card. Cash payments record the amount given and change. Card payments record card number and bank authorization code.(6 marks)

Answer

In the exam You will encounter THREE such questions in the exam Each one asks you to develop one UML diagram which might be Activity diagram, class diagram, sequence diagram, use case diagram Each question is worth 25 marks. Suggestion: look at the past papers, go through all of those questions and try to come up with UML diagram by yourself

Good luck!