You are on page 1of 12

Implementation

UNIT 3 CASE STUDY: INVENTORY CONTROL SYSTEM


Structure
3.0 3.1 3.2 3.3 3.4 3.5 3.6 3.7 3.8 3.9 Introduction Objectives Class Diagram Object Diagram Generalization and Association Diagram Collaboration Diagram Activity Diagram and Events Use Case Diagram Deployment Diagram Summary

Page Nos.
40 40 40 41 42 44 44 48 49 51

3.0 INTRODUCTION
Inventory control systems are used for managing the stocks of companies and big distribution organisations. In this unit we will discuss about OOM for invention control systems. We will cover class diagram design, object diagram different kind of relationships, which include generalization, association and collaboration. We will also discuss use case diagrams activities and events.

3.1 OBJECTIVES
After going through this unit, you should be able to: explain class diagram and object diagram of Inventory control System; describe generalization and Specialization of the system; describe collaboration diagram of the system; explain different activities and events of the systems, and explain deployment Diagram.

3.2 CLASS DIAGRAM


You know that a class is represented in a box like figure. Here we are taking the case study of Inventory Control System. Let us first set an idea of the Inventory Control System. It is the system in which you can manage the stock of the products that a company sells. Basically, this system is stock oriented where it makes sure that the quantity-in-stock does not reach the danger level (Qty-ordered>Qty-in-stock). In any system when we reach this level, we place a new order. To avoid this situation, when in our system Qty-in-stock reaches a minimum level called the Reorder-level then a new order is placed. Here, in this case study, you will see various diagrams.
40

SUPPLIER Supplier-id Supp-name Supp-address Supp-city Supp-state Supp-pincode Supp-status Supp-Contact No1 Supp-phone 2 ADD MODIFY DELETE VIEW

CUSTOMER Customer-id Cust-name Cust-address Cust-city Cust-state Cust-pincode Cust-contact-no ADD MODIFY DELETE VIEW

Case Study: Inventory Control System

Figure 1: Class diagram represents the static structure of a System

You know that a class is represented in a box like Figure which can have at the most three regions. Class Name List of Attributes List of Operations/Methods
PRODUCTS Product-id Name-of-product Category-id Description price Qty-in-stock Danger-level Last-modification-date Manufacturing-date ADD MODIFY DELETE VIEW Class Name ORDER Order-id Description No. of items product-id order date NEW () EXISTING ()

Attributes/properties

Class Methods

INVOICE Invoice-no Invoice-date Customer-id Supplier-id Payment-status Generate () View () Receipt-no Sale-of- sale Qty-sold

SALE

Detailed Item Sale () Daily Report Sale () Generate () View ()

Figure 2: Class diagram

3.3 OBJECT DIAGRAM


Object Diagram is an instance of a class. It describes the static structure of a system at a particular time and are used to test the accuracy of classes.

41

Implementation Enter Product Details

Generate Report

Prod. No PRODUCT Bills of Material INVOICE


SUPPLIER

Invoice No.

Order by by NEW New realise EXISTING Old Cust Code


CUSTOMER

Order- no

Name address

Places an order

ORDER

details

Update Identifies

details Validation Order Validate Order

Order received Update Stock Qty-Stock Updates Files

Order-no Cost-no Prod-no

Dispatch Order Order Details

Figure 3: Object Diagram

3.4 GENERALIZATION AND ASSOCIATION DIAGRAM


Generalisation: This is another name for inheritance, or an is a relationship. It refers to a relationship between two classes where one class is a specialized version of another.
42

Super Type

Case Study: Inventory Control System

Sub Type 1
CUSTOMER Name: string

Sub Type 2

Credit ()

Regular Customer PRODUCT

Customer

New Product

Existing Product

Figure 4: Generalisation of customer and product

Association: This represents static relationship between classes. Roles represent the way the two classes see each other.
name

Class A 1 role ORDER Date-of order: date Order-no n n

Class B n role CUSTOMER 1 Customer details m n SUPPLIER m Supplier Details

Figure 5: Association of Order and customer

Aggregation: This denotes a strong ownership between class A, the whole, and class B, and its part. Hollow Diamond Filled Diamond
PRODUCT

Simple Aggregation Strong Aggregation


INVOICE CUSTOMER

ORDER

ORDER Figure 6: Aggregation

SUPPLIER

Ternary Association for Customer Supplier


CUSTOMER SUPPLIER

PRODUCT

Figure 7: Ternary association

43

Implementation

3.5 COLLABORATION DIAGRAM


This represents the interactions between objects as a series of sequenced messages. Collaboration diagrams describe both the static structure and the dynamic behaviour of a system.

Representation
Object: Class 1.2: [Condition] Message

1. Message 2. Message 3. Message

Object: Class

Object: Class

Actor

2.3 [Condition] Message Object: Class

Figure 8 a: Collaboration diagram for inventory control system

: SUPPLIER SUPPLIER 1 places an order 2.0 [SUPPLIER] Invoice [In Stock] : ORDER Delivery new () Customer New product 1 [In order] 1.1 : STOCK 3.0

: PRODUCT

Figure 8 b: Collaboration diagram for the inventory control system

3.6 ACTIVITY DIAGRAM AND EVENTS


STATECHART DIAGRAM This describes the dynamic behaviour of a system in response to external stimuli Basically, states are triggered by specific events. Representation:
Initial state

State
Final state

event/action

Activity Diagram
This illustrates the dynamic nature of a system by modeling the flow of control from activity to activity, or you can say operation on some class that results in a change in the state of the system.
44

Basically, this shows the workflow model, or business process and the internal operation
: Class

Case Study: Inventory Control System

Activity

Activity : Class

Figure 9: Activity flow

Synchronization and Splitting of Control A short heavy bar with two transitions entering it represents a synchronization of Control. Splitting of Control that creates multiple states.

Synchronization

Splitting of Control

Demand Occurred [Valid]


[Valid demand]

Check QTY-in-stock Cancel Demand Validate the Order Place the Order [else]

[Rush order] Reverse Order


Overnight Delivery

Regular Delivery

Demand Occurred

Payment Made

Figure 10: Activity diagram

Events
Actions taken in Inventory Control System: 1) 2) 3) 4) 5) Order is placed by the CUSTOMER Order is received by the SUPPLIER Checking of Quantity-in-Stock and Reorder-level Checking of Inventory Status Generating Bills of Material
45

Implementation

6) 7)

Generating the INVOICE VOUCHER Updating Inventory Status File

Main screen Do: display Customer/Supplier

Select Order

Do: Place the Order

Validation

Do: Verify the Order

Order Rejected Order OK Sector the Order

Rejected Order Do: reject the Order

Do: check min. Qty-in-stock

Cancel Do: cancel the Order

Min Qty >qty-in-stock Reorder Level Display Do: finish process Do: Display Bad Message Generation Do: Generate INVOICE

Update Do: Update Inventory Status File

Generate Do: Generate Bills of Material (BOM)

Figure 11: State diagram

46

Place an Order <<uses>> <<uses>>

<<uses>>

Generate INVOICE <<extends>>

Case Study: Inventory Control System

<<extends>>

Generate Receipt

Update Inventory Status File

Invoice of an item for Customer

Invoice of the item for Supplier

Receipt of an item for Customer

Receipt for Supplier Place an Order <<uses>> <<uses>> <<uses>>

Validate the order

Check Qty-in-stock

Figure 12: Adding details

Data Flow Diagram for System


Order details Order Master File

Places CUSTOMER demand

1.0 Places an order

Check

1.0 Validate the order Validation Order

Invalid 1.2 2.0 Display error Msg Order Check Reorder level

8.0 Generate Invoice Voucher

Validated ROL OK Qty-in-stock

2.0 Valid ROL & Qty-instock

trans details Transaction File

4.0 Generate Bills of Material

2.1 Reject the Order


5.0 Inventory File Update Inventory Status

Figure 13: Data flow diagram

47

Implementation

3.7 USE CASE DIAGRAM


A uses relationship indicates that the use case is needed by another in order to perform a task An extends relationship indicates alternative options under a certain use case. Use case diagrams model the functionality of a system using actors and use cases. Use cases are services or functions provided by the system to its users.

Use Case

Use Case (Actor)

Use Case

Figure 14: Use Case diagram

For Inventory Control System the initial design is:


SUB DIAGRAM INVENTORY CONTROL SYSTEM

Place an Order Place an Order <<uses>> Generate INVOICE <<uses>> <<uses>>

Actor (Customer)

Update Inventory Status File

Generate INVOICE Update Inventory Status File

Generate BOM

Generate BOM

Figure 15: Initial design of the Inventory Control system

48

USER INTERFACE
Run Program Interactive Display Operate enter Display Menu Screen do: show Customer button Select Set supplier & Customer code
Display Order Screen do: show order details

Case Study: Inventory Control System


Power on Load Standard Program

Display Supplier Screen Do: show supplier

Run entries are set

Run Program

Set upon Order

HOLD

60 Sec without input Setup Set Qty-in-stock Set Order Qty Set Program

Set Qty-in-stock

Set Order Qty

To View

Generating report mode

Generate Bills of Material entry Report

Run Button

Generate Invoice Voucher

Press

Invoice Card Button

Generate Inventory Status Report

Press

Report Button

Figure 16: User interface

3.8 DEPLOYMENT DIAGRAM


Deployment diagram: This shows the hardware for your system, the software that is installed on that hardware, and the middleware that is used to connect the machines to one another.

49

Implementation

Deployment diagrams depicts the physical resources in a system including nodes, components and connections, where a node is a physical resource that executes code components.

Node Component

Figure 17: Deployment

Web Server INVENTORY CONTROL SYSTEM <<JSPs>>


CUSTOMER

<<JDBC>> JDBC

<<Device>> DB Server
Inventory DB <<databases>>

SUPPLIER

PRODUCTS

{order=order}

<<Deployment Space.>> Placing of Order Execution: thread Nested Transaction: True <<EJBs>> Servlets

Inventory Control Series <<Web Services>>

Web Server
<<JDBC>>

Inventory Control War

<<Device>> :App Server : EJB Container customes. ear supplier. ear product. ear order..xml <<deployment space>> Inventory gmt. jar

<<JDBC>> Inventory DB

Figure 18: Deployment diagram

50

3.9 SUMMARY
In this unit different diagram are design to represent OOM of inventory control system. These diagrams are: Class diagram Object diagram Generalization and association Collaboration diagram Activity diagram State diagram Dataflow diagram Use case diagram Use Interface and Deployment Diagram.

Case Study: Inventory Control System

51

You might also like