Print

Print


Commit in GeomConverter/src/org/lcsim/geometry on MAIN
IDDecoder.java+11-11.12 -> 1.13
JM: add findCellContainingXYZ() and getPositionVector() to IDDecoder interface

GeomConverter/src/org/lcsim/geometry
IDDecoder.java 1.12 -> 1.13
diff -u -r1.12 -r1.13
--- IDDecoder.java	7 Feb 2006 18:58:03 -0000	1.12
+++ IDDecoder.java	8 Feb 2006 01:00:29 -0000	1.13
@@ -1,5 +1,7 @@
 package org.lcsim.geometry;
 
+import hep.physics.vec.Hep3Vector;
+
 import org.lcsim.geometry.subdetector.BarrelEndcapFlag;
 import org.lcsim.geometry.util.IDDescriptor;
 
@@ -63,6 +65,9 @@
    
     // FIXME: change to Hep3Vector and eliminate the X/Y/Z/theta/phi methods
     
+    /** @return Hep3Vector representing the position of the current ID. */
+    public Hep3Vector getPositionVector();
+    
     /** @return position as double array of length 3 */
     public double[] getPosition();
     
@@ -81,7 +86,11 @@
     /** @return theta angle */
     public double getTheta();    
     
-    /*/\/\/\ Miscellaneous /\/\/\ */
+    /* /\/\/\ Reverse Decoding: Position to Cell /\/\/\ */
+    
+    public long findCellContainingXYZ(Hep3Vector pos);
+    
+    /* /\/\/\ Miscellaneous /\/\/\ */
     
     /** Get the flag that indicates barrel or endcap, i.e. the "barrel" field. */
     public BarrelEndcapFlag getBarrelEndcapFlag();
@@ -93,6 +102,7 @@
     public Subdetector getSubdetector();
     
     /* /\/\/\ Neighbours /\/\/\ */
+    
     public boolean supportsNeighbours();
     public long[] getNeighbourIDs();
     public long[] getNeighbourIDs(int deltaLayer, int deltaTheta, int deltaPhi);
CVSspam 0.2.8