00001 package edu.rice.cs.hpc.data.experiment.scope.visitors; 00002 00003 import edu.rice.cs.hpc.data.experiment.metric.BaseMetric; 00004 import edu.rice.cs.hpc.data.experiment.scope.CallSiteScope; 00005 import edu.rice.cs.hpc.data.experiment.scope.ProcedureScope; 00006 import edu.rice.cs.hpc.data.experiment.scope.Scope; 00007 00008 public class FinalizeMetricVisitorWithBackup extends AbstractFinalizeMetricVisitor { 00009 00010 public FinalizeMetricVisitorWithBackup(BaseMetric[] listOfMetrics) { 00011 super(listOfMetrics); 00012 } 00013 00014 00015 00016 protected void setValue ( Scope scope) { 00017 if (scope instanceof CallSiteScope || 00018 (scope instanceof ProcedureScope && !((ProcedureScope)scope).isAlien()) ) 00019 scope.backupMetricValues(); 00020 00021 super.setValue_internal(scope); 00022 } 00023 00024 }