lcsim/src/org/lcsim/detector/driver
diff -u -r1.9 -r1.10
--- SimTrackerHitIdentifierReadoutDriver.java 16 Dec 2008 00:26:50 -0000 1.9
+++ SimTrackerHitIdentifierReadoutDriver.java 16 Dec 2008 00:35:48 -0000 1.10
@@ -30,14 +30,13 @@
super(collectionNames);
}
- // FIXME: This should go in startOfData() but that method may not always be called.
- public void detectorChanged(Detector detector)
+ public void startOfData()
{
if (needCleanupDriver)
{
add(new ReadoutCleanupDriver(new ArrayList<String>(collections)));
needCleanupDriver=false;
- }
+ }
}
protected void process(EventHeader header)
lcsim/src/org/lcsim/recon/tracking/digitization/sistripsim
diff -u -r1.2 -r1.3
--- TrackerHitDriver.java 15 Dec 2008 21:09:00 -0000 1.2
+++ TrackerHitDriver.java 16 Dec 2008 00:35:48 -0000 1.3
@@ -187,15 +187,16 @@
}
public void startOfData()
- {
- super.startOfData();
-
+ {
// If readouts not already set, set them up
if (_readouts.size() != 0)
{
System.out.println("Adding SimTrackerHitIdentifierReadoutDriver with readouts: "+_readouts);
- super.add( new SimTrackerHitIdentifierReadoutDriver( _readouts ) );
+ super.add( new SimTrackerHitIdentifierReadoutDriver( _readouts ) );
}
+
+ // Call this after added above driver, so that subdriver's startOfData() method is called. --JM
+ super.startOfData();
// Only allow this once per job since readouts cannot be deleted for SimTrackerIdentifierReadoutDriver
// FIXME: should be a robust system for changing readouts and eliminating duplicates in the readout driver