EMMA Coverage Report (generated Sun Feb 05 10:43:15 CET 2012) |
---|
[all classes][de.uka.ipd.sdq.measurement.strategies.activeresource.cpu] |
name | class, % | method, % | block, % | line, % |
---|---|---|---|---|
WaitDemand.java | 0% (0/1) | 0% (0/6) | 0% (0/22) | 0% (0/10) |
name | class, % | method, % | block, % | line, % |
---|---|---|---|---|
class WaitDemand | 0% (0/1) | 0% (0/6) | 0% (0/22) | 0% (0/10) |
WaitDemand (): void | 0% (0/1) | 0% (0/8) | 0% (0/2) | |
cleanup (): void | 0% (0/1) | 0% (0/1) | 0% (0/1) | |
getName (): String | 0% (0/1) | 0% (0/2) | 0% (0/1) | |
getStrategysResource (): ResourceTypeEnum | 0% (0/1) | 0% (0/2) | 0% (0/1) | |
run (long): void | 0% (0/1) | 0% (0/4) | 0% (0/2) | |
waitFor (long): void | 0% (0/1) | 0% (0/5) | 0% (0/3) |
1 | package de.uka.ipd.sdq.measurement.strategies.activeresource.cpu; |
2 | |
3 | import de.uka.ipd.sdq.measurement.strategies.activeresource.AbstractDemandStrategy; |
4 | import de.uka.ipd.sdq.measurement.strategies.activeresource.ResourceTypeEnum; |
5 | |
6 | public class WaitDemand extends AbstractDemandStrategy { |
7 | |
8 | public WaitDemand() { |
9 | super(-2,0,3,10,50); |
10 | } |
11 | |
12 | private void waitFor(long waitingTime) { |
13 | try { |
14 | Thread.sleep(waitingTime); |
15 | } catch (InterruptedException e) { |
16 | } |
17 | } |
18 | |
19 | @Override |
20 | public void run(long initial) { |
21 | waitFor(initial); |
22 | } |
23 | |
24 | @Override |
25 | public ResourceTypeEnum getStrategysResource() { |
26 | return ResourceTypeEnum.CPU; |
27 | } |
28 | |
29 | @Override |
30 | public String getName() { |
31 | return "Wait"; |
32 | } |
33 | |
34 | @Override |
35 | public void cleanup() { |
36 | // Do nothing. |
37 | } |
38 | |
39 | } |
[all classes][de.uka.ipd.sdq.measurement.strategies.activeresource.cpu] |
EMMA 2.0.9414 (unsupported private build) (C) Vladimir Roubtsov |