Академический Документы
Профессиональный Документы
Культура Документы
UML
, .
1.1. UML
UML (Unified Modeling
Language) ,
80- 90- . UML
1994 .,
Booch [-1999] OMT (Object Modeling Technique)
Rational Software. 1995 .
, Unified
Method, 0.8. 1995 .
OOSE (Object-Oriented Software Engineering) .
, UML
, , .
UML ,
OMG (Object Management Group),
. UML
(Microsoft,
IBM, Hewlett-Packard, Oracle, Sybase .). ,
CASE-, Rational Software (Rational
Rose), UML (Paradigm Plus (CA), System
Architect (Popkin Software), Microsoft Visual Modeler .).
UML http://www.omg.org
http://www.rational.com. UML
[-1999],
. ,
[-2000], [-2000] [-2001].
1.2. UML
UML ,
, ,
- ,
. UML
. UML 1.1,
OMG
1997 .,
:
(use case diagrams)
-
);
(class diagrams)
;
(behavior diagrams):
(interaction diagrams):
(sequence diagrams)
(collaboration diagrams)
(statechart
diagrams)
(activity
diagrams)
, ;
(implementation diagrams):
(component
diagrams)
() ;
(deployment
diagrams)
.
1.3.
(use
case)
,
.
(), ,
( ).
.
, .
(actor) ,
. ,
. ,
,
,
.
,
.
, , , .
, -
.
()
. . 1.1
(Automated Teller Machine, ATM).
, ,
.
:
. ,
: , ,
5
, ,
.
. 1.1.
.
. ,
, ,
(stakeholders)
. ,
.
,
. , ,
.
,
. ,
:
6
, , ,
.
.
,
.
,
,
.
.
, ,
.
,
.
.
.
,
.
(,
), ( )
. ,
:
.
. ,
.
( )
.
,
, .
7
.
. , ,
.
. ,
, -
. -
, ,
, , .
,
.
,
. , ,
.
, (flow of events).
,
.
, , .
,
. , ,
. :
;
(pre-conditions);
;
(
);
(post-conditions).
.
, . ,
8
:
.
,
,
. ,
,
.
.
,
. ,
, . ,
,
.
.
,
.
, , ,
.
:
;
;
, , ;
(
);
;
.
,
:
1. ,
.
2.
.
3. .
4. . ,
1.
5. :
;
;
.
6. .
7. , .
8. .
9. , .
, 2.
, 1.
10. .
11. .
12. .
13. .
14. .
1.
.
1. ,
.
2. .
3. .
10
2.
.
1. , .
2. .
3. .
1. .
1. ,
.
2. .
, ,
.
3. .
4. .
,
. ,
-
. .
,
.
, ,
, .
.
UML
.
(communication), (include),
(extend) (generalization).
. UML
( ).
, .
11
,
- ,
.
.
()
,
.
.
.
.
UML
, . 1.2.
<<extend>>
<<include>>
. 1.2.
,
. ,
: .
, . 1.3.
12
. 1.3.
.
, ,
,
.
, .
.
, ,
.
1.4.
(interaction diagrams)
.
,
.
,
.
(message) ,
-
.
(informative) ,
-
.
13
- (interrogative) ,
-.
(imperative) ,
- .
:
(sequence diagrams)
(collaboration diagrams).
1.4.1.
,
. ,
, , ,
,
.
(
,
) . 1.4.
.
;
. ,
,
.
,
.
,
. (lifeline) .
.
14
1:
ATM
2:
3:
4: PIN-
5: PIN- (1234)
6:
7:
8: PIN-
9:
10:
( )
11:
12: (20 )
13: (20 .)
14: (20 .)
15: (20 .)
16: (20 )
17: (20 .)
18:
. 1.4.
15
. ,
.
;
, , ,
- (self-delegation) ,
,
.
.
.
.
,
.
. , ,
, ,
. , ,
(control objects).
.
1.4.2.
.
,
(collaborations)
.
,
. . 1.5
, , .
, ,
,
- .
, , .
16
2:
1:
18:
5: PIN- (1234)
10: ( )
12: (20 .)
3:
4: PIN-
9:
11:
ATM
17: (20 .)
ATM
7:
8: PIN-
14: (20 .)
6:
13: (20 .)
15: (20 .)
16: (20 .)
. 1.5. ,
-
.
, .
,
, ,
.
, , .
1.5.
1.5.1.
, .
,
, .
17
. 1.6.
<<Entity>>
Card Reader
- Card Number : integer
<<Boundary>>
ATM Screen
+ Prompt() : integer
+ AcceptInput(Input : Integer) : integer
0..1
0..1
0..1
0..n
<<Entity>>
Account
- Account Number : integer
- PIN : integer
- Balance : long
<<Boundary>>
Cash Dispenser
- Cash Balance : long
1
+ Open() : integer
+ Withdraw Funds(Amount : long) : integer
- Deduct Funds(Amount : long) : integer
- Verify Funds() : integer
. 1.6.
,
.
: Card Reader1 (
), Account (), ATM Screen ( ) Cash Dispenser
( ).
, .
, .
, (, ).
1
,
. , ,
. . , CASE-
.
18
,
-.
,
. ,
SecurityManager ( ),
, . TransactionManager (
) ,
.
,
,
.
.
1.5.3.
, ,
.
. -,
. , ,
..
,
.
. , Security ()
, .
Employee Maintenance (
), Reporting ( ) Error Handling
( ).
.
,
.
, . ,
UML, .
20
,
. ,
(. 1.7) ,
. ,
,
.
Entities
Boundaries
Control
. 1.7.
,
. ,
: ;
;
. ,
, , .
,
,
, , ,
.
21
.
. ,
,
4, .
1.5.4.
, . ,
Company () Name (),
Address () NumberOfEmployees ( ).
,
. ,
.
(attribute visibility).
. (. 1.8).
Employee Address Company:
Public (, ). ,
.
.
Company Address
Employee. UML
+ .
Private (, ).
. Employee
Address , Company
, . ,
Employee
,
.
UML.
Protected ().
. ,
22
. ,
HourlyEmp SalariedEmp,
Employee.
Address Employee,
HourlyEmp SalariedEmp, Company. UML
# .
Package or Implementation (). ,
, . ,
Address .
Company,
.
.
Employee
-Employee ID : Integer = 0
#SSN : String
#Salary : float
+Address : String
+City : String
+State : String
+Zip Code : long
+Departament : String
+Hire()
+Fire()
+Promote()
+Demote()
+Transfer()
. 1.8.
,
. .
,
.
,
.
.
23
1.5.5.
.
, .
, .
.
,
. ,
,
.
UML :
(1 : 1, 2 :
2, ...) :
.
(implementor operations)
-. ,
. , , ,
.
.
.
,
, ,
.
,
, -
.
(manager operations)
.
.
24
.
,
. (access operations).
, , Salary Employee.
, .
Employee
GetSalary SetSalary. , ,
.
Salary . SetSalary
,
Salary.
, ,
.
, ,
. Get Set
( )
.
(helper operations)
, ,
.
.
, :
1.
.
.
.
2. .
.
3. . ,
,
Get Set.
25
1.5.6.
. ,
. ,
, .
,
: , , .
(association) .
.
NewClass
NewClass2
. 1.9.
, ,
. UML
.
,
.
,
.
, ,
.
, .
.
,
.
26
(dependency)
, ,
, .
, .
NewClass
NewClass2
. 1.10.
. ,
, . , ++
#include.
(aggregations)
. . ,
, ,
.
,
. .
, :
Whole
Part
. 1.11.
UML
27
, -
, , , ,
: .
.
, ,
1..1; ,
,
(, , ).
(generalization)
.
. ,
. UML
- :
Student
(from Design Model)
- name
- address
- studentID
+ // get tuition()
+ // add schedule()
+ // delete schedule()
FulltimeStudent
ParttimeStudent
- gradDate
- maxNumCourses
. 1.12.
28
,
, .
(multiplicity) ,
.
,
Course () Student
(). : ,
. ,
:
? ?
,
.
,
, 10 20
. ,
. 1.13.
Course
Student
0..4
10..20
. 1.13.
UML
:
0..*
1..*
0..1
1..1 ( : 1)
29
.
, ,
. , Person () Company
() .
, Person ,
? ,
employs ():
Company
Employs
Person
. 1.14.
. ,
.
.
, .
Person Company, , Person
Company.
,
, .
, , ,
. , ,
, .
:
Company
+Employer
+Employee
. 1.15.
30
Person
1.6.
,
,
.
,
.
, - ,
.
. 1.16
. ,
.
. ,
, .
(event),
.
[ ]
entry:
do:
[ exit:
]
entry:
[
30 ]
. 1.16. Account
31
,
. ,
, [
] .
(guard condition) ,
.
(start)
(stop). ,
, .
,
.
. ,
, , .
- ,
.
. , ,
,
(actions).
: ,
, , .
Account ATM.
(activity) ,
, . ,
,
. .
,
,
. ,
do () .
32
(entry action) ,
, .
, ,
, ,
. ,
, , , ,
. ,
.
,
entry () .
(exit action) . ,
. Account
, , ,
.
. , .
,
exit () .
,
. ,
account () card reader
( ). ,
^ .
Do: ^.()
, ,
,
.
. , account
33
.
.
(Transition)
. ,
.
,
.
.
, .
,
.
.
, , ,
. .
(event) ,
.
.
.
, .
. ,
RequestClosure().
. , ,
, Amount (),
.
, ,
, . ,
, .
,
, .
34
(guard conditions) ,
, .
, .
.
, .
.
,
. ,
.
(action), ,
, .
, ,
, .
, , ,
.
,
.
.
,
.
,
, .
,
^ .
,
.
35
-, .
1.7.
UML,
, ,
, , SDL
. ,
[-1999].
, ,
,
.
.
, ,
. ,
.
,
, .
:
.
, ,
.
.
(workflow)
.
,
.
36
1.8.
,
.
.
: .
( )
.
. ,
.
. 1.17
.
ATM.exe
Cash Dispenser
Card Reader
ATM Screen
Card Reader
Cash Dispenser
ATM Screen
. 1.17.
.
++.
37
.,
. , ATM screen
ATM Screen .
ATM Screen.
ATM Screen.
(package specification)
ATM Screen C++ ( .).
,
++ (
.). ATM.exe
(thread of processing).
.
,
. , Card Reader
ATM Screen. , , , Card Reader
, ATM Screen .
ATMClient.exe.
, ,
. ,
Cash Dispenser, Card Reader ATM Screen.
ATM, Account.
. 1.18.
,
, .
. ,
.
: .
,
. ,
,
.
38
. ,
.
ATMServer.exe
Account
Account
. 1.18.
1.9.
(deployment diagram)
. ,
.
,
.
, .
.
,
, (node).
. 1.19.
39
Banking Database
Server
Oracle Server
<<LAN>>
Regional
ATM Server
ATMServer.exe
Printer
<<Private Network>>
<<Private Network>>
ATMClient.exe
ATMClient.exe
. 1.19.
.
.
.
. ,
, Oracle. ,
.
,
, ,
.
40
.
.
++,
,
,
.
++.
++ .
Rational Rose
,
++.
. ,
,
.
. ,
, , ,
,
. ,
Rational Rose/++
.
CASE- Rational
Rose :
UML,
;
, , ;
.
. , ,
, .
.
.
42
Rational Suite. Rational Suite :
Rational Suite AnalystStudio
;
Rational
Suite
DevelopmentStudio
;
Rational Suite TestStudio ,
;
Rational Suite Enterprise
,
,
.
Rational Suite, Rational Rose,
:
Rational Requisite Pro ,
. ,
,
,
,
,
;
Rational ClearCase ;
Rational SoDA
;
Rational ClearQuest
e-mail Web;
Rational TeamTest
;
Rational
Robot
;
Rational Purify
;
43
Rational PureCoverage ,
;
Rational Quantify
, ;
Rational
Suite
PerformanceStudio
- Web-.
Rational Rose
.
.
.
. Rational Rose
: IBM PC (Windows 95/98/NT), Sun SPARCstations
(UNIX, Solaris, SunOS), Hewlett-Packard (HP UX), IBM RS/6000 (AIX).
(documentation
window)
;
(toolbars)
;
(diagram window)
UML;
(log)
.
. 2.1 Rose.
44
,
. , ,
, ,
. :
( ,
, , , ..);
;
;
;
;
;
;
;
;
.
45
(view):
, ,
.
. 2.2.2.
.
, .
, .
+ .
Rose.
, .
,
,
,
. ,
Rose.
Rose
.
: .
, ,
.
UML.
. Tools > Options,
Toolbars.
(
):
1. Tools > Options.
2. Toolbars.
46
3.
, ( )
Show Standard ToolBar ( Show Diagram ToolBar)
:
1. .
2. Use Large Buttons
( )
:
1. .
2. Customize ()
3. ,
Add ()
Remove (), . 2.2.
. 2.2. .
,
UML . Rose
. ,
Rose
.
.
47
. ,
, .
, .
2.2.2. Rose
Rose (views)
, ,
.
.
,
.
,
.
. . 2.3 ,
Rose.
:
.
.
,
( ),
.
,
Rose. ,
,
. (. 2.3) Microsoft Word.
.
,
/ .
48
, /
.
. 2.3. .
, . 2.4,
, ,
.
.
, , ,
.
.
:
.
. ,
,
.
,
,
.
.
49
, .
. 2.4. .
:
, .
.
, .
Rose .
,
.
:
, (threads),
.
, ,
.
.
50
, ,
. , ,
- .
.
2.2.3.
Rose ,
:
;
;
;
;
;
;
.
, Tools > Options.
:
;
;
;
.
, ,
.
.
.
.
.
51
:
1. .
2. ,
- .
3. Options > Show All Attributes.
:
1. .
2. ,
- .
3. Options > Select Compartment Items.
4. Edit Compartment.
:
1. .
2. ,
- .
3. Options > Suppress Attributes.
:
1. Tools > Options.
2. Diagram.
3.
Suppress Attributes Show All Attributes.
.
.
,
.
;
.
.
.
, :
. ,
,
.
52
.
, ,
.
:
1. .
2. ,
- .
3. Options > Show All Operations.
:
1. .
2. ,
- .
3. Options > Select Compartment Items.
4. Edit Compartment.
:
1. .
2. ,
- .
3. Options > Suppress Operations.
:
1. .
2. ,
- .
3. Options > Show Operation Signature.
:
1. Tools > Options.
2. Diagram.
3.
Suppress Operations, Show All Operations Show Operation
Signatures.
:
1. .
53
2. ,
- .
3. Options > Show Visibility.
:
1. Tools > Options.
2. Diagram.
3.
Show Visibility.
Rose UML:
1. Tools > Options.
2. Notation.
3.
Visibility as Icons.
, Rose. ,
UML.
.
.
54
3.
3.1. .
-
.
,
.
, , ,
.
-
.
, ( ).
.
, .
,
, .
,
( ).
4
.
2 , -
.
10 3 ( 3,
). ,
.
, .
, ,
,
.
55
,
.
.
,
.
,
, , ,
. ,
.
3.2.
.
.
(Course Offering)
(Report Card)
(Roster)
(Schedule)
,
(
).
.
,
.
.
,
.
.
,
.
,
.
, .
,
.
56
3.3.
,
. .
, , , ,
, ,
,
.
.
,
, ,
.
Windows 95/98.
24
7 , 10%.
2000
, 500 ,
.
, ,
,
.
.
.
57
, .
3.4.
:
Student () ;
Professor () ;
Registrar ()
, , ;
Billing System ( )
;
Course Catalog ( )
, .
1. Rational Rose
:
1.
.
2. New > Actor
3.
NewClass.
UML.
4. , .
5.
coursereg(analysis) File > Save.
58
:
,
:
Login ( );
Register for Courses ( );
View Report Card ( );
Select Courses to Teach ( );
Submit Grades ( );
Maintain Professor Information ( );
Maintain Student Information ( );
Close Registration ( ).
2.
Rational Rose
:
1.
.
2. New > Use Case
3. NewUseCase
.
UML.
4. , .
59
:
. .
. 3.1.
Student
Register for Courses
Login
Course Catalog
Registrar
Close Registration
. 3.1.
.
60
Billing System
Rose
. (Main)
.
, .
:
1.
+ ,
.
2. Main, .
, [Use Case Diagram:
Use Case view / Main].
:
1.
.
2. New > Use Case Diagram.
3. , .
4. ,
.
3.
1. Main.
2.
,
.
3. Unidirectional Association (
)
.
Login
Any User.
. 3.2.
61
Student
Register for Courses
Login
Any User
Course Catalog
Registrar
Close Registration
Billing System
. 3.2.
4.
1. Register for Courses.
2.
: This use case allows a student to register
for courses in the current semester (
).
62
3. MS Word
Login ( ), Register
for Courses ( ) Close Registration
( ).
Login:
.
,
.
1. .
2. .
3. ,
.
/
,
/ ,
.
,
.
,
. .
Register for Courses:
.
( ),
63
.
.
,
.
1. ( ,
, ).
2. ,
(, ,
).
1.
.
2. 4 2
.
3. .
4. .
1. .
2.
.
3. ,
.
4. .
5. .
1. .
2. .
3. .
4. . ,
,
.
64
,
( ),
.
.
.
. :
1.
.
2. .
,
,
,
, ,
.
, ,
, .
,
. ,
, .
,
, . ,
, .
65
,
,
.
, ,
.
,
, .
.
Close Registration:
. ,
( ), .
, .
,
.
1. .
,
.
2. ,
- ,
. ,
,
.
66
3.
,
.
. ,
.
4. . -
(
, .3),
.
5.
.
.
,
,
.
.
,
. , .
,
. .
5.
1. .
2. Open Specification
67
3. .
4.
Insert File.
5. Open,
.
.
:
1. .
2. Delete.
3. , , ,
.
:
1. .
2. Edit > Delete from Model
CTRL + D.
68
3.5.
3.5.1.
:
;
;
;
().
:
.
Use-Case Realization, :
;
View Of Participating Classes (VOPC).
,
.
.
.
, ,
.
(Use-Case Realization):
( , ,
(
),
).
69
<<realizes>>
Use-Case
Realization
Use Case
. 3.3.
( ). ,
, .
. 3.4:
Student
Professor
Schedule
CourseOffering
Course
. 3.4.
6.
70
Traceabilities:
1.
.
2. New > Package
3. Design Model.
4. Use-Case Realizations, UseCase Realization Close Registration, Use-Case Realization Login
Use-Case Realization Register for Courses.
5. Use-Case Realization
Close Registration, Login Register
for Courses (
use-case realization,
).
6. Use-Case Realizations
Traceabilities
. 3.5.
<<realizes>>
<<use-case realization>>
Login
(from Use Case View)
Login
(from Use-Case Realization - Login)
<<realizes>>
<<use-case realization>>
Register for Courses
(from Use-Case Realization - Register
for Courses)
<<realizes>>
<<use-case realization>>
Close Registration
(from Use-Case Realization Close Registration)
Close Registration
(from Use Case View)
. 3.5. Traceabilities
71
Key
Abstractions:
1. Design Model.
2. New > Class.
NewClass .
3. Student.
4. Professor, Schedule, Course
CourseOffering.
5. Design Model.
6. New > Class Diagram.
7. Key Abstractions.
8. ,
.
. 3.4.
3.5.2.
,
:
1. (Boundary)
. ,
. :
, , , ),
(
, ).
2. - (Entity)
() .
-: ,
, ,
.
72
3. (Control)
.
. ,
.
,
, .
,
Register for Courses, . 3.6.
<<boundary>>
RegisterForCoursesForm
<<boundary>>
CourseCatalogSystem
<<control>>
RegistrationController
<<entity>>
Student
<<entity>>
Schedule
<<entity>>
CourseOffering
. 3.6. ,
Register for Courses
7. ,
Register for Courses,
View Of Participating Classes (VOPC)
1. Design Model.
2. New > Class.
NewClass .
3. RegisterForCoursesForm.
4.
RegisterForCoursesForm.
5. Open Specification.
73
6. Boundary .
7. CourseCatalogSystem
Boundary RegistrationController
Control.
8. Schedule, CourseOffering Student
Entity.
9. Register for
Courses Use-Case Realization Register for Courses.
10. New > Class Diagram.
11. VOPC (classes only).
12.
. 3.6.
, ,
(
).
( ),
.
. :
;
;
.
(,
).
8.
Register
for Courses. ,
. 3.7 3.11.
74
: RegisterForCoursesForm
: RegistrationController
: Student
1: // register for courses( )
2: // is registration open?( )
[ registration open ]
3: // display possible operations( )
4: // create schedule( )
5: // update schedule( )
6: // delete schedule( )
75
:Student
:RegisterForCourses
Form
:Registration
Controller
:CourseCatalog
System
1: // create schedule( )
:Schedule :Student
:Course
Catalog
1. Student .
2. RegisterForCoursesForm RegistrationController
.
3. Object Message
( ).
4. Student
RegisterForCoursesForm.
5. , : // register for courses.
6. 3 5,
, . 3.7 (
3 Message to Self).
:RegisterForCourses
Form
: Registration
Controller
: Student
1: // update schedule( )
t )
: RegisterForCourses
Form
: Registration
Controller
:Student
:Schedule
:CourseOffering
: Student
1: // delete schedule( )
78
, . 3.8 3.11. ,
. 3.11
PrimarySheduleOfferingInfo ( ,
Shedule OfferingInfo),
.
: Student
:RegisterFor
CoursesForm
:Registration
Controller
:Schedule :PrimarySchedule
OfferingInfo
: Course
Offering
:Student
1: // submit schedule( )
2: // submit schedule( )
3: // save( )
4: // submit( )
5: // is selected?( )
6: // has pre-requisites
[ is selected ]
(CourseOffering)
7: // still open?( )
8: // any conflicts?( )
[ has pre-requisites, course offering
open, and no schedule conflicts ]
9: // add student(Schedule)
10: // mark as enrolled in( )
4. ,
Anchor Notes To Item (
).
5. ,
, .
.
6. - (
. 3.7 ),
( )
.
,
. , ,
.
:
1. Text Box.
2. ,
.
3. , .
F5.
(responsibilities),
(responsibility) ,
.
.
, ,
,
80
( ).
, VOPC (classes only) (. 3.6)
8
, . 3.12.
<<control>>
RegistrationController
<<boundary>>
RegisterForCoursesForm
// submit schedule()
// display course offerings()
// update schedule()
// delete schedule()
// confirm schedule deletion()
// request schedule delete confirmation()
// display schedule()
// register for courses()
// display possible operations()
// save schedule()
// create schedule()
// select 4 primary and 2 alternate offerings()
// display blank schedule()
// update offering selections()
<<entity>>
Student
// get tuition()
// add schedule()
// get schedule()
// delete schedule()
// has pre-requisites()
<<entity>>
CourseOffering
// add student()
// remove student()
// close registration()
// get number of students()
// cancel()
// still open?()
// add professor()
// close()
// save()
<<entity>>
Schedule
// commit()
// select alternate()
// remove offering()
// level()
// cancel()
// get cost()
// delete()
// submit()
// save()
// any conflicts?()
// create with offerings()
// update with new selections()
<<boundary>>
CourseCatalogSystem
// get course offerings()
<<entity>>
PrimaryScheduleOfferingInfo
// is selected?()
// mark as enrolled in()
9.
1. Student.
2. New Attribute.
3. address
4. Enter.
5. 1 4, name studentID.
6. CourseOffering, Shedule
PrimaryScheduleOfferingInfo, . 3.13.
<<entity>
>Student
address
name
studentID
// get tuition()
// add schedule()
// get schedule()
// delete schedule()
// has pre-requisites()
<<entity>>
PrimaryScheduleOfferingInfo
grade
<<entity>>
CourseOffering
/ numStudents : Int
days : Enum
endTime : Time
number : String = "100"
startTime : Time
// add student()
// remove student()
// close registration()
// get number of students()
// cancel()
// still open?()
// add professor()
// close()
// save()
<<entity>>
Schedule
semester
// commit()
// select alternate()
// remove offering()
// level()
// cancel()
// get cost()
// delete()
// submit()
// save()
// any conflicts?()
// create with offerings()
// update with new selections()
// is selected?()
// mark as enrolled in()
. 3.13.
()
.
( ),
( ). ,
, .
, .
10.
,
Register for Courses.
82
Register for
Courses Use-Case Realization Register for Courses (. 3.14 3.16).
<<entity>>
Student
name
address
studentID 1
0..n
0..4
<<entity>> 0..n
<<entity>>
Schedule
CourseOffering
+primaryCourses
0..2
0..n
+alternateCourses
<<entity>>
FulltimeStudent
gradDate
<<entity>>
ParttimeStudent
maxNumCourses
+primaryCourses
0..n
0..n
0..4
+alternateCourses
0..2
<<entity>>
ScheduleOfferingInfo
status
// mark as selected()
// mark as cancelled()
// is selected?()
. 3.15. CourseOfferingInfo
83
<<entity>>
CourseOffering
,
Schedule CourseOffering
ScheduleOfferingInfo. ,
(status ), ,
, (grade)
.
<<control>>
<<boundary>>
RegisterForCoursesForm
1
0..n
0..1
0..1
<<entity>>
Student
1
0..1
0..1
+registrant
<<boundary>>
CourseCatalogSystem
RegistrationController
+currentSchedule
<<entity>>
Schedule
<<entity>>
PrimaryScheduleOfferingInfo
0..n
0..n
0..n
+primaryCourses
0..4
<<entity>>
FulltimeStudent
<<entity>>
ParttimeStudent
<<entity>>
CourseOffering
0..2
<<entity>>
ScheduleOfferingInfo
+alternateCourses
. 3.16. VOPC (
)
.
, .
:
1. Association.
2. .
:
1. ,
.
2. Navigable.
84
:
1. Association.
2. -
.
3. .
4. .
1. Aggregation .
2. - .
:
1. Aggregation.
2. -
.
3. .
4. .
. , ,
Employee,
.
, .
:
1. Generalization .
2. .
, ,
.
:
1. .
2. Multiplicity.
3. .
4. .
85
:
1. .
2. .
:
1. .
2. role Name.
3. .
( ):
1. .
2. Detail.
3. Link Element.
Close Registration
.
3.6.
3.6.1.
:
,
;
;
.
:
(foundation) (, ..);
(error handling classes);
;
;
.
(design classes):
86
,
;
,
.
:
, (,
);
,
;
(middleware,
COM/CORBA), ,
(, , ),
( ), .
.
:
: (- ),
.
: (
).
: , ,
, ,
.
:
(
), .
<<subsystem>>, ,
, /
,
.
87
<<subsystem proxy>>
.
,
.
:
Application Layer
( );
Business Services Layer , ( );
Middleware
Layer
.
. 3.17.
,
.
. 3.17.
88
,
:
(
<<layer>>);
Application Registration,
;
CourseCatalogSystem
( CourseCatalogSystem <<subsystem>>)
Business
Services,
CourseCatalogSystem, : External
System
Interfaces
CourseCatalogSystem ( ICourseCatalogSystem
<<Interface>>), University Artifacts -.
() CourseCatalogSystem
. 3.18 3.22.
. 3.18. CourseCatalogSystem
<<subsystem>>
CourseCatalogSystem
(from Business Services)
External System
Interfaces
(from Business Services)
University Artifacts
(from Business Services)
. 3.19.
( CourseCatalogSystem Dependencies)
89
:
1. Dependency .
2. ,
.
<<Interface>>
ICourseCatalogSystem
<<subsystem proxy>>
CourseCatalogSystem
getCourseOfferings()
initialize()
getCourseOfferings()
initialize()
DBCourseOfferring
create()
read()
initialize()
. 3.20. , (
ICourseCatalogSystem)
DBCourseOfferring
.
CourseCatalog
System Client
: CourseCatalog
System
: DBCourse
Offerring
1: getCourseOfferings(Semester)
:CourseOfferingList :CourseOffering
2: read(string)
Retrieve all available course
offerings for the current
semester
3: new( )
4: new( )
5: setData( )
6: add(CourseOffering)
. 3.21. ICourseCatalogSystem::getCourse
Offerings,
getCourseOfferings
90
CourseCatalog
System Client
: CourseCatalogSystem
1: initialize( )
: DBCourseOfferring
2: initialize( )
. 3.22. ICourseCatalogSystem:
:initialize,
initialize
3.6.2.
. :
(node) (
( ,
. .). ;
(connection) ().
: ( ).
Desktop PC
Desktop PC
<<Campus LAN>>
<<Campus LAN>>
Registration
Server
<<Campus LAN>>
<<Campus LAN>>
<<legacy>>
<<legacy>>
CourseCatalogSystem
BillingSystem
. 3.23.
91
, , ,
(peer-to-peer) ..);
;
;
;
.
. 3.24.
Desktop PC
Desktop PC
StudentApplication
RegistrarApplication
StudentApplication
RegistrarApplication
<<Campus LAN>>
<<Campus LAN>>
Registration
Server
<<Campus LAN>>
<<Campus LAN>>
CourseCatalogSystemAccess
CourseRegistrationProccess
CloseRegistrationProccess
BillingSystemAccess
<<legacy>>
<<legacy>>
CourseCatalogSystem
BillingSystem
.
3.24.
92
11.
,
Deployment View ( )
.
:
1. Processor.
2. ,
.
3. .
, .
(,
UNIX ).
.
, , .
(scheduling) ,
:
Preemptive ( ).
.
Non preemptive ( ).
. ,
.
Cyclic ().
.
, .
Executive
().
,
.
Manual (). .
:
1. .
2. General.
93
3. Stereotype.
:
1. .
2. Detail.
3. .
4. .
:
1. .
2. Show Scheduling.
:
1. Connection.
2. .
3. .
:
1. .
2. General.
3. Stereotype ().
:
1. .
2. New > Process.
3. .
:
1. .
2. Show Processes.
3.6.3.
:
(GUI Builder);
-
(
);
94
,
;
(persistent) ,
.
, ,
. ,
.
: operationName(parameter:class,):returnType.
, .
: public, private, protected.
(scope) : .
() :
,
(): attributeName:Type = Default;
,
;
: public, private, protected;
()
.
12.
Student
,
:
1. .
2. Open Specification.
3.
.
4. Initial Field ( )
.
95
. 3.25. Student
:
1. Tools > Options.
2. Notation.
3. Visibility as Icons,
Rose, ,
UML.
.
.
96
,
:
1. .
2. .
3.
.
4.
.
5. Export Control :
Public, Protected, Private Implementation.
public.
:
1. .
2. Detail.
3. ,
Insert.
4. .
5. Data type
.
6. , default
.
.
.
CourseOffering. (
) (
). ,
,
CourseOffering. ,
97
: (
) ( ).
Initialization
do/ initialize course offering
data
add student / set count=0 ^CourseRoster.create
[ count = 10 ]
Open
Closed
do/ Finalize course
cancel
^CourseRoster.delete
Canceled
. 3.26. CourseOffering
13.
CourseOffering
:
1. .
2. New > Statechart Diagram.
:
1. State
2. ,
.
Detail
.
:
1. .
2. Detail.
3. Actions.
4. Insert.
5. .
6. Actions.
7. When Do,
.
98
, When On Entry.
, When On Exit.
:
1. .
2. Detail.
3. Actions.
4. Insert.
5. .
6. Send Event.
7. (event),
(arguments) (Target).
:
1. Transition .
2. , .
3. , .
:
1. Transition to Self .
2. ,
.
, ,
:
1. ,
.
2. General.
3. Event.
4. Arguments.
5. Condition.
6. Action.
:
1. ,
.
99
2.
3.
4.
5.
Detail.
Send Event.
Send Arguments.
Send Target.
:
1. Start State End State.
2. ,
.
: (,
, )
(, , ),
.
<<control>>
RegistrationController
(from Registration)
+ submitSchedule()
+ saveSchedule()
+ getCourseOfferings() : CourseOfferingList
+ getCurrentSchedule(forStudent : Student, forSemester :
Semester) : Schedule
+ deleteCurrentSchedule()
<<class>> + new(forStudent : string)
+ getStudent(withID : string) : Student
+currentSchedule
0..1
0..1
<<entity>>
Schedule
(from University
Artifacts)
0..n
0..n
0..1
+registrant
<<Interface>>
ICourseCatalogSystem
(from External System
Interfaces)
0..n
0..1
1
<<entity>>
Student
(from University Artifacts)
+ getTuition() : double
+ addSchedule(theSchedule : Schedule)
+ getSchedule(forSemester: Semester) : Schedule
+ deleteSchedule(forSemester: Semester)
boolean
+ hasPrerequisites(forCourseOffering : CourseOffering) :
boolean
# passed(theCourseOffering : CourseOffering) : boolean
<<class>> + getNextAvailID() : int
+ getStudentID():int
+ getName() : string
+ getAddress(): string
+alternateCourses
0..2
+primaryCourses
0..4
<<entity>>
CourseOffering
(from University
Artifacts)
. 3.27.
100
:
1. ,
- ( .3.27 Schedule).
2. Containment.
3. By Value.
. By Value ,
, .
(By Reference) ,
.
:
( )
, . 3.28 .
(
).
<<entity>>
Student.
- name : string
- address : string
<<class>> - nextAvailID : int
- studentID : int
- dateofBirth : Date
1
1
Classification
<<entity>>
FulltimeClassification
<<entity>>
ParttimeClassification
- gradDate
- maxNumCourses
. 3.28
101
3.6.4.
Data Modeler.
.
-
SQL.
14.
:
:
1. .
2. Data Modeler > New >
Database.
3. DB_0
Target Oracle 8.x.
(persistent) :
1. Student University
Artifacts.
2. Detail.
3. Persistence Persistent.
4. Classification,
FulltimeClassification ParttimeClassification.
5. Student , + .
6. studentID.
7. Data Modeler > Part of Object
Identity ( ).
. 5, 6 7 Rational Rose,
2001.
:
1. University Artifacts.
2. Data Modeler > Transform to
Data Model.
102
T_Student.
+ name : NUMBER(5, 0)
+ address : NUMBER(5, 0)
+ nextAvailID : NUMBER(5, 0)
- studentID : NUMBER(5, 0)
+ dateofBirth : DATE
<<PK>> + PK_T_Student.15()
<<Identifying>>
1
1
T_Classification
- T_Classification_ID : NUMBER(10, 0)
studentID : NUMBER(5, 0)
<<PK>> + PK_T_Classification14()
<<Unique>> + TC_T_Classification18()
<<FK>> + FK_T_Classification6()
<<Index>> + TC_T_Classification17()
1
<<Identifying>>
0..1
<<Identifying>>
0..1
T_FulltimeClassification
T_ParttimeClassification
+ gradDate : NUMBER(5, 0)
studentID : NUMBER(5, 0)
T_Classification_ID : NUMBER(10, 0)
+ maxNumCourses : NUMBER(5, 0)
studentID : NUMBER(5, 0)
T_Classification_ID : NUMBER(10, 0)
<<PK>> + PK_T_FulltimeClassification16()
<<FK>> + FK_T_FulltimeClassification7()
<<PK>> + PK_T_ParttimeClassification17()
<<FK>> + FK_T_ParttimeClassification8()
. 3.29. -
103
SQL:
1. <<Schema>> S_0.
2. Data Modeler > Forward
Engineer.
3. Forward Engineering Wizard
Next.
4. DDL Next.
5.
Next.
6.
.
3.7.
3.7.1.
Rational Rose
.
, .
15.
++
Student .
:
1.
.
2. Package Specification.
3. .
4. Student
++.
5. Package Body.
6. .
7. Student
++.
104
8. Dependency.
9.
.
Student
Student
. 3.30.
:
1. Student.
2.
Student .
Student
Student.
3. Student Student
. Student
Student.
3.7.2.
:
1. .
2. .
3. , .
4. .
105
:
1. Tools > Check Model.
2. .
, ,
, , ,
.
Check Model
. Access Violations
, ,
,
.
:
1. Report > Show Access Violations.
2. .
,
, .
. Rose
.
.
Tools > Options,
. ,
, .
.
.
, Tools > Options,
,
.
,
, ..
. (C++, Java, )
. ,
, .
106
,
. .
,
.
.
.
. ,
,
.
Rose
(skeletal) :
. .
. ,
, .
.
,
.
.
.
.
.
16. ++
1.
2.
3.
4.
5.
.
.
Tools > C++ > Code Generation .
.
( Tools > C++ > Browse
Header Tools > C++ > Browse Body).
107
4.
! !
.
, .
:
;
(
:
;
);
108
,
;
,
( ),
(, , ), (,
, );
;
,
;
;
( )
.
.
.
.
Rational Rose.
.
4.1.
,
,
Rational Rose
, .
,
.
.
109
.
.
4.1.
. 4.1.
10 .
.
( )
. ,
, , .
.
. . ,
(
). ,
.
,
,
.
, 30
.
.
.
110
.
.
(
).
.
4.2.
III .
, , .
Rational Rose
.
20.00
. 4.2.
4.2.
.
.
. - ,
( ).
111
.
,
.
. ,
. .
.
.
.
, ,
,
.
.
. ,
, ,
.
.
4.3.
6 ?
, , .
.
www.metrosoft.narod.ru
Rational Rose
.
.
()
. (, , )
, (,
).
, .
112
,
, .
. ,
.
.
10 .
, .
.
(
).
,
.
:
, .
4.4.
!
Rational Rose
(
).
,
. ,
,
.
, , ,
. ,
, .
.
113
. ,
.
.
, , .
:
;
- ,
;
( 5 ).
,
.
. ,
,
.
,
.
4.5. -
- ,
, , .
Rational Rose
-
( ).
- .
. -
( ).
, . 9
.
114
.
, -
. - . ,
( ).
- .
( ), -
. , -
.
,
. , -
, .
, -
.
, -
.
,
- .
.
, 9. - ,
() ,
. ,
.
. , -
,
.
, - ,
.
- .
, .
000.
.
115
4.6.
.
?
.
?
.
. .
Rational Rose
.
, -.
( )
-. ,
, ,
.
,
.
-, .
.
( ) .
, (
).
, ,
.
# .
.
.
.
,
# .
,
.
116
,
.
,
.
, , .
,
. ,
, . ,
, ,
. , ,
,
.
4.7.
Play.
Rational Rose
.
.
: ,
, , , , ,
,
, .
5 , .
.
, ,
( ),
.
.
,
, , ,
.
117
,
, . ,
:
1) , , .
2) .
3) ,
.
4) .
,
( ),
( ), .
.
,
, .
4.8.
,
.
Rational Rose
.
. . ,
, ,
,
.
,
, -
.
, .
118
. ,
.
. (
),
. ,
, ()
.
(
) . ,
( ).
,
.
.
.
,
.
,
.
, , .
, .
15
. , :
;
;
;
.
,
.
.
119
4.9.
,
. !!!
Rational Rose
.
.
: , ,
, ,
, .
, .
. ,
.
.
.
,
.
, .
.
,
.
(10, 50, 100, 200, 500, 1000 ).
, .
. ,
, .
,
. ,
120
.
, .
,
.
.
, ,
,
.
.
4.10.
,
, .
.
Rational Rose
.
.
, , ,
, ,
.
.
.
, ,
, .
,
, .
, , .
.
,
.
(, ).
121
,
:
;
;
;
.
.
,
.
4.11.
, , : , , .
()
Rational Rose
,
.
( 0...9,
),
,
, .
,
, .
.
, .
.
, ,
. .
. .
.
, ,
122
.
, .
4.12.
- .
,
.
, -
.
(www.metrosoft.narod.ru)
Rational Rose
.
. ,
,
,
,
, .
,
. ,
,
.
. :
.
, , ,
, .
, ,
, ,
. ,
, (5 ),
.
,
(
, ..).
123
, .
. .
.
, ,
.
.
4.13.
, ,
: ,
, , , , .
. .
Rational Rose
.
( ), .
,
, (, )
, ,
. .
,
.
:
;
, ;
, ;
, .
124
, ,
.
4.14.
?
?! !
Rational Rose
.
(, ) .
:
, ;
.
, :
, , , ,
,
, .
, ,
.
. ,
, .
,
.
:
;
;
;
.
,
, .
125
4.15. -
,
?
, .
Rational Rose
-.
- .
-
,
-. .
(, , ,
, )
.
,
.
.
.
.
.
, , ,
.
.
-
.
, .
[-2001]. ,
Web- (
).
126
,
. Web-
:
Web-;
Web- (, CGI-);
HTML-;
JavaScript.
Web-:
link ;
build CGI- ,
;
submit Web-,
.
:
Web- (HTML-),
Active Server Page (ASP),
Java Server Page (JSP),
,
(, Javascript).
4.16. WWW-
,
.
WWW-
Rational Rose
WWW-.
WWW-
, .
: , , , ,
, .
.
127
, ,
,
. - .
,
. ,
.
()
, ..
.
,
.
.
,
. ,
, .
.
(
), .
. ,
,
.
.
-.
WWW- ,
-.
,
, ,
.
128
4.17.
.
Rational Rose
.
:
, (URL), ,
, , ,
, .
. ,
.
.
.
.
.
, (
).
(
).
( )
.
,
Web-, URL .
.
-.
WWW-
,
-
.
129
4.18.
., . . , ; , ,
, , ,
, .
. .
Rational Rose
.
(
, : 12 : 00),
.
:
,
,
,
.
: , , .
, ,
. ,
(
).
.
, ,
.
,
. , .
.
.
.
,
130
( ).
,
.
4.19.
, ,
. ;
;
Rational Rose
.
(..., , ,
, ) .
: -, - .
,
.
. , ,
.
.
:
;
;
,
;
;
;
;
(, ,
: , ).
131
4.20.
36 -102.
, , .
.
Rational Rose
.
:
, ,
, , ,
().
( : / , , + ,
) . /
.
, 1,
,
.
60 .
, .
+. +
, ( 59-
0-).
, ( 0-
59-).
,
.
.
. ,
.
10 . ,
( 1).
132
,
, .
.
:
0...9
( );
+
;
+ ;
, < > .
. 5
. ,
.
+ ,
- + . +
.
, , +
,
. .
, < >
, .
,
. < >
.
.
,
.
(, )
.
( )
.
, 15 .
133
4.21.
,
, .
Rational Rose
.
, ,
(,
).
,
, , ,
.
(,
,
,
. .).
.
4.22.
. . .
. , .
Rational Rose
.
.
.
,
, .
: ,
134
. ,
.
.
.
( ).
,
,
. ,
, ,
, . ,
.
,
, .
.
, , ,
, .
.
135
[-2000] ., . UML Rational Rose: . .
.: , 2000.
[-1999]
.
-
++. 2- .: . .
.: , .: , 1999.
[-2000] ., ., . UML.
: . . .: , 2000.
[-1998] . . CASE-.
. .:
, 1998.
[-2000] . .
. .:
, 2000.
[-2000] ., ., ., .
- : . . .: ,
2000.
[-2002] . UML.
, .: . .
.: , 2002.
[-2002] .
.: . . .: , 2002.
[-2001]
Web-
UML: . . .: , 2001.
[-1999] ., ., . .
, : . . .: , 1999.
[-2001] . UML
: . .: .: , 2001.
[-2001] . . UML : BHV, 2001.
136
[-2002] .
. UML.: .
.: .: , 2002.
[-2002] ., . UML
.: . . .: , 2002.
[-2001] . . CASE-:
Rational Rose .: , 2001
[-1999] ., . UML .
.: . .
.: , 1999.
[-2002] ., ., .
.: . .
: , 2002.
137
1. UML...............................................3
1.1. UML .............................................3
1.2. UML....................................................................................4
1.3. .............................................4
1.4. ...........................................................13
1.4.1. ..............................................14
1.4.2. ......................................................16
1.5. .........................................................................17
1.5.1. .........................................................................17
1.5.2 ...................................................................19
1.5.3. .....................................................................20
1.5.4. ....................................................................................22
1.5.5. ....................................................................................24
1.5.6. ...........................................................................................26
1.6. .....................................................................31
1.7. ...............................................................36
1.8. ................................................................37
1.9. ..................................................................39
2. CASE- Rational Rose ..............41
2.1. Rational Rose ................................................................41
2.2. Rational Rose...........................................................44
2.2.1. ........................................................................44
2.2.2. Rose ........................................48
2.2.3. ........................................51
3. ..................................................55
3.1. . ...................55
3.2. .....................................................56
3.3. ...................................57
3.4. .................................58
3.5. ...............................................................................69
3.5.1. ..............................................................69
3.5.2. ............................................72
138
3.6. ...............................................................86
3.6.1. ..................................................86
3.6.2. ....91
3.6.3. ...........................................................94
3.6.4. ...................................................102
3.7. ......................................................................104
3.7.1. ............................................................104
3.7.2. .........................................................................105
4. ..................108
4.1. ......................................................................109
4.2. ..........................................................................111
4.3. ................................................................112
4.4. ........113
4.5. -......................................................................................114
4.6. ..........................................................................................116
4.7. .......................................................................117
4.8. .........................................................................................118
4.9. .........................................................................................120
4.10. ................................................................................121
4.11. .............................................................................122
4.12. ............................................................................123
4.13. ................................................................124
4.14. .................................................................125
4.15. - ........................................................................126
4.16. WWW- ....................................................................127
4.17. ........................................................129
4.18. .....................................................................................130
4.19. ..............................................................131
4.20. ......................................................................................132
4.21. ............134
4.22. .......................................................................................134
...............................................................................................136
139