Real Time Scheduler: Use Case Diagram
Real Time Scheduler: Use Case Diagram
Real Time Scheduler: Use Case Diagram
submit task
user task table
memory
calculate cpu burst
short term scheduler
cpu allocation
suspend task
block task
SEQUENCE DIAGRAM
1: Check status
2: busy
3: check status
4: Busy
5: place task
ACTIVITY DIAGRAM
check status
allocate
task
place task in
waiting queue
CLASS DIAGRAM
TaskTable
task_id
arrival_time
burst_time
priority
get_arrival_time()
get_cpu_burst()
User
tasktable()
user_id
task_id
scheduler
submit() midtermscheduler
user()
task_id
status_flag
longtermscheduler
check_cpu_status()
task_id
shorttermscheduler check_secondary_memory_status()
arrival_time
allocate_cpu()
task_id
midtermscheduler()
apply_algorithm() arrival_time
place_time() burst_time
longtermscheduler()
select_task()
choose_algorithm()
calculate_cpu_burst()
readyQueue shorttermscheduler()
task_id waitingqueue
arrival_time
task_id
burst_time
arrival_time
burst_time
view_task()
waiting_time
view_priority()
readyqueue()
view_waiting_time()
view_task()
waitingqueue()
COLLABORATION DIAGRAM
2: busy 4: busy
Cpu Secondary
memory
3: check status
1: check status
Waiting mid
queue scheduler
5: place task
COMPONENT DIAGRAM
scheduler gui
DEPLOYMENT DIAGRAM
scheduler1
gui
Longtermscheduler.cls
Option Explicit
'##ModelId=4CA5A56702BF
Private task_id As Variant
'##ModelId=4CA5A56B01F4
Private arrival_time As Variant
'##ModelId=4CA5A5720242
Public Sub apply_algorithm()
End Sub
'##ModelId=4CA5A57A000F
Public Sub place_time()
End Sub
'##ModelId=4CA5A57E00FA
Public Sub longtermscheduler()
End Sub
Midtermscheduler.cls
Option Explicit
'##ModelId=4CA5A5CF0128
Private task_id As Variant
'##ModelId=4CA5A5D400CB
Private status_flag As Variant
'##ModelId=4CA5A5DC0000
Public Sub check_cpu_status()
End Sub
'##ModelId=4CA5A5E30232
Public Sub check_secondary_memory_status()
End Sub
'##ModelId=4CA5A5F2006D
Public Sub allocate_cpu()
End Sub
'##ModelId=4CA5A5F803C8
Public Sub midtermscheduler()
End Sub
readyQueue.cls
Option Explicit
'##ModelId=4CA5A61F0148
Private task_id As Variant
'##ModelId=4CA5A62400BB
Private arrival_time As Variant
'##ModelId=4CA5A6280232
Private burst_time As Variant
'##ModelId=4CA5A62D03D8
Public Sub view_task()
End Sub
'##ModelId=4CA5A6320138
Public Sub view_priority()
End Sub
'##ModelId=4CA5A63702BF
Public Sub readyqueue()
End Sub
Scheduler.cls
Option Explicit
'##ModelId=4CA5A69F0203
Implements midtermscheduler
'##ModelId=4CA5A69C0399
Implements longtermscheduler
'##ModelId=4CA5A6C90196
Implements shorttermscheduler
'##ModelId=4CAD4E6700DA
Private mshorttermschedulerObject As New shorttermscheduler
'##ModelId=4CAD4E670128
Private Sub shorttermscheduler_select_task()
Call mshorttermschedulerObject.select_task
End Sub
'##ModelId=4CAD4E670129
Private Sub shorttermscheduler_choose_algorithm()
Call mshorttermschedulerObject.choose_algorithm
End Sub
'##ModelId=4CAD4E67012A
Private Sub shorttermscheduler_calculate_cpu_burst()
Call mshorttermschedulerObject.calculate_cpu_burst
End Sub
'##ModelId=4CAD4E67012B
Private Sub shorttermscheduler_shorttermscheduler()
Call mshorttermschedulerObject.shorttermscheduler
End Sub
'##ModelId=4CAD4E67012C
Private Sub longtermscheduler_apply_algorithm()
End Sub
'##ModelId=4CAD4E670138
Private Sub longtermscheduler_place_time()
End Sub
'##ModelId=4CAD4E670139
Private Sub longtermscheduler_longtermscheduler()
End Sub
'##ModelId=4CAD4E67013A
Private Sub midtermscheduler_check_cpu_status()
End Sub
'##ModelId=4CAD4E67013B
Private Sub midtermscheduler_check_secondary_memory_status()
End Sub
'##ModelId=4CAD4E67013C
Private Sub midtermscheduler_allocate_cpu()
End Sub
'##ModelId=4CAD4E67013D
Private Sub midtermscheduler_midtermscheduler()
End Sub
Shorttermscheduler.cls
Option Explicit
'##ModelId=4CA5A59402FD
Private task_id As Variant
'##ModelId=4CA5A59900FA
Private arrival_time As Variant
'##ModelId=4CA5A59D0280
Private burst_time As Variant
'##ModelId=4CA5A5A30119
Public Sub select_task()
End Sub
'##ModelId=4CA5A5A800EA
Public Sub choose_algorithm()
End Sub
'##ModelId=4CA5A5AE007D
Public Sub calculate_cpu_burst()
End Sub
'##ModelId=4CA5A5B500DA
Public Sub shorttermscheduler()
End Sub
User.cls
Option Explicit
'##ModelId=4CA5A5310167
Private user_id As Variant
'##ModelId=4CA5A5350213
Private task_id As Variant
'##ModelId=4CA5A53B035B
Public Sub submit()
End Sub
'##ModelId=4CA5A53E038A
Public Sub user()
End Sub
Tasktable.cls
Option Explicit
'##ModelId=4CA5A4F2000F
Private task_id As Variant
'##ModelId=4CA5A4F8033C
Private arrival_time As Variant
'##ModelId=4CA5A50102EE
Private burst_time As Variant
'##ModelId=4CA5A507009C
Private priority As Variant
'##ModelId=4CA5A50D03C8
Public Sub get_arrival_time()
End Sub
'##ModelId=4CA5A51400EA
Public Sub get_cpu_burst()
End Sub
'##ModelId=4CA5A51C00EA
Public Sub tasktable()
End Sub
Waitingqueue.cls
Option Explicit
'##ModelId=4CA5A6490119
Private task_id As Variant
'##ModelId=4CA5A64D008C
Private arrival_time As Variant
'##ModelId=4CA5A6530138
Private burst_time As Variant
'##ModelId=4CA5A657000F
Private waiting_time As Variant
'##ModelId=4CA5A65E0251
Public Sub view_waiting_time()
End Sub
'##ModelId=4CA5A66401D4
Public Sub view_task()
End Sub
'##ModelId=4CA5A669002E
Public Sub waitingqueue()
End Sub