Commit in hps-java/src/main/java/org/lcsim/hps/recon/tracking on MAIN | |||
StereoPair.java | +31 | -4 | 1.2 -> 1.3 |
SvtUtils.java | +6 | -5 | 1.14 -> 1.15 |
+37 | -9 |
Add ability to specify if a stereo pair resides in the top or bottom SVT volume
diff -u -r1.2 -r1.3 --- StereoPair.java 27 Jul 2013 01:52:49 -0000 1.2 +++ StereoPair.java 30 Jul 2013 00:53:07 -0000 1.3 @@ -3,9 +3,11 @@
import org.lcsim.detector.tracker.silicon.SiSensor; /**
+ * A class describing an SVT stereo pair.
* * @author Per Hansson <[log in to unmask]>
- * @version $Id: StereoPair.java,v 1.2 2013/07/27 01:52:49 omoreno Exp $
+ * @author Omar Moreno <[log in to unmask]> + * @version $Id: StereoPair.java,v 1.3 2013/07/30 00:53:07 omoreno Exp $
*/ public class StereoPair {
@@ -16,7 +18,11 @@
// The axial and stereo sensors private SiSensor axialSensor = null; private SiSensor stereoSensor = null;
-
+ + // The detector volume in which the stereo pair resides + public enum detectorVolume{ Top, Bottom }; + private detectorVolume volume = detectorVolume.Top; +
/** * Default Ctor *
@@ -29,12 +35,15 @@
/** * Ctor *
- * @param layerNumber : Layer number to shich the stereo pair belongs to
+ * @param layerNumber : Layer number to which the stereo pair belongs to
+ * @param volume : detector volume (detectorVolume.Top or detector Volume.Bottom) in
+ * which the stereo pair resides
* @param axialSensor * @param stereoSensor */
- public StereoPair(int layerNumber, SiSensor axialSensor, SiSensor stereoSensor){
+ public StereoPair(int layerNumber, detectorVolume volume, SiSensor axialSensor, SiSensor stereoSensor){
this.layerNumber = layerNumber;
+ this.volume = volume;
this.axialSensor = axialSensor; this.stereoSensor = stereoSensor; }
@@ -58,6 +67,15 @@
} /**
+ * Set the SVT volume in which the stereo pair resides + * + * @param volume : detectorVolume.Top or detectorVolume.Bottom + */ + public void setDetectorVolume(detectorVolume volume){ + this.volume = volume; + } + + /**
* Get the axial sensor of the stereo pair * * @return Axial sensor. Returns null if it hasn't been set yet.
@@ -85,6 +103,15 @@
} /**
+ * Get the SVT volume in which the stereo pair resides + * + * @return volume : detectorVolume.Top or detectorVolume.Bottom + */ + public detectorVolume getDetectorVolume(){ + return volume; + } + + /**
* Return a string describing the stereo pair * * @return stereo pair description
diff -u -r1.14 -r1.15 --- SvtUtils.java 27 Jul 2013 01:52:49 -0000 1.14 +++ SvtUtils.java 30 Jul 2013 00:53:07 -0000 1.15 @@ -21,12 +21,13 @@
import org.lcsim.hps.util.Pair; import org.lcsim.hps.recon.tracking.StereoPair;
+import org.lcsim.hps.recon.tracking.StereoPair.detectorVolume;
/** * A class providing various utilities related to the HPS SVT. * * @author Omar Moreno <[log in to unmask]>
- * @version $Id: SvtUtils.java,v 1.14 2013/07/27 01:52:49 omoreno Exp $
+ * @version $Id: SvtUtils.java,v 1.15 2013/07/30 00:53:07 omoreno Exp $
*/ public class SvtUtils {
@@ -473,9 +474,9 @@
trackerLayer = (layerNumber + 1)/2; if(this.isAxial(firstSensor)){
- stereoPairs.add(new StereoPair(trackerLayer, firstSensor, secondSensor));
+ stereoPairs.add(new StereoPair(trackerLayer, detectorVolume.Top, firstSensor, secondSensor));
} else {
- stereoPairs.add(new StereoPair(trackerLayer, secondSensor, firstSensor));
+ stereoPairs.add(new StereoPair(trackerLayer, detectorVolume.Top, secondSensor, firstSensor));
} firstSensor = this.getBottomSensor(layerNumber, sensorNumber);
@@ -484,9 +485,9 @@
if(firstSensor == null || secondSensor == null) continue; if(this.isAxial(firstSensor)){
- stereoPairs.add(new StereoPair(trackerLayer, firstSensor, secondSensor));
+ stereoPairs.add(new StereoPair(trackerLayer, detectorVolume.Bottom, firstSensor, secondSensor));
} else {
- stereoPairs.add(new StereoPair(trackerLayer, secondSensor, firstSensor));
+ stereoPairs.add(new StereoPair(trackerLayer, detectorVolume.Bottom, secondSensor, firstSensor));
} } }
Use REPLY-ALL to reply to list
To unsubscribe from the LCD-CVS list, click the following link:
https://listserv.slac.stanford.edu/cgi-bin/wa?SUBED1=LCD-CVS&A=1