lcsim/src/org/lcsim/recon/cluster/util
diff -u -r1.1 -r1.2
--- VetoClustersFromParticles.java 4 Jul 2006 21:20:13 -0000 1.1
+++ VetoClustersFromParticles.java 2 Nov 2006 23:03:16 -0000 1.2
@@ -16,7 +16,7 @@
* to pick up the EventHeader object so that it can read in the list
* of particles on demand.
*
- * @version $Id: VetoClustersFromParticles.java,v 1.1 2006/07/04 21:20:13 mcharles Exp $
+ * @version $Id: VetoClustersFromParticles.java,v 1.2 2006/11/02 23:03:16 mcharles Exp $
*/
public class VetoClustersFromParticles extends Driver implements DecisionMakerSingle<Cluster>
@@ -38,9 +38,18 @@
for (ReconstructedParticle part : particles) {
List<Cluster> subClusters = recursivelyFindSubClusters(part);
boolean clusterInParticle = (subClusters.contains(objectToTest));
- if (clusterInParticle) { return false; }
+ if (clusterInParticle) {
+ if (m_debug) {
+ System.out.println("DEBUG: After looking at "+particles.size()+" particles, I found one which contained "+subClusters.size()
+ +" clusters. It matched this cluster with "+objectToTest.getCalorimeterHits().size()+" hits");
+ }
+ return false;
+ }
}
// No match
+ if (m_debug) {
+ System.out.println("DEBUG: After looking at "+particles.size()+" particles, I found no match for this cluster with "+objectToTest.getCalorimeterHits().size()+" hits");
+ }
return true;
}
@@ -74,4 +83,6 @@
protected EventHeader m_event;
protected String m_particleListName;
+ protected boolean m_debug = false;
+ public void setDebug(boolean debug) { m_debug = debug; }
}