EMMA Coverage Report (generated Sun Feb 05 10:43:15 CET 2012)
[all classes][de.uka.ipd.sdq.pipesandfilters.framework.recorder.sensorframework.strategies]

COVERAGE SUMMARY FOR SOURCE FILE [ResponseTimeWriteDataStrategy.java]

nameclass, %method, %block, %line, %
ResponseTimeWriteDataStrategy.java0%   (0/1)0%   (0/2)0%   (0/32)0%   (0/10)

COVERAGE BREAKDOWN BY CLASS AND METHOD

nameclass, %method, %block, %line, %
     
class ResponseTimeWriteDataStrategy0%   (0/1)0%   (0/2)0%   (0/32)0%   (0/10)
ResponseTimeWriteDataStrategy (IDAOFactory, Experiment, ExperimentRun): void 0%   (0/1)0%   (0/6)0%   (0/2)
writeData (PipeData): void 0%   (0/1)0%   (0/26)0%   (0/8)

1package de.uka.ipd.sdq.pipesandfilters.framework.recorder.sensorframework.strategies;
2 
3import javax.measure.Measure;
4import javax.measure.quantity.Duration;
5import javax.measure.unit.SI;
6 
7import de.uka.ipd.sdq.pipesandfilters.framework.PipeData;
8import de.uka.ipd.sdq.sensorframework.entities.Experiment;
9import de.uka.ipd.sdq.sensorframework.entities.ExperimentRun;
10import de.uka.ipd.sdq.sensorframework.entities.TimeSpanSensor;
11import de.uka.ipd.sdq.sensorframework.entities.dao.IDAOFactory;
12 
13public class ResponseTimeWriteDataStrategy extends AbstractWriteDataStrategy {
14 
15        public ResponseTimeWriteDataStrategy(IDAOFactory daoFactory,
16                        Experiment experiment, ExperimentRun run) {
17                super(daoFactory, experiment, run);
18        }
19        
20        @SuppressWarnings("unchecked")
21        @Override
22        public void writeData(PipeData data) {
23                Measure<Double, Duration> waitingTimeMeasure = (Measure<Double, Duration>) data
24                                .getTupleElement(0);
25                Measure<Double, Duration> eventTimeMeasure = (Measure<Double, Duration>) data
26                        .getTupleElement(1);
27                double waitingTime = waitingTimeMeasure.doubleValue(SI.SECOND);
28                double eventTime = eventTimeMeasure.doubleValue(SI.SECOND);
29                run.addTimeSpanMeasurement((TimeSpanSensor)sensor, eventTime, waitingTime);
30        }
31 
32        
33 
34}

[all classes][de.uka.ipd.sdq.pipesandfilters.framework.recorder.sensorframework.strategies]
EMMA 2.0.9414 (unsupported private build) (C) Vladimir Roubtsov