> I tried editing the Detector.ini and making the associated component
> java files, but I get complaints at compile/load time that it cannot
> read the file (even if I use a copy of the original with no
> DIRC stuff
> but put it in a different place). I tried various ways of pointing at
> the new location without success. I am about to try editing
> the original
> (on my machine only of course!) where it sits and rebuilding lcd.jar
> itself. Is there an easier way?
In principle you just need to put your new Detector.ini files on the CLASSPATH and then load them. I check with Wolfgang Walkowiak who did this recently, and here is his prescription:
1) Build a directory tree like this:
detector/
detector/l2track099/
detector/l2track099/ClusterParameters.ini
detector/l2track099/Detector.ini
detector/l2track099/FullBarrelResolutionBc.ini
detector/l2track099/FullBarrelResolutionNbc.ini
detector/l2track099/HitSmearing.ini
detector/l2track099/TrackParameters.ini
Note, you need a full set of .ini files, not just Detector.ini. You can copy an appropriate set of files from one of the existing detectors and modify them appropriately.
2) Copy your files into a .jar file using the command
jar cvf MyDetector.jar detector
Check that it worked by using the command jar tvf MyDetector.jar, the output should look like this:
C:\Program Files\Java Analysis Studio -- current\extensions>jar tvf myDetector.jar
0 Tue Mar 13 19:37:40 PST 2001 META-INF/
68 Tue Mar 13 19:37:40 PST 2001 META-INF/MANIFEST.MF
0 Tue Mar 13 18:43:12 PST 2001 detector/
0 Tue Mar 13 18:42:46 PST 2001 detector/l2track099/
387 Sun Oct 22 14:48:04 PDT 2000 detector/l2track099/ClusterParameters.ini
7293 Tue Oct 10 15:44:20 PDT 2000 detector/l2track099/Detector.ini
215265 Thu Oct 05 13:52:36 PDT 2000 detector/l2track099/FullBarrelResolutionBc.ini
215265 Thu Oct 05 13:52:30 PDT 2000 detector/l2track099/FullBarrelResolutionNbc.ini
240 Tue Oct 03 11:33:04 PDT 2000 detector/l2track099/HitSmearing.ini
522 Tue Mar 13 19:37:46 PST 2001 detector/l2track099/TrackParameters.ini
3) Copy the new MyDetector.jar to the same directory as your lcd.jar (probably the extensions director below your JAS installation).
4) Restart JAS
5) In your code, put the line:
Detector.setCurrentDetector(new Detector("/detector/l2track099"));
Tony
|