1 | <?php |
||
8 | final class InMemoryProfile implements Profile |
||
9 | { |
||
10 | /** |
||
11 | * @var Process[] |
||
12 | */ |
||
13 | private $processes = []; |
||
14 | |||
15 | /** |
||
16 | * @var float |
||
17 | */ |
||
18 | private $processorLoad = 0.0; |
||
19 | |||
20 | /** |
||
21 | * @var float |
||
22 | */ |
||
23 | private $memoryLoad = 0.0; |
||
24 | |||
25 | /** |
||
26 | * @var Process[] |
||
27 | */ |
||
28 | private $siblingProcesses = []; |
||
29 | |||
30 | /** |
||
31 | * @var float |
||
32 | */ |
||
33 | private $siblingProcessorLoad = 0.0; |
||
34 | |||
35 | /** |
||
36 | * @var float |
||
37 | */ |
||
38 | private $siblingMemoryLoad = 0.0; |
||
39 | |||
40 | /** |
||
41 | * @inheritdoc |
||
42 | * |
||
43 | * @return Process[] |
||
44 | */ |
||
45 | 1 | public function getProcesses() |
|
49 | |||
50 | /** |
||
51 | * @inheritdoc |
||
52 | * |
||
53 | * @param Process[] $processes |
||
54 | * |
||
55 | * @return $this |
||
56 | */ |
||
57 | 1 | public function setProcesses(array $processes) |
|
63 | |||
64 | /** |
||
65 | * @inheritdoc |
||
66 | * |
||
67 | * @return float |
||
68 | */ |
||
69 | 1 | public function getProcessorLoad() |
|
73 | |||
74 | /** |
||
75 | * @inheritdoc |
||
76 | * |
||
77 | * @param float $processorLoad |
||
78 | * |
||
79 | * @return $this |
||
80 | */ |
||
81 | 1 | public function setProcessorLoad($processorLoad) |
|
87 | |||
88 | /** |
||
89 | * @inheritdoc |
||
90 | * |
||
91 | * @return float |
||
92 | */ |
||
93 | 1 | public function getMemoryLoad() |
|
97 | |||
98 | /** |
||
99 | * @inheritdoc |
||
100 | * |
||
101 | * @param float $memoryLoad |
||
102 | * |
||
103 | * @return $this |
||
104 | */ |
||
105 | 1 | public function setMemoryLoad($memoryLoad) |
|
111 | |||
112 | /** |
||
113 | * @inheritdoc |
||
114 | * |
||
115 | * @return Process[] |
||
116 | */ |
||
117 | 1 | public function getSiblingProcesses() |
|
121 | |||
122 | /** |
||
123 | * @inheritdoc |
||
124 | * |
||
125 | * @param Process[] $siblingProcesses |
||
126 | * |
||
127 | * @return $this |
||
128 | */ |
||
129 | 1 | public function setSiblingProcesses(array $siblingProcesses) |
|
135 | |||
136 | /** |
||
137 | * @inheritdoc |
||
138 | * |
||
139 | * @return float |
||
140 | */ |
||
141 | 1 | public function getSiblingProcessorLoad() |
|
145 | |||
146 | /** |
||
147 | * @inheritdoc |
||
148 | * |
||
149 | * @param float $siblingProcessorLoad |
||
150 | * |
||
151 | * @return $this |
||
152 | */ |
||
153 | 1 | public function setSiblingProcessorLoad($siblingProcessorLoad) |
|
159 | |||
160 | /** |
||
161 | * @inheritdoc |
||
162 | * |
||
163 | * @return float |
||
164 | */ |
||
165 | 1 | public function getSiblingMemoryLoad() |
|
169 | |||
170 | /** |
||
171 | * @inheritdoc |
||
172 | * |
||
173 | * @param float $siblingMemoryLoad |
||
174 | * |
||
175 | * @return $this |
||
176 | */ |
||
177 | 1 | public function setSiblingMemoryLoad($siblingMemoryLoad) |
|
183 | } |
||
184 |