Object-oriented System Design and analysis topic _ Business Event Analysis

Source: Internet
Author: User

PS; this part of content is the first touch. But according to the previous topic <3>, it is the basis of the design use case diagram. After the requirement is obtained, it is used for requirement analysis.

 

 

 

1. concepts related to Event Analysis

Event Analysis starts the object-oriented development process and serves as the basis for subsequent model development. It is a powerful technology that determines the system functions required by users. Event Analysis includes some basic concepts: events, event streams, and data streams.

1. Events

An event occurs at a specific time and starts or triggers a system preset response. Events are classified into three types: external, internal, and scheduled. An external event occurs outside the system boundary. For example, readers borrow books, customers withdraw money, and students choose courses.

An internal event occurs within the system boundary. For example, an internal event is triggered when the number of items in stock is lower than the set point. Internal events are important in real-time systems and coordination systems involving the dynamic behavior of objects.

Scheduled events are scheduled events. The most common scheduled event is the event that triggers periodic output. For example, if an employee is paid on the third day of each month, the weekly sales report is reported to the manager before nine o'clock A.M. every Monday.

2. event stream

Event streams are information flows that do not contain detailed feature values related to applications. It only notifies the System of the occurrence of a specific event and triggers the system response. All necessary data required for the system response has been stored in the system.

Scheduled events are always accompanied by event streams. For example, if the scheduled event "it is time to generate the customer's consumption Bill", the data required to generate the customer's consumption bill is already in the system and no external input is required.

3. Data Stream

Data Stream inclusion and ApplicationProgramRelated Data Elements with feature values describing event details.

For example, if a customer withdraws money from a bank, the withdrawal request includes data such as the account, withdrawal date, and withdrawal amount. Airline ticket booking requests include: Passenger Name, ride date, flight number, seat number, service level, route mileage, and other data.

Data Stream has two functions in event analysis: its arrival triggers the system response; its data is necessary for the system to generate the required response. The data stream generated by the system response can contain only one or two data items, or a complex report containing detailed data items.

PS: data flow charts are similar to those in structured design.

 

  2 principle of Business Event Analysis 1. event-driven principle

To understand system behavior in the form of events, the "stimulus-response" approach is adopted. The basic behavior of the event-driven system is as follows:

(1) The system waits idle until an event is triggered;

(2) The system makes a complete response when an event occurs;

(3) After the response is complete, the system continues to wait for other events.

Take the library self-service query terminal that provides collection Literature Query as an example. The query terminal waits for the reader to enter the query conditions in the preset location of the Library. The reader queries by the query conditions and the query terminal outputs the query results.

From the perspective of event analysis, the system is like a self-service query terminal, waiting for the input of query conditions or triggering to execute preset actions. To respond to events, some objects in the system or system must be able to identify events. Generates an event stream to notify the system of a specific event. For external events, messages that enter the system must contain specific data to make the system respond correctly.

Depending on the purpose of the analyst and the system development stage, the event can be described in different scales and levels of detail. For example, "customer withdrawal" is a system-level high-level and large-scale event, and "input withdrawal amount" (the customer presses the key on the ATM) is a low-level and small-scope event. System-level high-level events generally contain multiple low-level events. When studying system requirements, we mainly research events at the overall level of the system. These system-level events are called business events.

2. "stimulus-response"

Business event analysis: the information processing system adopts the "stimulus-response" viewpoint. Stimulus is the input of the system to notify the message or signal of an event in the system environment. Some responses are system outputs that contain preset messages or signals, while others store data in the system's internal memory. Figure 1 shows the external events from the "stimulus-response" perspective.

Figure 1 external events and their components

System input and output are the only way for the system to communicate with its environment. Here we think of the system as a black box to hide its internal events. The only way for the system to know that an event occurs in its environment is to perceive it by receiving a message containing the necessary information of the event. The only way for external events to know the system response is to receive messages from inside the black box. The value of the stimulus and response with the message function lies in the information it transmits. These messages can be classified into event streams or data streams.

An event is a whole, and an event analysis should focus on the whole, not all parts. An event is different from an event component. system input, system action or action, and system output are not components of an event.

Based on the "stimulus-response" perspective, to get a precise understanding of user needs, you need to determine the following information for business event analysis:

(1) All events to be responded by the system;

(2) stimulation associated with each event (system input, event stream or data stream );

(3) required response (system output );

(4) actions or actions required to respond to each stimulus.

3. Business Event Analysis Method 1. Describe business events

During event analysis, you must use a precise language to determine and describe business events. You can use phrases to describe events for a clear understanding. The following describes specific styles for each type of event (focusing on external events and scheduled events.

(1) Describe external business events

The external event description uses a complete active voice sentence.

For example, students query scores, customers withdraw money from their bank accounts, and customers purchase goods.

When an external event is specified, the subject of the sentence indicates the system in the person, organization, or environment. The predicate of the sentence usually indicates the system input-the message notifying the system event.

(2) Describe timed business events

The description of scheduled events uses the phrase "...... The time is up ...... .

For example, it is time to generate the school public course schedule. This is different from "generate a school public course schedule". "generate a school public course schedule" describes the system action (what the system should do when an event occurs) rather than the event.

In this case, when a scheduled event is specified, the sentence predicates usually represent the output of the system-the message describing the system's response to the event.

2. Determine participants

A participant is a person, organization, or other system that provides system input or receives system output.

Determine the participant's needs:

(1) Find the persons, organizations, or systems in the environment that provide or receive system inputs;

(2) name the participant.

A participant's name is a noun or noun phrase that describes the participant. The student who sends the query request in the "Student query score" event is a student.

3. Determine System Input and Output

System input is a message that notifies the System of the event content and must respond to the system. System output is a message generated by the system to respond to events.

Determine System input and output requirements:

(1) Find the information associated with the event to enter or exit the system;

(2) name the system input and output.

Input and Output names use nouns (or phrases) that can describe information contained in input or output ). It mainly focuses on input and output information, rather than actions. In the Score Management System, the query request contains the student ID and course information.

In general, both input and output are treated as data streams. In an object-oriented system, input is represented by messages, and output can be represented by messages or output objects. Note that sometimes external events only store data in the system and do not generate corresponding output.

4. Determine System actions

A system action is an action or action that must be performed when an event is responded.

Determine System action requirements:

(1) Find the actions or actions that must be performed in response to the event;

(2) name the system action.

The action name is the verb phrase contained in the event description. The system action in the "student borrowing" event is to borrow books.

It is helpful to list events, participants, system inputs and outputs, and system actions in the event table.

4. business event analysis example

In order to thoroughly understand the process of using the event analysis method to establish the event model, the following uses a public elective system of a university as an example to analyze the event.

  1. Background of University Public Course Selection

According to the time limit of the Academic Affairs Office, the plan list of public colleges and universities in each semester is formulated before the student selection date. According to the time limit, each department in the university must submit a list of public education class plans for this semester to the academic affairs office. The information in these lists are combined to form the final list of public school class plans. The school public school class plan list is distributed to each department office and each professor, and students can see it in the school bulletin board.

During the course selection, students send requests to the class they want to select (by selecting a course ). Each class request contains the student's student ID and the student's public class number (Note: A course can be divided into multiple classes ). If this class is not available, students can try to select other classes of the same class. When the students select as many classes as possible (maximum allowed), the students obtain a printed list of classes. This list shows all the classes successfully selected by the students.

Each class roster listing the names and student IDs of included students is printed and sent to each class professor.

2. event model of the Course Selection System for Public colleges and universities

Based on the background description, You need to analyze business events to generate an event table.

(1) determine business events

The course selection process includes several activities: first, the Department needs to develop and list the Public Course course plans for the Academic Affairs Office of the school (number of courses open, each course is divided into several classes, information about the number of students in each class, the time, place, and instructors of the course). Then, the Office of Academic Affairs of the school collects statistics, checks and approves the plan, and releases the list of public school class plans, the faculty, professors, and students can see that the students select classes based on the course selection rules of the public school, and obtain the list of all successfully selected classes. Finally, the Academic Affairs Office selects the courses based on the course selection conditions, print the roster of each class to the corresponding course Professor. After the overall analysis, we determine four required business events and describe them using the recommendation format:

1) is the list of submitted public class plans. This is an external event and the system will not respond until it receives the information submitted by the system in the class plan. Each department is separately handed over to the Department's public class plan, and the system will save the information for future use.

2) It's time to generate the school's public school class plan list. This is a scheduled event. When all the departments submit the required information, the list of school public education class plans can be generated.

3) Students select a class. This is an external event. The system selects the maximum allowed class requests for each student and generates a list of classes for each student. This information is recorded in the system. The system can immediately generate a list of classes for students after completing the class selection, and does not need to wait until all the students have completed the selection.

4) It's time to generate the class roster. This is a scheduled event. When all the students have completed the class selection, the system generates a class roster with the stored data. In fact, the class roster can be generated immediately after a certain class is fully selected, which does not prevent the determination of the event type.

(2) Determine participants

In this process, you need to know who provides the system input or gets the output from the system.

In the external event "submitted by the Department to the public class plan list", we can see that the Department provides the information of the class plans to be provided by each department to the public elective system of colleges and universities. Is a participant in this event. The subject of the sentence described in this event is "system ". If an external event is described properly, the subject is generally the participant that provides the system input. In the "student select class" event, the student is the participant who provides the class selection information. "It's time to generate the school's public school class plan list" and "it's time to generate the class roster" are triggered by the time. The participants do not need to provide external input.

Analyze the participants who receive the output from the system. The event "submitted to the public worker class plan list" only saves the information and does not output it. The event "takes time to generate the school public worker class plan list, the students, professors, and students received a list of public school class plans. In the "student select class" incident, the students received a list of classes and the "time to generate the class roster" incident, the class roster is available to professors.

Among the four events, three participants are identified: department, student, and Professor.

(3) Determine System Input and Output

Determine and name the input and output of the system based on the business event description. There are two inputs in the public elective system of colleges and universities: the list of public class plans (the "List of submitted public class plans "), select class request (Event "student select class "). Three outputs: The school public school class plan list (the event is "Time to generate the school public school class plan List"), the student class list (the event "student select class "), class Roster (the event "it's time to generate the class roster ").

(4) Determine System actions

There are four business events in the Course Selection System of Public colleges and universities. One action or action that the system must perform must respond to these four events. The four actions are as follows: Submit the public class plan list (the event "system submits the public class plan List "), generate a list of school public school class plans (the event is "Time to generate the school public school class plan List"), select a class (the event "select a class for students "), generate the class roster (the event "it's time to generate the class roster ").

Use the event table to represent the event model based on the business event analysis results. For each event, the event table contains the relevant participants, input and output, and system actions. Table 1 shows the event table of the Course Selection System for Public colleges and universities.

Table 1 events of the Course Selection System for Public colleges and universities

Event ID

Event Description

System input

Provide input participants

System action

System output

Receiving output participants

1.

List of submitted public worker class plans

Department Public worker class plan list

System

List of submitted public worker class plans

   

2.

It's time to generate the school public school class plan list

   

Generate a list of public school class plans

School public school class plan list

Student
System
Professor

3.

Select a class

Select class request

Student

Select class

Student class list

Student

4.

It's time to generate the class roster.

   

Generate a class roster

Class Roster

Professor

in business event analysis, the basic model of system implementation technology is ignored. Analysts cannot assume the implementation technology that the designer chooses, the requirement must be presented in a way that allows multiple implementations. In business event analysis, the system has perfect internal technology. Messages flow in the system instantly, and the system can respond immediately and without errors. The stored data is not accidentally stored, these assumptions help analysts to model events, focus on the nature, and ignore secondary details.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.