Commit in projects/lcsim/trunk/detector-framework/src/main/java/org/lcsim/geometry/compact/converter/lcdd on MAIN | |||
HPSTestRunTracker2014GeometryDefinition.java | +26 | -17 | 3285 -> 3286 |
added component ID's to half-module components.
--- projects/lcsim/trunk/detector-framework/src/main/java/org/lcsim/geometry/compact/converter/lcdd/HPSTestRunTracker2014GeometryDefinition.java 2014-09-01 12:06:36 UTC (rev 3285) +++ projects/lcsim/trunk/detector-framework/src/main/java/org/lcsim/geometry/compact/converter/lcdd/HPSTestRunTracker2014GeometryDefinition.java 2014-09-02 05:00:29 UTC (rev 3286) @@ -1104,14 +1104,12 @@
}
- public static class Sensor extends BaseGeometry { - private int id;
+ public static class Sensor extends HalfModuleComponent {
private static final double sensor_length= 100.00; //98.33; private static final double sensor_width = 40.34; //38.3399; private static final double sensor_thickness = 0.32; public Sensor(String name, BaseGeometry m, int id) {
- super(name, m); - this.id = id;
+ super(name, m, id);
init(); } public static double getSensorLength() {
@@ -1134,17 +1132,23 @@
protected void setCoord() { setCoord(null); }
- public int getId() { - return id; - } - public void setId(int id) { - this.id = id; - }
protected void setCenter() { setCenter(0,0,0); } protected void setBoxDim() { setBoxDim(getSensorLength(),getSensorThickness(),getSensorWidth());
+ } + protected double getThickness() { + return getSensorThickness(); + } + protected double getHeigth() { + return getSensorHeight(); + } + protected double getWidth() { + return getSensorWidth(); + } + protected double getLength() { + return getSensorLength();
} }
@@ -1186,8 +1190,10 @@
} public static abstract class HalfModuleComponent extends BaseGeometry {
- public HalfModuleComponent(String name, BaseGeometry m) {
+ int id = -1; + public HalfModuleComponent(String name, BaseGeometry m, int id) {
super(name, m);
+ this.id = id;
} protected abstract double getThickness(); protected abstract double getHeigth();
@@ -1196,14 +1202,17 @@
protected void setCoord() { setCoord(null); }
+ public int getId() { + return id; + }
} public static class HalfModuleLamination extends HalfModuleComponent { protected static final double kapton_length = 184.0; protected static final double kapton_width = 40.0; protected static final double kapton_thickness = 0.050;
- public HalfModuleLamination(String name, BaseGeometry m) { - super(name, m);
+ public HalfModuleLamination(String name, BaseGeometry m, int id) { + super(name, m, id);
init(); } protected void setPos() {
@@ -1246,8 +1255,8 @@
protected static final double cf_length = 200.; protected static final double cf_width = 45.; protected static final double cf_thickness = 0.250;
- public CarbonFiber(String name, BaseGeometry m) { - super(name, m);
+ public CarbonFiber(String name, BaseGeometry m, int id) { + super(name, m, id);
init(); } protected void setPos() {
@@ -1289,8 +1298,8 @@
protected static final double hybrid_length = 170.0 - HPSTestRunTracker2014GeometryDefinition.Sensor.getSensorLength(); // sensor b-to-b with hybrid protected static final double hybrid_width = HPSTestRunTracker2014GeometryDefinition.Sensor.getSensorWidth(); protected static final double hybrid_thickness = 4.0/64.0*inch;
- public Hybrid(String name, BaseGeometry m) { - super(name, m);
+ public Hybrid(String name, BaseGeometry m, int id) { + super(name, m, id);
init(); } protected void setPos() {
Use REPLY-ALL to reply to list
To unsubscribe from the LCDET-SVN list, click the following link:
https://listserv.slac.stanford.edu/cgi-bin/wa?SUBED1=LCDET-SVN&A=1