Membangun use case model, merupakan salah satu kompetensi yang HARUS dikuasai oleh seorang software engineers. Apalagi saat menggunakan pendekatan model driven engineering dan membangun aplikasi berorientasi object, maka kemampuan membuat use case model survey, menjadi sangat krusial. Tentu saja, dengan melatih diri berulang-ulang, maka kompetensi membuat use case model survey akan makin baik.
Berikut saya berikan sebuah contoh, membuat use case model pada aplikasi tes online. Langkah penyelesaiannya adalah 1.1 Membuat deskripsi masalah yang akan diselesaikan; 1.2 Membuat model penyelesaian masalah. Kemudian melakukan 1.3 Requirements Capturing. Berikut adalah penjelesan detailnya:
1.1 Problem description
This case study comprises an electronic examining system. A teacher makes use of the system to give an examination to her/his students. We assume that creating an examination is a separate task performed out of the scope of the examining system. This system should be made available on the web, so that both the teacher and the students have remote access to it.
A teacher creates a test and stores this test into a test repository. Afterwards the teacher can assign this test to a group of students. There can be different types of tests but all of them must have a deadline defined by the teacher. So, for example the teacher may propose an examination in which the students are requested to write an essay about a certain subject or to solve some questions. The former activity may take several days to be completed while the latter may take only a limited number of minutes. The teacher also evaluates a student’s test answer by attaching comments and grading it.
When a student access the system, this student can consult his/her personal profile and do a test. A student personal profile contains his/her personal information, the list of tests to be done and the answers, grades and comments of completed tests. A student does a test by submitting the answers for this test. Once an answer is submitted it can not be resubmitted. All the student personal profiles are stored in a profile repository, however the access of a student is limited to his/her personal profile.
1.2 Problem modelling
This section reports the results of case study modelling activities. Each of the following subsections presents some of the results of these activities, viz., requirements capturing and analysis. The complete UML documentation of this case study can be found in Fig below. The development of this case study was performed making use of Rational Rose as a modelling support tool.
1.3 Requirements capturing
The requirements of the electronic examining system were captured by means of a use case diagram according to the following steps:
1. Identification of the actors;
2. Identification of the use cases;
3. Description of each use case.
1) Process Identification of the Actors
The identification of the actors of the system was straightforward. We simply identified the roles of the potential users of the system. The identified actors are the following:
• Student, who is a person who takes exams and consults some personal and test related information that are stored in his/her profile. The student has limited access rights to the system;
• Teacher, who is a person that assigns tests to groups of students and grade the assigned tests. The teacher has full rights to the system.
2) Process Identification of the use cases
The identification of the use cases was more complex. As a rule of thumb to identify a use case we considered the following criteria: a use case should represent a sequence of related actions that provide some functionality to the actor when successfully executed. Whenever a variation on a normal behaviour or a repetition of a separate use case were identified, the extends and uses relationships between use cases were used.
The identified use cases are the following:
• Access Student Profile, which is used to access the student profiles. All student profiles are kept in a profile repository ordered according to the student groups that the student belongs. The teacher reads and writes the student profile, while the student reads the student profile. The student can write to his/her profile only the test results.
• Access Test Repository, which is used to access the test repository. The teacher can read and write to the test repository, while the student can read from the test repository only the tests that are assigned to his/her profile.
• Assign Test, which is used to select a test from the test repository and assign the selected test to a group of students.
• Consult Profile, which is used to consult a student personal profile. The student profile contains the student personal information, the tests to be done, the test answers and the grades received so far. The student profiles are stored in a profile repository. A student has access rights only to his/her personal profile.
• Do Test, which is used to do a test. The student selects one of the tests from his/her profile. The student retrieves this test from the test repository. Then, the student does the test and submits the test answers, which are stored in his/her profile.
• Evaluate Test, which is used to evaluate a performed test. The evaluation of a test consists of making comments concerning the answers provided and grading the test. The teacher first selects a test to be evaluated and then retrieves from the student profiles some or all the answers provided for that test.
• Register Test, which is used to register and store one test in the test repository.
Each use case was described briefly, by means of few sentences that summarises the actions (see previous use case descriptions), and in a step-by-step manner, by means of a detailed description of what the system needs to do when interacting with its actors.
Detailed Use cases Description
1. Access Student Profile
This use case is used to access the student profiles All student profiles are kept in a profile repository ordered according to the student groups that the student belongs. The teacher reads and writes the student profile, while the student reads the student profile. The student can write to his/her profile only the test results.
----------------------------------------------
Detailed use case description (I):
1 - Teacher assigns a test to group of students.
Detailed use case description (II):
1 - Teacher retrieves a student test answer
2 - Teacher adds a comment to the test answer.
3 - Teacher grades the test answer.
PS: 2 is optional. 1/2/3 can be executed in any order.
Detailed use case description (III):
1 - Student browses his/her personal information.
2 - Student browses his/her test list.
3 - Student browses his/her grade list.
4 - Student browses his/her test comments.
PS: 1/2/3/4 can be executed in any order.
Detailed use case description (IV):
1 - Student selects a test to do.
2 - Student does a test, storing the test result into his/her personal profile.
2. Access Test Repository
This use case is used to access the test repository. The teacher can read and write to the test repository, while the student can read from the test repository only the tests that are assigned to his/her profile.
----------------------------------------------
Detailed use case description (I):
1 - Teacher stores a test into the test repository.
Detailed use case description (II):
1 - Teacher browses the tests available in the test repository.
Detailed use case description (III):
1 - Teacher retrieves a test from the test repository.
Detailed use case description (IV):
1 - Student reads a test from the test repository with restrictions.
3. Assign Test
This use case is used to select a test from the test repository and assign the selected test to a group of students.
---------------------------------------------
Detailed use case description:
1 - Teacher browses test list/repository
2 - Teacher select a test and assign it to a group of students. The selected test is added to the test list of the group of students.
4.Consult Profile
This use case is used to consult a student personal profile. The student profile contains the student personal information, the tests to be done, the test answers and the grades received so far. The student profiles are stored in a profile repository. A student has access rights only to his/her personal profile.
-------------------------------------------
Detailed description:
1 - Student browses his/her personal information.
2 - Student browses his/her assigned test.
3 - Student browses his/her grades.
4 - Student browses his/her test comments.
PS: 1/2/3/4 can be executed in any order.
5. Do Test
This use case is used to do a test. The student selects one of the tests from his/her profile. The student retrieves this test from the test repository. Then, the student does the test and submits the test answers, which are stored in his/her profile.
----------------------------------------------
Detailed use case description:
1 - Student selects a test from the test list.
2 - Selected test is loaded from the test repository.
3 - Student does the test. Test answers are stored stored in the student profile.
6. Evaluate Test
This use case is used to evaluate a performed test. The evaluation of a test consists of making comments concerning the answers provided and grading the test. The teacher first selects a test to be evaluated and then retrieves from the student profiles some or all the answers provided for that test.
----------------------------------------------
Detailed description:
1 - Teacher retrieves the test from the test repository.
2 - Teacher retrieves student test answers from the profile repository.
3 - Teacher adds comment to the student test
4 - Teacher grades the student test
PS: 3 is optional
7. Register Test
This use case is used to register and store a test into the test repository.
--------------------------------------------
Detailed use case description:
1 - Teacher registers a test to the test repository. The test is stored into the test repositor.
Gambar Use Case dari Studi Kasus diatas adalah ...