AbstractCombineMetric.java

Go to the documentation of this file.
00001 package edu.rice.cs.hpc.data.experiment.metric;
00002 
00003 import edu.rice.cs.hpc.data.experiment.scope.Scope;
00004 import edu.rice.cs.hpc.data.experiment.scope.filters.MetricValuePropagationFilter;
00005 
00006 public abstract class AbstractCombineMetric  {
00007 
00008     protected void combine_internal(Scope target, Scope source,
00009             MetricValuePropagationFilter inclusiveOnly,
00010             MetricValuePropagationFilter exclusiveOnly) {
00011 
00012         if (target.isCounterZero() && inclusiveOnly != null) {
00013             target.safeCombine(source, inclusiveOnly);
00014         }
00015         if (exclusiveOnly != null)
00016             target.combine(source, exclusiveOnly);
00017 
00018         target.incrementCounter();
00019         
00020     }
00021     
00022     abstract public void combine(Scope target, Scope source,
00023             MetricValuePropagationFilter inclusiveOnly,
00024             MetricValuePropagationFilter exclusiveOnly);
00025 }

Generated on 5 May 2015 for HPCVIEWER by  doxygen 1.6.1