-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathPatientFlowSys.java
More file actions
89 lines (76 loc) · 3.73 KB
/
Copy pathPatientFlowSys.java
File metadata and controls
89 lines (76 loc) · 3.73 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
package HealthCareSystem;
import java.awt.*;
import simView.*;
import genDevs.modeling.*;
import genDevs.simulation.*;
import GenCol.*;
public class PatientFlowSys extends ViewableDigraph{
public PatientFlowSys() {
super("airport");
ViewableAtomic walkinarrv = new WalkinArrivals ("walkinArrivals",5);
ViewableAtomic emergarrv = new EmergencyArrivals ("emergencyArrivals",5);
ViewableAtomic walkinQueue = new WalkinPatientsQueue ("WalkinPatientsQueue");
ViewableAtomic emergQueue = new EmergencyPatientsQueue ("EmergencyPatientsQueue");
ViewableAtomic outPatient = new OutPatientCenter ("OutPatientCenter");
ViewableAtomic emrgPatient = new EmergencyRecoveryCenter ("EmergencyRecoveryCenter");
ViewableAtomic contrl = new AssessmentController ("AssessmentController");
add(walkinarrv);
add(emergarrv);
add(walkinQueue);
add(emergQueue);
add(outPatient);
add(emrgPatient);
add(contrl);
addInport("start");
addInport("stop");
addOutport("walkinOut");
addOutport("emergOut");
addOutport("ctrlOut");
addTestInput("start", new entity (""));
addTestInput("stop", new entity (""));
addCoupling(this, "start", walkinarrv, "start");
addCoupling(this, "start", emergarrv, "start");
addCoupling(this, "stop", walkinarrv, "stop");
addCoupling(this, "stop", emergarrv, "stop");
addCoupling(outPatient, "out", this, "walkinOut");
addCoupling(emrgPatient, "out", this, "emergOut");
addCoupling(contrl, "out", this, "ctrlOut");
addCoupling(walkinarrv, "out",walkinQueue,"in");
addCoupling(emergarrv, "out",emergQueue,"in");
addCoupling(walkinQueue, "out",outPatient,"in");
addCoupling(emergQueue, "out",emrgPatient,"in");
addCoupling(walkinQueue, "ready",outPatient,"ready");
addCoupling(emergQueue, "ready",emrgPatient,"ready");
addCoupling(outPatient,"yes_ready",walkinQueue,"yes_ready");
addCoupling(emrgPatient, "yes_ready",emergQueue,"yes_ready");
addCoupling(outPatient,"out",contrl,"in");
addCoupling(emrgPatient, "out",contrl,"in");
addCoupling(contrl, "out",outPatient,"in");
addCoupling(contrl, "out",emrgPatient,"in");
addCoupling(outPatient, "out",walkinQueue,"in");
addCoupling(emrgPatient, "out",emergQueue,"in");
initialize();
}
/**
* Automatically generated by the SimView program.
* Do not edit this manually, as such changes will get overwritten.
*/
public void layoutForSimView()
{
preferredSize = new Dimension(882, 505);
if((ViewableComponent)withName("EmergencyPatientsQueue")!=null)
((ViewableComponent)withName("EmergencyPatientsQueue")).setPreferredLocation(new Point(148, 389));
if((ViewableComponent)withName("OutPatientCenter")!=null)
((ViewableComponent)withName("OutPatientCenter")).setPreferredLocation(new Point(353, 102));
if((ViewableComponent)withName("EmergencyRecoveryCenter")!=null)
((ViewableComponent)withName("EmergencyRecoveryCenter")).setPreferredLocation(new Point(359, 293));
if((ViewableComponent)withName("walkinArrivals")!=null)
((ViewableComponent)withName("walkinArrivals")).setPreferredLocation(new Point(40, 121));
if((ViewableComponent)withName("WalkinPatientsQueue")!=null)
((ViewableComponent)withName("WalkinPatientsQueue")).setPreferredLocation(new Point(162, 22));
if((ViewableComponent)withName("AssessmentController")!=null)
((ViewableComponent)withName("AssessmentController")).setPreferredLocation(new Point(491, 204));
if((ViewableComponent)withName("emergencyArrivals")!=null)
((ViewableComponent)withName("emergencyArrivals")).setPreferredLocation(new Point(44, 251));
}
}// end of class airport