RMCode: Automatic Prototyping from Requirement Model Yilong Yang - - PowerPoint PPT Presentation

rmcode automatic prototyping from requirement model
SMART_READER_LITE
LIVE PREVIEW

RMCode: Automatic Prototyping from Requirement Model Yilong Yang - - PowerPoint PPT Presentation

RMCode: Automatic Prototyping from Requirement Model Yilong Yang Software Engineering Lab http://lab.mydreamy.net yylonly@gmail.com Preliminary Requirement Model Use Case Diagram System Sequence Diagram / Activity Diagram


slide-1
SLIDE 1

RMCode: Automatic Prototyping from Requirement Model

Yilong Yang

http://lab.mydreamy.net yylonly@gmail.com Software Engineering Lab

slide-2
SLIDE 2

Preliminary

  • Use Case Diagram
  • System Sequence Diagram / Activity Diagram
  • Conceptual Class Diagram
  • Operation Contract

Requirement Model

slide-3
SLIDE 3

Requirement Model

  • The responsibilities of the target system includes knowing

responsibilities and doing responsibilities.

  • Knowing responsibilities of the target system are specified by

the conceptual class diagram.

  • Doing responsibilities are specified by activity diagrams or

system sequence diagrams for use cases in the use case diagram.

  • Contract of doing responsibility not only contains the

signatures of operation but also pre and post conditions of

  • peration for fulfilling the responsibility
slide-4
SLIDE 4

Motivation

  • Requirement errors mostly lead to the failures of software

development.

  • Customers and end-user are not entirely sure of what is

needed before trying out the target software.

  • It is very desirable to have a tool to generate prototypes

directly from requirements automatically.

slide-5
SLIDE 5

State-of-arts

  • Current UML modeling tools can only generate skeleton

code, the operations still need to be manually implemented.

  • Even if providing a design model to each operation, only

less than 48% correct source code can be generated.

slide-6
SLIDE 6

RMCode: Requirement Modeler and Code Generator

  • RMCode can automatic generate object-oriented

prototype from UML requirement model.

  • Generated prototype can be used for validating the

requirements and eliciting more requirements.

slide-7
SLIDE 7

Case Study I CoCoME (Supermarket System)

slide-8
SLIDE 8

Use Case Diagram

slide-9
SLIDE 9

System Interactions

Activity Diagram System Sequence Diagram

slide-10
SLIDE 10

Doing responsibilities

slide-11
SLIDE 11

Conceputal Class Diagram

slide-12
SLIDE 12

Operation Contract

slide-13
SLIDE 13

Requirement Model in RMCode

slide-14
SLIDE 14

Generate Prototype

slide-15
SLIDE 15

Prototype: System Operations

slide-16
SLIDE 16

Prototype: System Status

slide-17
SLIDE 17

Generate CRUD Operations

slide-18
SLIDE 18

Loading or adding start-up data

slide-19
SLIDE 19

Start-up Data: UM Store

slide-20
SLIDE 20

Start-up data: Item Apple

slide-21
SLIDE 21

Validate ProcessSale

slide-22
SLIDE 22

Validate ProcessSale

slide-23
SLIDE 23

Refined Requirement Model

slide-24
SLIDE 24

OpenCashDesk

CashDesk1 Status:

slide-25
SLIDE 25

ProcessSale - makeNewSale

slide-26
SLIDE 26

ProcessSale - enterItem

Input Variables:

slide-27
SLIDE 27

ProcessSale - enterItem

slide-28
SLIDE 28

execute enterItem before makeNewSale

slide-29
SLIDE 29

ProcessSale - endSale

slide-30
SLIDE 30

ProcessSale - endSale

slide-31
SLIDE 31

ProcessSale - makeCashPayment

slide-32
SLIDE 32

ProcessSale - makeCashPayment

slide-33
SLIDE 33

Requirement Validation

If we miss this condition

slide-34
SLIDE 34

Requirement Validation

Sale Status After executing of enterItem (we need to pay 100 MOP)

slide-35
SLIDE 35

Requirement Validation

System Status After executing of CashPayment with only 80 payment CashPayment Invariant is not holding at this moment

slide-36
SLIDE 36

Next Step

  • We specified main functionality about Cashier about

checking out.

  • We did not touch storage management yet….
slide-37
SLIDE 37

Refined Requirement Model

slide-38
SLIDE 38

UseCase: OrderProducts

slide-39
SLIDE 39

Refining Conceptual Class Diagram

slide-40
SLIDE 40

showStockReports

slide-41
SLIDE 41

showStockReports

slide-42
SLIDE 42

changePrice

slide-43
SLIDE 43

changePrice

slide-44
SLIDE 44

After checking out this two surface laptop

slide-45
SLIDE 45

makeNewOrder

slide-46
SLIDE 46

Listing out of stock products

Bug? Let`s check post-condition Should be item.StockNumber = 0

slide-47
SLIDE 47

Fixing error requirement, re- generation, and running prototype

Bug? Let`s check post-condition Should be item.StockNumber = 0

slide-48
SLIDE 48

Fixing error requirement, re- generation, and running prototype

slide-49
SLIDE 49

Executing orderItem

slide-50
SLIDE 50

List suppliers and choose one

slide-51
SLIDE 51

Place Order

slide-52
SLIDE 52

Place Order

slide-53
SLIDE 53

Receive Ordered Products

slide-54
SLIDE 54

CoCoME (Supermarket System)

  • UML requirement model
  • Refine UML requirement model in RMCode
  • Validate and fix requirements
slide-55
SLIDE 55

Case Study II UM Library Management System

slide-56
SLIDE 56

Use Case Diagram

slide-57
SLIDE 57

Use Case Diagram

slide-58
SLIDE 58
slide-59
SLIDE 59
slide-60
SLIDE 60

The contract of borrowBook

slide-61
SLIDE 61
slide-62
SLIDE 62
slide-63
SLIDE 63

The contract of renewBook

slide-64
SLIDE 64

The contract of renewBook

slide-65
SLIDE 65

The contract of renewBook

slide-66
SLIDE 66

The contract of returnBook

slide-67
SLIDE 67

The contract of returnBook

slide-68
SLIDE 68

The contract of dueSoonNotification

slide-69
SLIDE 69

The contract of makeReservation

slide-70
SLIDE 70

The contract of makeReservation

slide-71
SLIDE 71

Prototype Functionality

slide-72
SLIDE 72

Prototype Status

slide-73
SLIDE 73

RMCode

  • RMCode is a good UML requirement modelling tool
  • RMCode provides an evolutionary approach to validate the

requirement

  • Good for training your mind as like project manager
slide-74
SLIDE 74

Contribute to RMCode

  • Download RMCode from
  • http://lab.mydreamy.net
  • Try the provided case studies from GitHub
  • https://github.com/yylonly/RMCodeCaseStudies.git
  • Create new case studies, then make a pull request
  • Open a new issue on GitHub, if bugs were found.
slide-75
SLIDE 75

Contribute to RMCode

  • Full-stack JavaScript Web Application
  • Java EE Application
  • Android/IOS Application

If you are interested in the development of :

slide-76
SLIDE 76

Thank You