Class MeasurementTestUtils


  • public final class MeasurementTestUtils
    extends Object
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static <Q extends javax.measure.quantity.Quantity>
      void
      allDoubleMeasurementValuesMatch​(org.palladiosimulator.edp2.models.ExperimentData.Measurement measurement, org.palladiosimulator.metricspec.BaseMetricDescription valueMetric, javax.measure.unit.Unit<Q> unit, org.hamcrest.Matcher<Double> matcher)  
      static <Q extends javax.measure.quantity.Quantity>
      List<javax.measure.Measure<?,​Q>>
      allMeasurementsOfMetric​(org.palladiosimulator.edp2.models.ExperimentData.Measurement measurement, org.palladiosimulator.metricspec.BaseMetricDescription valueMetric)  
      static <Q extends javax.measure.quantity.Quantity>
      void
      allMeasurementValuesMatch​(org.palladiosimulator.edp2.models.ExperimentData.Measurement measurement, org.palladiosimulator.metricspec.BaseMetricDescription valueMetric, org.hamcrest.Matcher<javax.measure.Measure<?,​Q>> matcher)  
      static Map<Integer,​Double> calculateIntBucketsBasedOnStateDuration​(org.palladiosimulator.edp2.models.ExperimentData.Measurement measurement, org.palladiosimulator.metricspec.BaseMetricDescription contentMetric, javax.measure.unit.Unit<? extends javax.measure.quantity.Quantity> convertContentToMetric)  
      static Optional<org.palladiosimulator.edp2.models.ExperimentData.Measurement> getMeasurementOfAt​(Collection<org.palladiosimulator.edp2.models.ExperimentData.Measurement> measurements, org.palladiosimulator.metricspec.MetricDescription metric, EObject location)  
      static Optional<org.palladiosimulator.edp2.models.ExperimentData.Measurement> getMeasurementOfAt​(Collection<org.palladiosimulator.edp2.models.ExperimentData.Measurement> measurements, org.palladiosimulator.metricspec.MetricDescription metric, org.palladiosimulator.edp2.models.measuringpoint.MeasuringPoint location)  
      static boolean sameMeasuringPoint​(org.palladiosimulator.edp2.models.measuringpoint.MeasuringPoint point1, org.palladiosimulator.edp2.models.measuringpoint.MeasuringPoint point2)  
    • Constructor Detail

      • MeasurementTestUtils

        public MeasurementTestUtils()
    • Method Detail

      • allDoubleMeasurementValuesMatch

        public static <Q extends javax.measure.quantity.Quantity> void allDoubleMeasurementValuesMatch​(org.palladiosimulator.edp2.models.ExperimentData.Measurement measurement,
                                                                                                       org.palladiosimulator.metricspec.BaseMetricDescription valueMetric,
                                                                                                       javax.measure.unit.Unit<Q> unit,
                                                                                                       org.hamcrest.Matcher<Double> matcher)
      • allMeasurementValuesMatch

        public static <Q extends javax.measure.quantity.Quantity> void allMeasurementValuesMatch​(org.palladiosimulator.edp2.models.ExperimentData.Measurement measurement,
                                                                                                 org.palladiosimulator.metricspec.BaseMetricDescription valueMetric,
                                                                                                 org.hamcrest.Matcher<javax.measure.Measure<?,​Q>> matcher)
      • allMeasurementsOfMetric

        public static <Q extends javax.measure.quantity.Quantity> List<javax.measure.Measure<?,​Q>> allMeasurementsOfMetric​(org.palladiosimulator.edp2.models.ExperimentData.Measurement measurement,
                                                                                                                                 org.palladiosimulator.metricspec.BaseMetricDescription valueMetric)
      • getMeasurementOfAt

        public static Optional<org.palladiosimulator.edp2.models.ExperimentData.Measurement> getMeasurementOfAt​(Collection<org.palladiosimulator.edp2.models.ExperimentData.Measurement> measurements,
                                                                                                                org.palladiosimulator.metricspec.MetricDescription metric,
                                                                                                                EObject location)
      • getMeasurementOfAt

        public static Optional<org.palladiosimulator.edp2.models.ExperimentData.Measurement> getMeasurementOfAt​(Collection<org.palladiosimulator.edp2.models.ExperimentData.Measurement> measurements,
                                                                                                                org.palladiosimulator.metricspec.MetricDescription metric,
                                                                                                                org.palladiosimulator.edp2.models.measuringpoint.MeasuringPoint location)
      • sameMeasuringPoint

        public static boolean sameMeasuringPoint​(org.palladiosimulator.edp2.models.measuringpoint.MeasuringPoint point1,
                                                 org.palladiosimulator.edp2.models.measuringpoint.MeasuringPoint point2)
      • calculateIntBucketsBasedOnStateDuration

        public static Map<Integer,​Double> calculateIntBucketsBasedOnStateDuration​(org.palladiosimulator.edp2.models.ExperimentData.Measurement measurement,
                                                                                        org.palladiosimulator.metricspec.BaseMetricDescription contentMetric,
                                                                                        javax.measure.unit.Unit<? extends javax.measure.quantity.Quantity> convertContentToMetric)