Import Geant4 8.1.0 source tree

This commit is contained in:
Gabriele Cosmo
2016-06-09 14:44:26 +02:00
parent 8a51e0bc40
commit 216a75eeb1
8717 changed files with 360418 additions and 141343 deletions
@@ -0,0 +1,8 @@
/control/execute macros/DefaultOptions.mac
/control/execute macros/DefaultPhysics.mac
/run/initialize
/control/execute macros/DefaultBeam.mac
/control/execute macros/DefaultMaterials.mac
#/control/execute macros/DefaultView.mac
/control/execute macros/DefaultGeometry.mac
/control/execute macros/DefaultAnalysis.mac
@@ -0,0 +1,52 @@
# $Id: GNUmakefile,v 1.6 2005/11/24 02:34:48 capra Exp $
# --------------------------------------------------------------
# GNUmakefile for examples with internal subpackages
# R. Capra, 09 Sep 2005
# --------------------------------------------------------------
name := Radmon
G4TARGET := $(name)
G4EXLIB := true
SUBDIRS := userActions generalPurpose materials sensitivity detector physics generator
ifdef G4ANALYSIS_USE
SUBDIRS += analysis
endif
SUBDIRS += application
ifndef G4INSTALL
G4INSTALL = ../../..
endif
.PHONY: all bin makesub clean cleansub
all: makesub lib bin
include $(G4INSTALL)/config/binmake.gmk
ifdef G4ANALYSIS_USE
CPPFLAGS += `aida-config --include`
CPPFLAGS += -DG4ANALYSIS_USE
LDFLAGS += `aida-config --lib`
LOADLIBS += `aida-config --lib`
endif
CPPFLAGS += -I./detector/include \
-I./generalPurpose/include \
-I./application/include
makesub:
@for dir in $(SUBDIRS); do ( \
echo Entering $$dir ... ; \
cd $$dir; \
$(MAKE) obj );\
done
clean:: cleansub
cleansub:
@for dir in $(SUBDIRS); do ( \
echo Entering $$dir ...; \
cd $$dir; \
$(MAKE) clean );\
done
+153
View File
@@ -0,0 +1,153 @@
$Id: History,v 1.16 2005/12/06 19:39:09 capra Exp $
-------------------------------------------------------------------
=========================================================
Geant4 - an Object-Oriented Toolkit for Simulation in HEP
=========================================================
Category History file
---------------------
This file should be used by G4 developers and category coordinators to
briefly summarize all major modifications introduced in the code and keep
track of all category-tags.
It DOES NOT substitute the CVS log-message one should put at every committal
in the CVS repository !
----------------------------------------------------------
* Reverse chronological order (last date on top), please *
----------------------------------------------------------
06 Dec 2005 - radmon-V07-01-14 - R. Capra - Documentation extended README
file now covers all the aspects of the application
in great details. Small changes in RadmonApplication
and RadmonApplicationAnalysisSetup so that when
G4ANALYSIS_USE is not set, code builds without
analysis. RadmonPhysicsList changed in order to
manage particles changes present from tag
geant4-08-00-cand01. Stepping action added in order
to manage these changes. Errors present in
RadmonPhysicsHadronsBertini, RadmonPhysicsDecay,
RadmonPhysicsICRUIonization corrected. The error
present in RadmonPhysicsHadronsBertini caused the
application crash. The error present in
RadmonPhysicsDecay, RadmonPhysicsICRUIonization
caused a not true warning message appear.
25 Nov 2005 - radmon-V07-01-13 - R. Capra - Introduced step limitations and
secondary production thresholds. Geometry materials
corrected.
- Code tested against materials overlapping
- Small corrections in RadmonPhysicsInoisationICRU and
RadmonPhysicsDecay
25 Nov 2005 - radmon-V07-01-12 - R. Capra - Analysis framework completed
hadronic physics implemented. First analysis module
implemented.
24 Nov 2005 - radmon-V07-01-11 - R. Capra - Development of the analysis
code. Framwork partially completed. Sensitive
detectors not linked to Geometry yet.
RadmonAnalysis methods have a dummy implementation.
Introduced changes are:
- Analysis code (partial)
- Tracks display
- Event/Run number dump
- Small corrections (grammar, comments)
- RadmonPhysicsList::OnLayoutChange behaviur changed
(better performances)
- Macros updated according to current developments
Code builds and runs. Analysis stuff still not
completely working.
07 Nov 2005 - radmon-V07-01-10 - R. Capra - Development of the physics list
code. Framework completed and working. Insertion of
modular physics list in progress. Current physics
models are:
- Electron: EEDL, Standard
- Photon: EPDL, Standard
- Positron: Standard
- Muon+/-: Standard
- Tau+/-: Standard
- Neutron: Binary Cascade
- Decay for all short living particles
- Nuclear reactions of photons and e+/- on nuclei
Small corrections to some primary generator
algorithms
Default macros for beam and physics defined
Code builds, test in progress
07 Nov 2005 - radmon-V07-01-09 - R. Capra - Development of the physics list
code:
- RadmonPhysicsDummyPhysicsList class removed
Code builds, but not tested yet. Physics list still
to be implemented
25 Oct 2005 - radmon-V07-01-08 - R. Capra - Development of the particle
generator according to the design:
- Minor changes in the detector package.
- RadmonApplication has been splietted into classes
for management purposes and in order to improve
the compilation time and dependencies.
- Completely new generator package with a design
similar to the detector one.
Code builds. Primary generator code not tested yet.
24 Oct 2005 - radmon-V07-01-07 - R. Capra - Design iteration: classes:
- RadmonVDetectorLayoutObserver
- RadmonVDetectorLayoutSubject
- RadmonDetectorLayoutEntityWithAttributes
has been moved in generalPurpose package without the
Detector suffix. They will be used for the primary
generator too.
30 Sep 2005 - radmon-V07-01-06 - R. Capra - Implementation according to the
design. The layer with pads needed for detectors
layout has been now implemented.
Macros to generate the real packaging geometry has
been provided.
27 Sep 2005 - radmon-V07-01-05 - R. Capra - Implementation according to the
design. All the packaging layers are now
implemented. Trasparency support (alpha channel)
has been provided.
21 Sep 2005 - radmon-V07-01-04 - R. Capra - Implementation according to the
design almost completed. Following functionality
added:
- Alpha channel support for attributes
- Carved geometry decorator
- Hole geometry decorator
19 Sep 2005 - radmon-V07-01-03 - R. Capra - Implementation according to the
design in progress. Following functionality added:
- Materials creation through a messenger
- Geometry creation and update
- First Geometry constructor object created (Simple
box)
- Macros directory created
14 Sep 2005 - radmon-V07-01-02 - R. Capra - Implementation according to the
design in progress. RadmonDetectorMessenger completed
and tested. Needs still some work on detector
construction and materials. The code runs. Creation
of the physics subpackage. This tag is only for
backup purposes
12 Sep 2005 - radmon-V07-01-01 - R. Capra - Implementation according to the
design in progress. RadmonDetectorLayout completed
Needs still some work Messenger and detector
construction and materials . The code does not run
but should build. This tag is only for backup
purposes
09 Sep 2005 - radmon-V07-01-00 - R. Capra - Internal subdirectories created
and GNUmakefile(s). Implementation according to the
design in progress. The code does not builds.
This tag is only for backup purposes
File diff suppressed because it is too large Load Diff
@@ -0,0 +1,68 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: Radmon.cc
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: Radmon.cc,v 1.3 2006/06/29 16:06:29 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Description: Application main file
//
// Include files
#include <cstdlib>
#include <iostream>
#include <fstream>
#include "RadmonApplicationOptions.hh"
#include "RadmonApplication.hh"
// Main
int main(int argc, char * * argv)
{
RadmonApplicationOptions options(argc, argv);
if (!options.Valid())
return EXIT_FAILURE;
if (options.Help())
{
options.DumpHelp();
return EXIT_SUCCESS;
}
RadmonApplication application(options);
if (!application.Valid())
return EXIT_FAILURE;
G4cout << options.ApplicationName() << ": Application ended successfully." << G4endl;
return EXIT_SUCCESS;
}
@@ -0,0 +1,51 @@
# $Id: GNUmakefile,v 1.1 2005/11/24 02:33:32 capra Exp $
# --------------------------------------------------------------------
# GNUmakefile for exaple subpackage
# R. Capra, 09 Sep 2005
# --------------------------------------------------------------------
name := Radmon
ifndef G4INSTALL
G4INSTALL = ../../../..
endif
include $(G4INSTALL)/config/architecture.gmk
include $(G4INSTALL)/config/G4UI_USE.gmk
include $(G4INSTALL)/config/G4VIS_USE.gmk
include $(G4INSTALL)/config/interactivity.gmk
CPPFLAGS += -I$(G4BASE)/global/management/include \
-I$(G4BASE)/global/HEPGeometry/include \
-I$(G4BASE)/global/HEPRandom/include \
-I$(G4BASE)/intercoms/include \
-I$(G4BASE)/interfaces/basic/include \
-I$(G4BASE)/interfaces/common/include \
-I$(G4BASE)/run/include \
-I$(G4BASE)/event/include \
-I$(G4BASE)/tracking/include \
-I$(G4BASE)/track/include \
-I$(G4BASE)/geometry/management/include \
-I$(G4BASE)/geometry/navigation/include \
-I$(G4BASE)/geometry/volumes/include \
-I$(G4BASE)/geometry/solids/CSG/include \
-I$(G4BASE)/geometry/solids/Boolean/include \
-I$(G4BASE)/particles/management/include \
-I$(G4BASE)/materials/include \
-I$(G4BASE)/processes/management/include \
-I$(G4BASE)/processes/cuts/include \
-I$(G4BASE)/digits_hits/hits/include \
-I$(G4BASE)/digits_hits/digits/include \
-I$(G4BASE)/digits_hits/detector/include \
-I$(G4BASE)/visualization/management/include \
-I$(G4BASE)/graphics_reps/include \
-I../generalPurpose/include \
-I../sensitivity/include \
-I../userActions/include
CPPFLAGS += `aida-config --include`
CPPFLAGS += -DG4ANALYSIS_USE
LDFLAGS += `aida-config --lib`
LOADLIBS += `aida-config --lib`
include $(G4INSTALL)/config/common.gmk
@@ -0,0 +1,104 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonAnalysis.hh
// Creation date: Nov 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonAnalysis.hh,v 1.4 2006/06/29 16:06:41 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Description: Analysis main class
//
#ifndef RADMONANALYSIS_HH
#define RADMONANALYSIS_HH
// Include files
#include "globals.hh"
#include "RadmonEventActionObserver.hh"
#include "RadmonVLayoutObserver.hh"
#include "AIDA/IAnalysisFactory.h"
#include "AIDA/ITreeFactory.h"
#include "AIDA/ITree.h"
#include "AIDA/ITupleFactory.h"
#include "AIDA/ITuple.h"
#include <utility>
#include <list>
// Forward declaration
class RadmonVDataAnalysisFactory;
class RadmonVDataAnalysis;
class RadmonVAnalysisLayout;
class RadmonSensitiveDetector;
class RadmonAnalysis : public RadmonEventActionObserver, public RadmonVLayoutObserver
{
public:
RadmonAnalysis(RadmonVAnalysisLayout * layout, RadmonVDataAnalysisFactory * factory, AIDA::IAnalysisFactory * analysis);
virtual ~RadmonAnalysis();
virtual void OnLayoutChange(void);
virtual void OnBeginOfEvent(const G4Event * event);
virtual void OnEndOfEvent(const G4Event * event);
private:
// Private methods
G4bool InitializeSensitiveDetectorsList(std::list<G4String> & tupleLabels, G4String & columns);
G4bool OpenFile(void);
G4bool InitializeTuple(const std::list<G4String> & tupleLabels, const G4String & columns);
void Destruct(void);
// Hidden constructors and operators
RadmonAnalysis();
RadmonAnalysis(const RadmonAnalysis & copy);
RadmonAnalysis & operator=(const RadmonAnalysis & copy);
// Private data types
typedef std::list<RadmonVDataAnalysis *> DataAnalysesList;
typedef std::pair<RadmonSensitiveDetector *, DataAnalysesList *> SensitiveDetectorPair;
typedef std::list<SensitiveDetectorPair> SensitiveDetectorsList;
// Private attributes
RadmonVAnalysisLayout * analysisLayout;
RadmonVDataAnalysisFactory * dataFactory;
AIDA::IAnalysisFactory * analysisFactory;
AIDA::ITreeFactory * treeFactory;
AIDA::ITree * tree;
AIDA::ITupleFactory * tupleFactory;
AIDA::ITuple * tuple;
G4int indexRunId;
G4int indexEventId;
G4bool changed;
SensitiveDetectorsList sensitiveDetectorsList;
};
#endif /* RADMONANALYSIS_HH */
@@ -0,0 +1,112 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonAnalysisLayout.hh
// Creation date: Nov 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonAnalysisLayout.hh,v 1.3 2006/06/29 16:06:44 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Description: Concrete class to keep track of the analysis options
//
#ifndef RADMONANALYSISLAYOUT_HH
#define RADMONANALYSISLAYOUT_HH
// Include files
#include "RadmonVAnalysisLayout.hh"
#include "RadmonAnalysisSensitiveDetectorTypeLayout.hh"
#include "RadmonTLabelledCollection.hh"
#include "globals.hh"
#include <vector>
#include <utility>
class RadmonAnalysisLayout : public RadmonVAnalysisLayout
{
public:
RadmonAnalysisLayout();
~RadmonAnalysisLayout();
virtual void SetOutputFileName(const G4String & outputFileName);
virtual const G4String & GetOutputFileName(void) const;
virtual void SetOutputFileFormat(const G4String & outputFileFormat);
virtual const G4String & GetOutputFileFormat(void) const;
virtual void CreateSensitiveDetector(const G4String & sensitiveDetectorLabel, const G4String & sensitiveDetectorType);
virtual void SetSensitiveDetectorType(const G4String & sensitiveDetectorLabel, const G4String & sensitiveDetectorType);
virtual const G4String & GetSensitiveDetectorType(const G4String & sensitiveDetectorLabel) const;
virtual void RemoveSensitiveDetector(const G4String & sensitiveDetectorLabel);
virtual G4int GetNSensitiveDetectors(void) const;
virtual const G4String & GetSensitiveDetectorLabel(G4int index) const;
virtual void CreateSensitiveDetectorType(const G4String & sensitiveDetectorTypeLabel);
virtual void RemoveSensitiveDetectorType(const G4String & sensitiveDetectorTypeLabel);
virtual void AppendDataAnalysisToSensitiveDetectorType(const G4String & sensitiveDetectorTypeLabel, const G4String & dataAnalysisLabel);
virtual void SetDataAnalysisType(const G4String & sensitiveDetectorTypeLabel, const G4String & dataAnalysisLabel, const G4String & dataAnalysisType);
virtual void RemoveDataAnalysis(const G4String & sensitiveDetectorTypeLabel, const G4String & dataAnalysisLabel);
virtual G4int GetNDataAnalyses(const G4String & sensitiveDetectorTypeLabel) const;
virtual const G4String & GetDataAnalysisLabel(const G4String & sensitiveDetectorTypeLabel, G4int index) const;
virtual const G4String & GetDataAnalysisType(const G4String & sensitiveDetectorTypeLabel, const G4String & dataAnalysisLabel) const;
virtual void SetDataAnalysisAttribute(const G4String & sensitiveDetectorTypeLabel, const G4String & dataAnalysisLabel, const G4String & attributeName, const G4String & attributeValue);
virtual void ClearDataAnalysisAttribute(const G4String & sensitiveDetectorTypeLabel, const G4String & dataAnalysisLabel, const G4String & attributeName);
virtual G4int GetDataAnalysisNAttributes(const G4String & sensitiveDetectorTypeLabel, const G4String & dataAnalysisLabel) const;
virtual G4String GetDataAnalysisAttributeName(const G4String & sensitiveDetectorTypeLabel, const G4String & dataAnalysisLabel, G4int index) const;
virtual G4String GetDataAnalysisAttribute(const G4String & sensitiveDetectorTypeLabel, const G4String & dataAnalysisLabel, const G4String & attributeName, const G4String & defaultAttributeValue=G4String()) const;
virtual void DumpLayout(std::ostream & out) const;
virtual G4bool Load(std::istream & in);
virtual G4bool Save(std::ostream & out) const;
private:
typedef std::pair<G4String, G4String> SensitiveDetector;
typedef std::vector<SensitiveDetector> SensitiveDetectors;
inline G4bool SensitiveDetectorTypeInUse(const G4String & sensitiveDetectorType);
inline G4bool ExistsSensitiveDetector(const G4String & sensitiveDetectorLabel) const;
inline SensitiveDetector * FindSensitiveDetector(const G4String & sensitiveDetectorLabel);
inline const SensitiveDetector * FindSensitiveDetector(const G4String & sensitiveDetectorLabel) const;
inline RadmonAnalysisSensitiveDetectorTypeLayout * FindSensitiveDetectorType(const G4String & sensitiveDetectorTypeLabel);
inline const RadmonAnalysisSensitiveDetectorTypeLayout * FindSensitiveDetectorType(const G4String & sensitiveDetectorTypeLabel) const;
inline RadmonDataAnalysisLayout * FindDataAnalysis(const G4String & sensitiveDetectorTypeLabel, const G4String & dataAnalysisLabel);
inline const RadmonDataAnalysisLayout * FindDataAnalysis(const G4String & sensitiveDetectorTypeLabel, const G4String & dataAnalysisLabel) const;
inline G4String & GetNullStr() const;
// Hidden constructors and operators
RadmonAnalysisLayout(const RadmonAnalysisLayout & copy);
RadmonAnalysisLayout & operator=(const RadmonAnalysisLayout & copy);
G4String fileName;
G4String fileFormat;
SensitiveDetectors sensitiveDetectors;
RadmonTLabelledCollection<RadmonAnalysisSensitiveDetectorTypeLayout> sensitiveDetectorTypes;
};
#endif /* RADMONANALYSISLAYOUT_HH */
@@ -0,0 +1,87 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonDetectorMessenger.hh
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonAnalysisMessenger.hh,v 1.3 2006/06/29 16:06:47 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Description: UI commands for managing a layout
//
#ifndef RADMONANALYSISMESSENGER_HH
#define RADMONANALYSISMESSENGER_HH
// Include files
#include "RadmonMessenger.hh"
#include "G4String.hh"
// Forward declarations
class RadmonVAnalysisLayout;
class RadmonAnalysisMessenger : public RadmonMessenger
{
public:
RadmonAnalysisMessenger(RadmonVAnalysisLayout * layout);
~RadmonAnalysisMessenger();
virtual G4String GetCurrentValue(G4UIcommand * command);
virtual void SetNewValue(G4UIcommand * command, G4String newValue);
private:
// Hidden constructors and operators
RadmonAnalysisMessenger();
RadmonAnalysisMessenger(const RadmonAnalysisMessenger & copy);
RadmonAnalysisMessenger & operator=(const RadmonAnalysisMessenger & copy);
// Private Attributes
RadmonVAnalysisLayout * analysisLayout;
// Commands
RADMON_DECLARE_COMMAND(SetOutputFileName);
RADMON_DECLARE_COMMAND(SetOutputFileFormat);
RADMON_DECLARE_COMMAND(CreateSensitiveDetector);
RADMON_DECLARE_COMMAND(SetSensitiveDetectorType);
RADMON_DECLARE_COMMAND(RemoveSensitiveDetector);
RADMON_DECLARE_COMMAND(CreateSensitiveDetectorType);
RADMON_DECLARE_COMMAND(RemoveSensitiveDetectorType);
RADMON_DECLARE_COMMAND(AppendDataAnalysisToSensitiveDetectorType);
RADMON_DECLARE_COMMAND(SetDataAnalysisType);
RADMON_DECLARE_COMMAND(RemoveDataAnalysis);
RADMON_DECLARE_COMMAND(SetDataAnalysisAttribute);
RADMON_DECLARE_COMMAND(ClearDataAnalysisAttribute);
RADMON_DECLARE_COMMAND(DumpLayout);
RADMON_DECLARE_COMMAND(Load);
RADMON_DECLARE_COMMAND(Save);
};
#endif /* RADMONANALYSISMESSENGER_HH */
@@ -0,0 +1,89 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonAnalysisSensitiveDetectorTypeLayout.hh
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonAnalysisSensitiveDetectorTypeLayout.hh,v 1.3 2006/06/29 16:06:49 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Description: Internal class to manage sensitive detector types
//
#ifndef RADMONANALYSISSENSITIVEDETECTORTYPELAYOUT_HH
#define RADMONANALYSISSENSITIVEDETECTORTYPELAYOUT_HH
// Include files
#include "RadmonDataAnalysisLayout.hh"
#include "RadmonTLabelledCollection.hh"
#include "G4String.hh"
#include "globals.hh"
class RadmonAnalysisSensitiveDetectorTypeLayout
{
public:
inline RadmonAnalysisSensitiveDetectorTypeLayout();
RadmonAnalysisSensitiveDetectorTypeLayout(const RadmonAnalysisSensitiveDetectorTypeLayout & copy);
inline ~RadmonAnalysisSensitiveDetectorTypeLayout();
RadmonAnalysisSensitiveDetectorTypeLayout & operator=(const RadmonAnalysisSensitiveDetectorTypeLayout & copy);
inline const G4String & GetLabel(void) const;
inline void SetLabel(const G4String & label);
G4int GetNDataAnalyses(void) const;
G4bool Empty(void) const;
const RadmonDataAnalysisLayout & GetDataAnalysis(G4int index) const;
RadmonDataAnalysisLayout & GetDataAnalysis(G4int index);
G4bool ExistsDataAnalysisByLabel(const G4String & dataAnalysisLabel) const;
G4int MultiplicityDataAnalysisByLabel(const G4String & dataAnalysisLabel) const;
const RadmonDataAnalysisLayout & FindDataAnalysisByLabel(const G4String & dataAnalysisLabel, G4int count = 0) const;
RadmonDataAnalysisLayout & FindDataAnalysisByLabel(const G4String & dataAnalysisLabel, G4int count = 0);
RadmonDataAnalysisLayout & AppendDataAnalysis(void);
RadmonDataAnalysisLayout & PrependDataAnalysis(void);
void RemoveDataAnalysisByLabel(const G4String & dataAnalysisLabel, G4int count = 0);
void RemoveDataAnalysesByLabel(const G4String & dataAnalysisLabel);
void RemoveDataAnalysis(G4int index);
void RemoveDataAnalysesByRange(G4int first, G4int last);
void RemoveAllDataAnalyses(void);
void DumpLayout(std::ostream & out, const G4String & indent=G4String()) const;
private:
// Private attributes
G4String sensitiveDetectorLabel;
RadmonTLabelledCollection<RadmonDataAnalysisLayout> dataAnalysesCollection;
};
// Inline implementations
#include "RadmonAnalysisSensitiveDetectorTypeLayout.icc"
#endif /* RADMONANALYSISSENSITIVEDETECTORTYPELAYOUT_HH */
@@ -0,0 +1,63 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonAnalysisSensitiveDetectorTypeLayout.icc
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonAnalysisSensitiveDetectorTypeLayout.icc,v 1.3 2006/06/29 16:06:51 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
#ifndef RADMONANALYSISSENSITIVEDETECTORTYPELAYOUT_HH
#error "RadmonAnalysisSensitiveDetectorTypeLayout.icc cannot be included directly. Please use RadmonAnalysisSensitiveDetectorTypeLayout.hh"
#else /* RADMONANALYSISSENSITIVEDETECTORTYPELAYOUT_HH */
inline RadmonAnalysisSensitiveDetectorTypeLayout :: RadmonAnalysisSensitiveDetectorTypeLayout()
{
}
inline RadmonAnalysisSensitiveDetectorTypeLayout :: ~RadmonAnalysisSensitiveDetectorTypeLayout()
{
}
inline const G4String & RadmonAnalysisSensitiveDetectorTypeLayout :: GetLabel(void) const
{
return sensitiveDetectorLabel;
}
inline void RadmonAnalysisSensitiveDetectorTypeLayout :: SetLabel(const G4String & label)
{
sensitiveDetectorLabel=label;
}
#endif /* RADMONANALYSISSENSITIVEDETECTORTYPELAYOUT_HH */
@@ -0,0 +1,67 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonDataAnalysisDepositedEnergy.hh
// Creation date: Nov 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonDataAnalysisDepositedEnergy.hh,v 1.3 2006/06/29 16:06:53 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Description: Energy deposit analysis
//
#ifndef RADMONDATAANALYSISDEPOSITEDENERGY_HH
#define RADMONDATAANALYSISDEPOSITEDENERGY_HH
// Include files
#include "RadmonVDataAnalysisWithLabel.hh"
class RadmonDataAnalysisDepositedEnergy : public RadmonVDataAnalysisWithLabel
{
public:
RadmonDataAnalysisDepositedEnergy();
inline virtual ~RadmonDataAnalysisDepositedEnergy();
virtual RadmonVDataAnalysisWithLabel * New(void) const;
virtual G4String ObtainColumnsDeclaration(const G4String & prefix);
virtual void InitializeFromTuple(const G4String & prefix, const AIDA::ITuple * tuple);
virtual void StoreIntoTuple(RadmonHitsCollection * hitsCollection, AIDA::ITuple * tuple);
virtual void StoreIntoHit(G4Step * step, RadmonHit * hit);
private:
// Hidden constructors and operators
RadmonDataAnalysisDepositedEnergy(const RadmonDataAnalysisDepositedEnergy & copy);
RadmonDataAnalysisDepositedEnergy & operator=(const RadmonDataAnalysisDepositedEnergy & copy);
// Private attributes
G4int indexHitEnergyDeposit;
G4int indexTupleEnergyDeposit;
};
#include "RadmonDataAnalysisDepositedEnergy.icc"
#endif /* RADMONDATAANALYSISDEPOSITEDENERGY_HH */
@@ -0,0 +1,41 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonDataAnalysisDepositedEnergy.icc
// Creation date: Nov 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonDataAnalysisDepositedEnergy.icc,v 1.3 2006/06/29 16:06:55 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
#ifndef RADMONDATAANALYSISDEPOSITEDENERGY_HH
#error "RadmonDataAnalysisDepositedEnergy.icc cannot be included directly. Please use RadmonDataAnalysisDepositedEnergy.hh"
#else /* RADMONDATAANALYSISDEPOSITEDENERGY_HH */
inline RadmonDataAnalysisDepositedEnergy :: ~RadmonDataAnalysisDepositedEnergy()
{
}
#endif /* RADMONDATAANALYSISDEPOSITEDENERGY_HH */
@@ -0,0 +1,68 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonDataAnalysisLayout.hh
// Creation date: Nov 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonDataAnalysisLayout.hh,v 1.3 2006/06/29 16:06:57 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Description: Internal class that describes layer informations
//
#ifndef RADMONDATAANALYSISLAYOUT_HH
#define RADMONDATAANALYSISLAYOUT_HH
// Include files
#include "RadmonLayoutEntityWithAttributes.hh"
class RadmonDataAnalysisLayout : public RadmonLayoutEntityWithAttributes
{
public:
inline RadmonDataAnalysisLayout();
inline RadmonDataAnalysisLayout(const RadmonDataAnalysisLayout & copy);
inline ~RadmonDataAnalysisLayout();
inline RadmonDataAnalysisLayout & operator=(const RadmonDataAnalysisLayout & copy);
inline const G4String & GetLabel(void) const;
inline void SetLabel(const G4String & label);
inline const G4String & GetType(void) const;
inline void SetType(const G4String & type);
void DumpLayout(std::ostream & out, const G4String &indent=G4String()) const;
private:
// Private attributes
G4String dataAnalysisLabel;
G4String dataAnalysisType;
};
// Inline implementations
#include "RadmonDataAnalysisLayout.icc"
#endif /* RADMONDATAANALYSISLAYOUT_HH */
@@ -0,0 +1,100 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonDataAnalysisLayout.icc
// Creation date: Nov 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonDataAnalysisLayout.icc,v 1.3 2006/06/29 16:07:01 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
#ifndef RADMONDATAANALYSISLAYOUT_HH
#error "RadmonDataAnalysisLayout.icc cannot be included directly. Please use RadmonDataAnalysisLayout.hh"
#else /* RADMONDATAANALYSISLAYOUT_HH */
inline RadmonDataAnalysisLayout :: RadmonDataAnalysisLayout()
{
}
inline RadmonDataAnalysisLayout :: RadmonDataAnalysisLayout(const RadmonDataAnalysisLayout & copy)
:
RadmonLayoutEntityWithAttributes(copy),
dataAnalysisLabel(copy.dataAnalysisLabel),
dataAnalysisType(copy.dataAnalysisType)
{
}
inline RadmonDataAnalysisLayout :: ~RadmonDataAnalysisLayout()
{
}
inline RadmonDataAnalysisLayout & RadmonDataAnalysisLayout :: operator=(const RadmonDataAnalysisLayout & copy)
{
RadmonLayoutEntityWithAttributes::operator=(copy);
dataAnalysisLabel=copy.dataAnalysisLabel;
dataAnalysisType=copy.dataAnalysisType;
return (*this);
}
inline const G4String & RadmonDataAnalysisLayout :: GetLabel(void) const
{
return dataAnalysisLabel;
}
inline void RadmonDataAnalysisLayout :: SetLabel(const G4String & label)
{
dataAnalysisLabel=label;
}
inline const G4String & RadmonDataAnalysisLayout :: GetType(void) const
{
return dataAnalysisType;
}
inline void RadmonDataAnalysisLayout :: SetType(const G4String & type)
{
dataAnalysisType=type;
}
#endif /* RADMONDATAANALYSISLAYOUT_HH */
@@ -0,0 +1,71 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonDataAnalysisWithLabelFactory.hh
// Creation date: Nov 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonDataAnalysisWithLabelFactory.hh,v 1.3 2006/06/29 16:07:05 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Description: Concrete factory that constructs
// RadmonSubPhysiscsListWithLabel objects
//
#ifndef RADMONDATAANALYSISWITHLABELFACTORY_HH
#define RADMONDATAANALYSISWITHLABELFACTORY_HH
// Include files
#include "RadmonVDataAnalysisFactory.hh"
#include <list>
// Forward declarations
class RadmonVDataAnalysis;
class RadmonVDataAnalysisWithLabel;
class RadmonDataAnalysisWithLabelFactory : public RadmonVDataAnalysisFactory
{
public:
inline RadmonDataAnalysisWithLabelFactory();
virtual ~RadmonDataAnalysisWithLabelFactory();
virtual RadmonVDataAnalysis * CreateDataAnalysis(const G4String & dataAnalysisName);
void AppendDataAnalysisWithLabel(RadmonVDataAnalysisWithLabel * physicsList);
private:
// Hidden constructors and operators
RadmonDataAnalysisWithLabelFactory(const RadmonDataAnalysisWithLabelFactory & copy);
RadmonDataAnalysisWithLabelFactory & operator=(const RadmonDataAnalysisWithLabelFactory & copy);
// Private attributes
typedef std::list<RadmonVDataAnalysisWithLabel *> DataAnalyses;
DataAnalyses dataAnalyses;
};
// Inline implementations
#include "RadmonDataAnalysisWithLabelFactory.icc"
#endif /* RADMONDATAANALYSISWITHLABELFACTORY_HH */
@@ -0,0 +1,41 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonDataAnalysisWithLabelFactory.icc
// Creation date: Nov 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonDataAnalysisWithLabelFactory.icc,v 1.3 2006/06/29 16:07:07 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
#ifndef RADMONDATAANALYSISWITHLABELFACTORY_HH
#error "RadmonDataAnalysisWithLabelFactory.icc cannot be included directly. Please use RadmonDataAnalysisWithLabelFactory.hh"
#else /* RADMONDATAANALYSISWITHLABELFACTORY_HH */
inline RadmonDataAnalysisWithLabelFactory :: RadmonDataAnalysisWithLabelFactory()
{
}
#endif /* RADMONDATAANALYSISWITHLABELFACTORY_HH */
@@ -0,0 +1,74 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonDataAnalysisWithLabelMessenger.hh
// Creation date: Nov 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonDataAnalysisWithLabelMessenger.hh,v 1.3 2006/06/29 16:07:09 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Description: UI commands for dumping the available constructors
//
#ifndef RADMONDATAANALYSISWITHLABELMESSENGER_HH
#define RADMONDATAANALYSISWITHLABELMESSENGER_HH
// Include files
#include "RadmonMessenger.hh"
#include "G4String.hh"
#include <set>
class RadmonDataAnalysisWithLabelMessenger : public RadmonMessenger
{
public:
static RadmonDataAnalysisWithLabelMessenger * Instance(void);
void AddAvailableDataAnalysis(const G4String & name);
void RemoveAvailableDataAnalysis(const G4String & name);
virtual G4String GetCurrentValue(G4UIcommand * command);
virtual void SetNewValue(G4UIcommand * command, G4String newValue);
private:
// Hidden constructors and operators
RadmonDataAnalysisWithLabelMessenger();
RadmonDataAnalysisWithLabelMessenger(const RadmonDataAnalysisWithLabelMessenger & copy);
~RadmonDataAnalysisWithLabelMessenger();
RadmonDataAnalysisWithLabelMessenger & operator=(const RadmonDataAnalysisWithLabelMessenger & copy);
// Private Data Types
typedef std::set<G4String> AvailableDataAnalyses;
// Private variables
AvailableDataAnalyses availableDataAnalyses;
static RadmonDataAnalysisWithLabelMessenger * instance;
// Commands
RADMON_DECLARE_COMMAND(Dump);
};
#endif /* RADMONDATAANALYSISWITHLABELMESSENGER_HH */
@@ -0,0 +1,93 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonVAnalysisLayout.hh
// Creation date: Nov 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonVAnalysisLayout.hh,v 1.1.2.2 2006/06/29 16:07:11 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Description: Abstract class to keep track of the analysis options
//
#ifndef RADMONVANALYSISLAYOUT_HH
#define RADMONVANALYSISLAYOUT_HH
// Include files
#include "RadmonVLayoutSubject.hh"
#include "globals.hh"
class RadmonVAnalysisLayout : public RadmonVLayoutSubject
{
public:
virtual void SetOutputFileName(const G4String & outputFileName) = 0;
virtual const G4String & GetOutputFileName(void) const = 0;
virtual void SetOutputFileFormat(const G4String & outputFileFormat) = 0;
virtual const G4String & GetOutputFileFormat(void) const = 0;
virtual void CreateSensitiveDetector(const G4String & sensitiveDetectorLabel, const G4String & sensitiveDetectorType) = 0;
virtual void SetSensitiveDetectorType(const G4String & sensitiveDetectorLabel, const G4String & sensitiveDetectorType) = 0;
virtual const G4String & GetSensitiveDetectorType(const G4String & sensitiveDetectorLabel) const = 0;
virtual void RemoveSensitiveDetector(const G4String & sensitiveDetectorLabel) = 0;
virtual G4int GetNSensitiveDetectors(void) const = 0;
virtual const G4String & GetSensitiveDetectorLabel(G4int index) const = 0;
virtual void CreateSensitiveDetectorType(const G4String & sensitiveDetectorTypeLabel) = 0;
virtual void RemoveSensitiveDetectorType(const G4String & sensitiveDetectorTypeLabel) = 0;
virtual void AppendDataAnalysisToSensitiveDetectorType(const G4String & sensitiveDetectorTypeLabel, const G4String & dataAnalysisLabel) = 0;
virtual void SetDataAnalysisType(const G4String & sensitiveDetectorTypeLabel, const G4String & dataAnalysisLabel, const G4String & dataAnalysisType) = 0;
virtual void RemoveDataAnalysis(const G4String & sensitiveDetectorTypeLabel, const G4String & dataAnalysisLabel) = 0;
virtual G4int GetNDataAnalyses(const G4String & sensitiveDetectorTypeLabel) const = 0;
virtual const G4String & GetDataAnalysisLabel(const G4String & sensitiveDetectorTypeLabel, G4int index) const = 0;
virtual const G4String & GetDataAnalysisType(const G4String & sensitiveDetectorTypeLabel, const G4String & dataAnalysisLabel) const = 0;
virtual void SetDataAnalysisAttribute(const G4String & sensitiveDetectorTypeLabel, const G4String & dataAnalysisLabel, const G4String & attributeName, const G4String & attributeValue) = 0;
virtual void ClearDataAnalysisAttribute(const G4String & sensitiveDetectorTypeLabel, const G4String & dataAnalysisLabel, const G4String & attributeName) = 0;
virtual G4int GetDataAnalysisNAttributes(const G4String & sensitiveDetectorTypeLabel, const G4String & dataAnalysisLabel) const = 0;
virtual G4String GetDataAnalysisAttributeName(const G4String & sensitiveDetectorTypeLabel, const G4String & dataAnalysisLabel, G4int index) const = 0;
virtual G4String GetDataAnalysisAttribute(const G4String & sensitiveDetectorTypeLabel, const G4String & dataAnalysisLabel, const G4String & attributeName, const G4String & defaultAttributeValue=G4String()) const = 0;
virtual void DumpLayout(std::ostream & out) const = 0;
virtual G4bool Load(std::istream & in) = 0;
virtual G4bool Save(std::ostream & out) const = 0;
protected:
inline RadmonVAnalysisLayout();
inline ~RadmonVAnalysisLayout();
private:
// Hidden constructors and operators
RadmonVAnalysisLayout(const RadmonVAnalysisLayout & copy);
RadmonVAnalysisLayout & operator=(const RadmonVAnalysisLayout & copy);
};
// Inline implementations
#include "RadmonVAnalysisLayout.icc"
#endif /* RADMONVANALYSISLAYOUT_HH */
@@ -0,0 +1,47 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonVAnalysisLayout.icc
// Creation date: Nov 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonVAnalysisLayout.icc,v 1.3 2006/06/29 16:07:13 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
#ifndef RADMONVANALYSISLAYOUT_HH
#error "RadmonVAnalysisLayout.icc cannot be included directly. Please use RadmonVAnalysisLayout.hh"
#else /* RADMONVANALYSISLAYOUT_HH */
inline RadmonVAnalysisLayout :: RadmonVAnalysisLayout()
{
}
inline RadmonVAnalysisLayout :: ~RadmonVAnalysisLayout()
{
}
#endif /* RADMONVANALYSISLAYOUT_HH */
@@ -0,0 +1,68 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonVDataAnalysis.hh
// Creation date: Nov 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonVDataAnalysis.hh,v 1.4 2006/06/29 16:07:15 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Description: Abstract class of an analysis piece
//
#ifndef RADMONVDATAANALYSIS_HH
#define RADMONVDATAANALYSIS_HH
// Include files
#include "RadmonSensitiveDetectorDataStorer.hh"
#include "RadmonHit.hh"
#include "G4String.hh"
#include "AIDA/ITuple.h"
class RadmonVDataAnalysis : public RadmonSensitiveDetectorDataStorer
{
public:
inline virtual ~RadmonVDataAnalysis();
virtual void SetDataAnalysisAttribute(const G4String & attributeName, const G4String &value) = 0;
virtual G4String ObtainColumnsDeclaration(const G4String & prefix) = 0;
virtual void InitializeFromTuple(const G4String & prefix, const AIDA::ITuple * tuple) = 0;
virtual void StoreIntoTuple(RadmonHitsCollection * hitsCollection, AIDA::ITuple * tuple) = 0;
protected:
inline RadmonVDataAnalysis();
private:
// Hidden constructors and operators
RadmonVDataAnalysis(const RadmonVDataAnalysis & copy);
RadmonVDataAnalysis & operator=(const RadmonVDataAnalysis & copy);
};
// Inline implementations
#include "RadmonVDataAnalysis.icc"
#endif /* RADMONVDATAANALYSIS_HH */
@@ -0,0 +1,47 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonVDataAnalysis.icc
// Creation date: Nov 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonVDataAnalysis.icc,v 1.3 2006/06/29 16:07:17 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
#ifndef RADMONVDATAANALYSIS_HH
#error "RadmonVDataAnalysis.icc cannot be included directly. Please use RadmonVDataAnalysis.hh"
#else /* RADMONVDATAANALYSIS_HH */
inline RadmonVDataAnalysis :: RadmonVDataAnalysis()
{
}
inline RadmonVDataAnalysis :: ~RadmonVDataAnalysis()
{
}
#endif /* RADMONVDATAANALYSIS_HH */
@@ -0,0 +1,62 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonVDataAnalysisFactory.hh
// Creation date: Nov 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonVDataAnalysisFactory.hh,v 1.1.2.2 2006/06/29 16:07:19 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Description: Abstract class of a factory of analysis items
//
#ifndef RADMONVDATAANALYSISFACTORY_HH
#define RADMONVDATAANALYSISFACTORY_HH
// Forward declaration
class RadmonVDataAnalysis;
class G4String;
class RadmonVDataAnalysisFactory
{
public:
inline virtual ~RadmonVDataAnalysisFactory();
virtual RadmonVDataAnalysis * CreateDataAnalysis(const G4String & dataAnalysis) = 0;
protected:
inline RadmonVDataAnalysisFactory();
private:
// Hidden constructors and operators
RadmonVDataAnalysisFactory(const RadmonVDataAnalysisFactory & copy);
RadmonVDataAnalysisFactory & operator=(const RadmonVDataAnalysisFactory & copy);
};
// Inline implementations
#include "RadmonVDataAnalysisFactory.icc"
#endif /* RADMONVDATAANALYSISFACTORY_HH */
@@ -0,0 +1,47 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonVDataAnalysisFactory.icc
// Creation date: Nov 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonVDataAnalysisFactory.icc,v 1.1.2.2 2006/06/29 16:07:21 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
#ifndef RADMONVDATAANALYSISFACTORY_HH
#error "RadmonVDataAnalysisFactory.icc cannot be included directly. Please use RadmonVDataAnalysisFactory.hh"
#else /* RADMONVDATAANALYSISFACTORY_HH */
inline RadmonVDataAnalysisFactory :: ~RadmonVDataAnalysisFactory()
{
}
inline RadmonVDataAnalysisFactory :: RadmonVDataAnalysisFactory()
{
}
#endif /* RADMONVDATAANALYSISFACTORY_HH */
@@ -0,0 +1,69 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonVDataAnalysisWithLabel.hh
// Creation date: Nov 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonVDataAnalysisWithLabel.hh,v 1.3 2006/06/29 16:07:23 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Description: Abstract class of an analysis piece with label
// and attributes
//
#ifndef RADMONVDATAANALYSISWITHLABEL_HH
#define RADMONVDATAANALYSISWITHLABEL_HH
// Include files
#include "RadmonLayoutEntityWithAttributes.hh"
#include "RadmonVDataAnalysis.hh"
class RadmonVDataAnalysisWithLabel : public RadmonVDataAnalysis, public RadmonLayoutEntityWithAttributes
{
public:
inline virtual ~RadmonVDataAnalysisWithLabel();
inline const G4String & GetLabel(void) const;
inline virtual void SetDataAnalysisAttribute(const G4String & attributeName, const G4String & value);
virtual RadmonVDataAnalysisWithLabel * New(void) const = 0;
protected:
inline RadmonVDataAnalysisWithLabel(const G4String & label);
private:
// Hidden constructors and operators
RadmonVDataAnalysisWithLabel();
RadmonVDataAnalysisWithLabel(const RadmonVDataAnalysisWithLabel & copy);
RadmonVDataAnalysisWithLabel & operator=(const RadmonVDataAnalysisWithLabel & copy);
// Private attributes
G4String physiscListLabel;
};
#include "RadmonVDataAnalysisWithLabel.icc"
#endif /* RADMONVDATAANALYSISWITHLABEL_HH */
@@ -0,0 +1,67 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonVDataAnalysisWithLabel.icc
// Creation date: Nov 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonVDataAnalysisWithLabel.icc,v 1.3 2006/06/29 16:07:25 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
#ifndef RADMONVDATAANALYSISWITHLABEL_HH
#error "RadmonVDataAnalysisWithLabel.icc cannot be included directly. Please use RadmonVDataAnalysisWithLabel.hh"
#else /* RADMONVDATAANALYSISWITHLABEL_HH */
inline RadmonVDataAnalysisWithLabel :: ~RadmonVDataAnalysisWithLabel()
{
}
inline const G4String & RadmonVDataAnalysisWithLabel :: GetLabel(void) const
{
return physiscListLabel;
}
inline void RadmonVDataAnalysisWithLabel :: SetDataAnalysisAttribute(const G4String & attributeName, const G4String & value)
{
SetAttribute(attributeName, value);
}
inline RadmonVDataAnalysisWithLabel :: RadmonVDataAnalysisWithLabel(const G4String & label)
:
physiscListLabel(label)
{
}
#endif /* RADMONVDATAANALYSISWITHLABEL_HH */
@@ -0,0 +1,417 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonAnalysis.cc
// Creation date: Nov 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonAnalysis.cc,v 1.2.2.2 2006/06/29 16:07:35 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Include files
#include "RadmonAnalysis.hh"
#include "RadmonVDataAnalysisFactory.hh"
#include "RadmonVDataAnalysis.hh"
#include "RadmonVAnalysisLayout.hh"
#include "RadmonSensitiveDetector.hh"
#include "G4UIcommand.hh"
#include "G4Event.hh"
#include "G4SDManager.hh"
#include "G4RunManager.hh"
#include "G4Run.hh"
#include <fstream>
#include <exception>
using namespace std;
RadmonAnalysis :: RadmonAnalysis(RadmonVAnalysisLayout * layout, RadmonVDataAnalysisFactory * factory, AIDA::IAnalysisFactory * analysis)
:
analysisLayout(layout),
dataFactory(factory),
analysisFactory(analysis),
treeFactory(0),
tree(0),
changed(true)
{
if (analysisLayout==0)
G4Exception("RadmonAnalysis::RadmonAnalysis: layout==0.");
if (dataFactory==0)
G4Exception("RadmonAnalysis::RadmonAnalysis: factory==0.");
if (analysisFactory==0)
G4Exception("RadmonAnalysis::RadmonAnalysis: analysis==0.");
analysisLayout->AttachObserver(this);
treeFactory=analysisFactory->createTreeFactory();
}
RadmonAnalysis :: ~RadmonAnalysis()
{
analysisLayout->DetachObserver(this);
Destruct();
delete treeFactory;
delete analysisFactory;
delete dataFactory;
}
void RadmonAnalysis :: OnLayoutChange(void)
{
changed=true;
}
void RadmonAnalysis :: OnBeginOfEvent(const G4Event * /* event */)
{
if (!changed)
return;
Destruct();
list<G4String> tupleLabels;
G4String columns("int runId; int eventId");
if (!InitializeSensitiveDetectorsList(tupleLabels, columns))
{
changed=true;
return;
}
if (!OpenFile())
{
changed=true;
return;
}
if (!InitializeTuple(tupleLabels, columns))
{
changed=false;
return;
}
indexRunId=tuple->findColumn("runId");
indexEventId=tuple->findColumn("eventId");
changed=false;
}
void RadmonAnalysis :: OnEndOfEvent(const G4Event * event)
{
if (!tuple)
return;
if (sensitiveDetectorsList.empty())
return;
SensitiveDetectorsList::iterator sd(sensitiveDetectorsList.begin());
const SensitiveDetectorsList::iterator sdEnd(sensitiveDetectorsList.end());
G4SDManager * manager(G4SDManager::GetSDMpointer());
if (!manager)
return;
tuple->fill(indexRunId, G4RunManager::GetRunManager()->GetCurrentRun()->GetRunID());
tuple->fill(indexEventId, event->GetEventID());
while (sd!=sdEnd)
{
RadmonSensitiveDetector * radmonSensitiveDetector(sd->first);
DataAnalysesList * dataAnalysesList(sd->second);
RadmonHitsCollection * collection(radmonSensitiveDetector->GetDetectorCollection());
DataAnalysesList::iterator i(dataAnalysesList->begin());
DataAnalysesList::iterator end(dataAnalysesList->end());
while (i!=end)
{
(*i)->StoreIntoTuple(collection, tuple);
i++;
}
sd++;
}
tuple->addRow();
}
G4bool RadmonAnalysis :: InitializeSensitiveDetectorsList(list<G4String> & tupleLabels, G4String & columns)
{
G4SDManager * manager(G4SDManager::GetSDMpointer());
if (!manager)
return false;
RadmonVAnalysisLayout const * const constLayout(analysisLayout);
G4int n(constLayout->GetNSensitiveDetectors());
tupleLabels.clear();
while (n>0)
{
n--;
const G4String & sensitiveDetectorLabel(constLayout->GetSensitiveDetectorLabel(n));
G4VSensitiveDetector * sensitiveDetector(manager->FindSensitiveDetector(sensitiveDetectorLabel, false));
if (!sensitiveDetector)
{
G4cout << "RadmonAnalysis::InitializeSensitiveDetectorsList: \"" << sensitiveDetectorLabel << "\" is not attached to any volume." << G4endl;
continue;
}
RadmonSensitiveDetector * radmonSensitiveDetector;
try
{
radmonSensitiveDetector=dynamic_cast<RadmonSensitiveDetector *>(sensitiveDetector);
}
catch (exception e)
{
G4cout << "RadmonAnalysis::InitializeSensitiveDetectorsList: \"" << sensitiveDetectorLabel << "\" is not a RadmonSensitiveDetector object." << G4endl;
radmonSensitiveDetector=0;
}
if (!radmonSensitiveDetector)
continue;
const G4String & sensitiveDetectorType(constLayout->GetSensitiveDetectorType(sensitiveDetectorLabel));
G4int m(constLayout->GetNDataAnalyses(sensitiveDetectorType));
if (m==0)
continue;
DataAnalysesList * dataAnalysesList(new DataAnalysesList);
G4String sensitiveDetectorColumns;
while (m>0)
{
m--;
const G4String & dataAnalysisLabel(constLayout->GetDataAnalysisLabel(sensitiveDetectorType, m));
const G4String & dataAnalysisType(constLayout->GetDataAnalysisType(sensitiveDetectorType, dataAnalysisLabel));
RadmonVDataAnalysis * dataAnalysis(dataFactory->CreateDataAnalysis(dataAnalysisType));
if (dataAnalysis==0)
{
G4cout << "RadmonAnalysis::InitializeSensitiveDetectorsList: \"" << dataAnalysisLabel << "\" defined in \"" << sensitiveDetectorType << "\" not found in the analysis factory." << G4endl;
continue;
}
G4String tupleLabel(sensitiveDetectorLabel);
tupleLabel+='_';
tupleLabel+=dataAnalysisLabel;
G4String dataAnalysisColumns(dataAnalysis->ObtainColumnsDeclaration(tupleLabel));
if (dataAnalysisColumns.empty())
continue;
dataAnalysesList->push_back(dataAnalysis);
tupleLabels.push_back(tupleLabel);
columns+="; ";
columns+=dataAnalysisColumns;
}
if (dataAnalysesList->empty())
delete dataAnalysesList;
else
sensitiveDetectorsList.push_back(SensitiveDetectorPair(radmonSensitiveDetector, dataAnalysesList));
}
return !sensitiveDetectorsList.empty();
}
G4bool RadmonAnalysis :: OpenFile(void)
{
RadmonVAnalysisLayout const * const constLayout(analysisLayout);
const G4String & original(constLayout->GetOutputFileName());
G4String fileName(original);
for(G4int index(1); ; index++)
{
ifstream in(fileName);
if (!in.is_open())
break;
fileName=(original+'_')+G4UIcommand::ConvertToString(index);
}
if (fileName!=original)
G4cout << "RadmonAnalysis::OpenFile: \"" << original << "\" just exists. \"" << fileName << "\" will be used." << G4endl;
try
{
tree=treeFactory->create(fileName, constLayout->GetOutputFileFormat(), false, true);
}
catch (exception e)
{
G4cout << "RadmonAnalysis::OpenFile: " << e.what() << G4endl;
tree=0;
}
if (!tree)
return false;
tupleFactory=analysisFactory->createTupleFactory(* tree);
if (!tupleFactory)
{
delete tree;
tree=0;
return false;
}
return true;
}
G4bool RadmonAnalysis :: InitializeTuple(const list<G4String> & tupleLabels, const G4String & columns)
{
try
{
tuple=tupleFactory->create("1", "Radmon", columns);
}
catch (exception e)
{
G4cout << "RadmonAnalysis::InitializeTuple: " << e.what() << G4endl;
tuple=0;
}
SensitiveDetectorsList::iterator sd(sensitiveDetectorsList.begin());
const SensitiveDetectorsList::iterator sdEnd(sensitiveDetectorsList.end());
list<G4String>::const_iterator j(tupleLabels.begin());
while (sd!=sdEnd)
{
RadmonSensitiveDetector * radmonSensitiveDetector(sd->first);
DataAnalysesList * dataAnalysesList(sd->second);
DataAnalysesList::iterator i(dataAnalysesList->begin());
DataAnalysesList::iterator end(dataAnalysesList->end());
if (tuple==0)
{
while (i!=end)
{
delete *i;
i=dataAnalysesList->erase(i);
}
}
if (dataAnalysesList->empty())
{
delete dataAnalysesList;
sd=sensitiveDetectorsList.erase(sd);
}
else
{
radmonSensitiveDetector->Activate(true);
i=dataAnalysesList->begin();
end=dataAnalysesList->end();
while (i!=end)
{
radmonSensitiveDetector->AttachDataStorer(*i);
(*i)->InitializeFromTuple(*j, tuple);
j++;
i++;
}
sd++;
}
}
return !sensitiveDetectorsList.empty();
}
void RadmonAnalysis :: Destruct(void)
{
if (tree)
{
tree->commit();
tree->close();
delete tupleFactory;
delete tree;
tree=0;
tupleFactory=0;
}
while (!sensitiveDetectorsList.empty())
{
SensitiveDetectorPair sensitiveDetectorPair(sensitiveDetectorsList.back());
sensitiveDetectorsList.pop_back();
sensitiveDetectorPair.first->Activate(false);
sensitiveDetectorPair.first->ClearDataStorersList();
DataAnalysesList::iterator i(sensitiveDetectorPair.second->begin());
const DataAnalysesList::iterator end(sensitiveDetectorPair.second->end());
while (i!=end)
{
delete (*i);
i++;
}
delete sensitiveDetectorPair.second;
}
}
@@ -0,0 +1,561 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonDataAnalysisLayout.cc
// Creation date: Nov 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonAnalysisLayout.cc,v 1.3 2006/06/29 16:07:37 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Include files
#include "RadmonAnalysisLayout.hh"
#include "RadmonDumpStyle.hh"
#include "G4UnitsTable.hh"
#include <iomanip>
RadmonAnalysisLayout :: RadmonAnalysisLayout()
{
}
RadmonAnalysisLayout :: ~RadmonAnalysisLayout()
{
}
void RadmonAnalysisLayout :: SetOutputFileName(const G4String & outputFileName)
{
if (fileName==outputFileName)
return;
fileName=outputFileName;
NotifyChange();
}
const G4String & RadmonAnalysisLayout :: GetOutputFileName(void) const
{
return fileName;
}
void RadmonAnalysisLayout :: SetOutputFileFormat(const G4String & outputFileFormat)
{
if (fileFormat==outputFileFormat)
return;
fileFormat=outputFileFormat;
NotifyChange();
}
const G4String & RadmonAnalysisLayout :: GetOutputFileFormat(void) const
{
return fileFormat;
}
void RadmonAnalysisLayout :: CreateSensitiveDetector(const G4String & sensitiveDetectorLabel, const G4String & sensitiveDetectorType)
{
if (ExistsSensitiveDetector(sensitiveDetectorLabel))
return;
if (!FindSensitiveDetectorType(sensitiveDetectorType))
return;
sensitiveDetectors.push_back(SensitiveDetector(sensitiveDetectorLabel, sensitiveDetectorType));
NotifyChange();
}
void RadmonAnalysisLayout :: SetSensitiveDetectorType(const G4String & sensitiveDetectorLabel, const G4String & sensitiveDetectorType)
{
SensitiveDetector * sensitiveDetector(FindSensitiveDetector(sensitiveDetectorLabel));
if (!sensitiveDetector)
return;
if (sensitiveDetectorType==sensitiveDetector->second)
return;
if (!FindSensitiveDetectorType(sensitiveDetectorType))
return;
sensitiveDetector->second=sensitiveDetectorType;
NotifyChange();
}
const G4String & RadmonAnalysisLayout :: GetSensitiveDetectorType(const G4String & sensitiveDetectorLabel) const
{
const SensitiveDetector * sensitiveDetector(FindSensitiveDetector(sensitiveDetectorLabel));
if (!sensitiveDetector)
return GetNullStr();
return sensitiveDetector->second;
}
void RadmonAnalysisLayout :: RemoveSensitiveDetector(const G4String & sensitiveDetectorLabel)
{
SensitiveDetectors::iterator i(sensitiveDetectors.begin());
const SensitiveDetectors::iterator end(sensitiveDetectors.end());
while (i<end)
{
if (i->first==sensitiveDetectorLabel)
{
sensitiveDetectors.erase(i);
return;
}
i++;
}
G4cout << "RadmonAnalysisLayout::RemoveSensitiveDetector: Sensitive detector \"" << sensitiveDetectorLabel << "\" does not exist." << G4endl;
}
G4int RadmonAnalysisLayout :: GetNSensitiveDetectors(void) const
{
return sensitiveDetectors.size();
}
const G4String & RadmonAnalysisLayout :: GetSensitiveDetectorLabel(G4int index) const
{
return sensitiveDetectors[index].first;
}
void RadmonAnalysisLayout :: CreateSensitiveDetectorType(const G4String & sensitiveDetectorTypeLabel)
{
if (sensitiveDetectorTypes.ExistsItemByLabel(sensitiveDetectorTypeLabel))
{
G4cout << "RadmonAnalysisLayout::CreateSensitiveDetectorType: Sensitive detector \"" << sensitiveDetectorTypeLabel << "\" just exists." << G4endl;
return;
}
RadmonAnalysisSensitiveDetectorTypeLayout & sensitiveDetectorType(sensitiveDetectorTypes.AppendItem());
sensitiveDetectorType.SetLabel(sensitiveDetectorTypeLabel);
}
void RadmonAnalysisLayout :: RemoveSensitiveDetectorType(const G4String & sensitiveDetectorTypeLabel)
{
if (!sensitiveDetectorTypes.ExistsItemByLabel(sensitiveDetectorTypeLabel))
{
G4cout << "RadmonAnalysisLayout::RemoveSensitiveDetectorType: Sensitive detector \"" << sensitiveDetectorTypeLabel << "\" does not exist." << G4endl;
return;
}
if (SensitiveDetectorTypeInUse(sensitiveDetectorTypeLabel))
{
G4cout << "RadmonAnalysisLayout::RemoveSensitiveDetectorType: Sensitive detector \"" << sensitiveDetectorTypeLabel << "\" is in use. Cannot be removed." << G4endl;
return;
}
sensitiveDetectorTypes.RemoveItemByLabel(sensitiveDetectorTypeLabel);
}
void RadmonAnalysisLayout :: AppendDataAnalysisToSensitiveDetectorType(const G4String & sensitiveDetectorTypeLabel, const G4String & dataAnalysisLabel)
{
RadmonAnalysisSensitiveDetectorTypeLayout * sensitiveDetectorType(FindSensitiveDetectorType(sensitiveDetectorTypeLabel));
if (! sensitiveDetectorType)
return;
if (sensitiveDetectorType->ExistsDataAnalysisByLabel(dataAnalysisLabel))
{
G4cout << "RadmonAnalysisLayout::AppendDataAnalysisToSensitiveDetectorType: Data analysis label \"" << dataAnalysisLabel << "\" just exits in sensitive detector \"" << sensitiveDetectorTypeLabel << "\"." << G4endl;
return;
}
RadmonDataAnalysisLayout & dataAnalysisLayout(sensitiveDetectorType->AppendDataAnalysis());
dataAnalysisLayout.SetLabel(dataAnalysisLabel);
if (SensitiveDetectorTypeInUse(sensitiveDetectorTypeLabel))
NotifyChange();
}
void RadmonAnalysisLayout :: SetDataAnalysisType(const G4String & sensitiveDetectorTypeLabel, const G4String & dataAnalysisLabel, const G4String & dataAnalysisType)
{
RadmonDataAnalysisLayout * dataAnalysis(FindDataAnalysis(sensitiveDetectorTypeLabel, dataAnalysisLabel));
if (!dataAnalysis)
return;
if (dataAnalysis->GetType()==dataAnalysisType)
return;
dataAnalysis->SetType(dataAnalysisType);
if (SensitiveDetectorTypeInUse(sensitiveDetectorTypeLabel))
NotifyChange();
}
void RadmonAnalysisLayout :: RemoveDataAnalysis(const G4String & sensitiveDetectorTypeLabel, const G4String & dataAnalysisLabel)
{
RadmonAnalysisSensitiveDetectorTypeLayout * sensitiveDetectorType(FindSensitiveDetectorType(sensitiveDetectorTypeLabel));
if (! sensitiveDetectorType)
return;
if (!sensitiveDetectorType->ExistsDataAnalysisByLabel(dataAnalysisLabel))
{
G4cout << "RadmonAnalysisLayout::RemoveDataAnalysis: Data analysis label \"" << dataAnalysisLabel << "\" does not exit in sensitive detector \"" << sensitiveDetectorTypeLabel << "\"." << G4endl;
return;
}
sensitiveDetectorType->RemoveDataAnalysisByLabel(dataAnalysisLabel);
if (SensitiveDetectorTypeInUse(sensitiveDetectorTypeLabel))
NotifyChange();
}
G4int RadmonAnalysisLayout :: GetNDataAnalyses(const G4String & sensitiveDetectorTypeLabel) const
{
const RadmonAnalysisSensitiveDetectorTypeLayout * sensitiveDetectorType(FindSensitiveDetectorType(sensitiveDetectorTypeLabel));
if (! sensitiveDetectorType)
return 0;
return sensitiveDetectorType->GetNDataAnalyses();
}
const G4String & RadmonAnalysisLayout :: GetDataAnalysisLabel(const G4String & sensitiveDetectorTypeLabel, G4int index) const
{
const RadmonAnalysisSensitiveDetectorTypeLayout * sensitiveDetectorType(FindSensitiveDetectorType(sensitiveDetectorTypeLabel));
if (! sensitiveDetectorType)
return GetNullStr();
return sensitiveDetectorType->GetDataAnalysis(index).GetLabel();
}
const G4String & RadmonAnalysisLayout :: GetDataAnalysisType(const G4String & sensitiveDetectorTypeLabel, const G4String & dataAnalysisLabel) const
{
const RadmonDataAnalysisLayout * dataAnalysisType(FindDataAnalysis(sensitiveDetectorTypeLabel, dataAnalysisLabel));
if (!dataAnalysisType)
return GetNullStr();
return dataAnalysisType->GetType();
}
void RadmonAnalysisLayout :: SetDataAnalysisAttribute(const G4String & sensitiveDetectorTypeLabel, const G4String & dataAnalysisLabel, const G4String & attributeName, const G4String & attributeValue)
{
RadmonDataAnalysisLayout * dataAnalysisType(FindDataAnalysis(sensitiveDetectorTypeLabel, dataAnalysisLabel));
if (!dataAnalysisType)
return;
dataAnalysisType->SetAttribute(attributeName, attributeValue);
if (SensitiveDetectorTypeInUse(sensitiveDetectorTypeLabel))
NotifyChange();
}
void RadmonAnalysisLayout :: ClearDataAnalysisAttribute(const G4String & sensitiveDetectorTypeLabel, const G4String & dataAnalysisLabel, const G4String & attributeName)
{
RadmonDataAnalysisLayout * dataAnalysisType(FindDataAnalysis(sensitiveDetectorTypeLabel, dataAnalysisLabel));
if (!dataAnalysisType)
return;
if (!dataAnalysisType->ExistsAttribute(attributeName))
{
G4cout << "RadmonAnalysisLayout::ClearDataAnalysisAttribute: Attribute \"" << attributeName << "\" does not exist in data analysis \"" << dataAnalysisLabel << "\" of sensitive detector \"" << sensitiveDetectorTypeLabel << "\"." << G4endl;
return;
}
dataAnalysisType->ClearAttribute(attributeName);
if (SensitiveDetectorTypeInUse(sensitiveDetectorTypeLabel))
NotifyChange();
}
G4int RadmonAnalysisLayout :: GetDataAnalysisNAttributes(const G4String & sensitiveDetectorTypeLabel, const G4String & dataAnalysisLabel) const
{
const RadmonDataAnalysisLayout * dataAnalysisType(FindDataAnalysis(sensitiveDetectorTypeLabel, dataAnalysisLabel));
if (!dataAnalysisType)
return 0;
return dataAnalysisType->GetNAttributes();
}
G4String RadmonAnalysisLayout :: GetDataAnalysisAttributeName(const G4String & sensitiveDetectorTypeLabel, const G4String & dataAnalysisLabel, G4int index) const
{
const RadmonDataAnalysisLayout * dataAnalysisType(FindDataAnalysis(sensitiveDetectorTypeLabel, dataAnalysisLabel));
if (!dataAnalysisType)
return GetNullStr();
return dataAnalysisType->GetAttributeName(index);
}
G4String RadmonAnalysisLayout :: GetDataAnalysisAttribute(const G4String & sensitiveDetectorTypeLabel, const G4String & dataAnalysisLabel, const G4String & attributeName, const G4String & defaultAttributeValue) const
{
const RadmonDataAnalysisLayout * dataAnalysisType(FindDataAnalysis(sensitiveDetectorTypeLabel, dataAnalysisLabel));
if (!dataAnalysisType)
return G4String();
return dataAnalysisType->GetAttribute(attributeName, defaultAttributeValue);
}
void RadmonAnalysisLayout :: DumpLayout(std::ostream & out) const
{
const G4String indent(" - ");
out << "- " << std::setw(RADMONDUMP_INDENT_WIDTH-2); out.setf(std::ostream::left, std::ostream::adjustfield); out << "File name"; out.setf(std::ostream::right, std::ostream::adjustfield); out << " = \"" << fileName << "\"\n"
" " << std::setw(RADMONDUMP_INDENT_WIDTH-2); out.setf(std::ostream::left, std::ostream::adjustfield); out << "File format"; out.setf(std::ostream::right, std::ostream::adjustfield); out << " = \"" << fileFormat << "\"\n"
"\n- Sensitive detectors\n";
G4String indent2(indent);
indent2.prepend(" ");
if (sensitiveDetectors.empty())
out << indent << "No sensitive detectors defined.\n";
else
{
const G4int width(RADMONDUMP_INDENT_WIDTH-indent2.length());
const G4int n(sensitiveDetectors.size());
for (G4int i(0); i<n; i++)
{
out << indent << "Sensitive Detector # " << i << '\n'
<< indent2 << std::setw(width); out.setf(std::ostream::left, std::ostream::adjustfield); out << "Label"; out.setf(std::ostream::right, std::ostream::adjustfield); out << " = \"" << sensitiveDetectors[i].first << "\"\n"
<< indent2 << std::setw(width); out.setf(std::ostream::left, std::ostream::adjustfield); out << "Type"; out.setf(std::ostream::right, std::ostream::adjustfield); out << " = \"" << sensitiveDetectors[i].second << "\"\n";
}
}
out << "\n- Sensitive detector types\n";
G4int n(sensitiveDetectorTypes.GetNItems());
if (n==0)
{
out << indent << "No sensitive detector types defined.\n";
return;
}
for(G4int i(0); i<n; i++)
{
out << indent << "Sensitive detector type # " << i << '\n';
sensitiveDetectorTypes.GetItem(i).DumpLayout(out, indent2);
}
}
G4bool RadmonAnalysisLayout :: Load(std::istream & /* in */)
{
// TO BE DONE
G4cout << "RadmonAnalysisLayout::Load(): PLEASE CHECK" << G4endl;
return false;
}
G4bool RadmonAnalysisLayout :: Save(std::ostream & /* out */) const
{
// TO BE DONE
G4cout << "RadmonAnalysisLayout::Save(): PLEASE CHECK" << G4endl;
return false;
}
inline G4bool RadmonAnalysisLayout :: SensitiveDetectorTypeInUse(const G4String & sensitiveDetectorType)
{
G4int i(0);
G4int n(sensitiveDetectors.size());
for (; i<n; i++)
if (sensitiveDetectors[i].second==sensitiveDetectorType)
return true;
return false;
}
inline G4bool RadmonAnalysisLayout :: ExistsSensitiveDetector(const G4String & sensitiveDetectorLabel) const
{
G4int i(0);
G4int n(sensitiveDetectors.size());
for (; i<n; i++)
if (sensitiveDetectors[i].first==sensitiveDetectorLabel)
{
G4cout << "RadmonAnalysisLayout::ExistsSensitiveDetector: Sensitive detector \"" << sensitiveDetectorLabel << "\" just exists." << G4endl;
return true;
}
return false;
}
inline RadmonAnalysisLayout::SensitiveDetector * RadmonAnalysisLayout :: FindSensitiveDetector(const G4String & sensitiveDetectorLabel)
{
G4int i(0);
G4int n(sensitiveDetectors.size());
for (; i<n; i++)
if (sensitiveDetectors[i].first==sensitiveDetectorLabel)
return &(sensitiveDetectors[i]);
G4cout << "RadmonAnalysisLayout::FindSensitiveDetector: Sensitive detector \"" << sensitiveDetectorLabel << "\" does not exist." << G4endl;
return 0;
}
inline const RadmonAnalysisLayout::SensitiveDetector * RadmonAnalysisLayout :: FindSensitiveDetector(const G4String & sensitiveDetectorLabel) const
{
return const_cast<RadmonAnalysisLayout *>(this)->FindSensitiveDetector(sensitiveDetectorLabel);
}
inline RadmonAnalysisSensitiveDetectorTypeLayout * RadmonAnalysisLayout :: FindSensitiveDetectorType(const G4String & sensitiveDetectorTypeLabel)
{
if (!sensitiveDetectorTypes.ExistsItemByLabel(sensitiveDetectorTypeLabel))
{
G4cout << "RadmonAnalysisLayout::FindSensitiveDetectorType: Sensitive detector type \"" << sensitiveDetectorTypeLabel << "\" does not exist." << G4endl;
return 0;
}
return & sensitiveDetectorTypes.FindItemByLabel(sensitiveDetectorTypeLabel);
}
inline const RadmonAnalysisSensitiveDetectorTypeLayout * RadmonAnalysisLayout :: FindSensitiveDetectorType(const G4String & sensitiveDetectorTypeLabel) const
{
return const_cast<RadmonAnalysisLayout *>(this)->FindSensitiveDetectorType(sensitiveDetectorTypeLabel);
}
inline RadmonDataAnalysisLayout * RadmonAnalysisLayout :: FindDataAnalysis(const G4String & sensitiveDetectorTypeLabel, const G4String & dataAnalysisLabel)
{
RadmonAnalysisSensitiveDetectorTypeLayout * sensitiveDetectorType(FindSensitiveDetectorType(sensitiveDetectorTypeLabel));
if (sensitiveDetectorType==0)
return 0;
if (!sensitiveDetectorType->ExistsDataAnalysisByLabel(dataAnalysisLabel))
{
G4cout << "RadmonAnalysisLayout::FindDataAnalysis: Data analysis labelled \"" << dataAnalysisLabel << "\" does not exist in sensitive detector type \"" << sensitiveDetectorTypeLabel << "\"." << G4endl;
return 0;
}
return & sensitiveDetectorType->FindDataAnalysisByLabel(dataAnalysisLabel);
}
inline const RadmonDataAnalysisLayout * RadmonAnalysisLayout :: FindDataAnalysis(const G4String & sensitiveDetectorTypeLabel, const G4String & dataAnalysisLabel) const
{
return const_cast<RadmonAnalysisLayout *>(this)->FindDataAnalysis(sensitiveDetectorTypeLabel, dataAnalysisLabel);
}
inline G4String & RadmonAnalysisLayout :: GetNullStr() const
{
static G4String *nullStr(0);
if (nullStr==0)
nullStr=new G4String("");
return *nullStr;
}
@@ -0,0 +1,333 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonAnalysisMessenger.cc
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonAnalysisMessenger.cc,v 1.3 2006/06/29 16:07:39 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Messenger commands path
#define COMMANDS_PATH "/radmon/analysis/"
// Include files
#include "RadmonAnalysisMessenger.hh"
#include "RadmonVAnalysisLayout.hh"
#include "G4UnitsTable.hh"
RadmonAnalysisMessenger :: RadmonAnalysisMessenger(RadmonVAnalysisLayout * layout)
:
RadmonMessenger(COMMANDS_PATH, "Interactive analysis configuration commands."),
analysisLayout(layout),
RADMON_INITIALIZE_COMMAND(SetOutputFileName),
RADMON_INITIALIZE_COMMAND(SetOutputFileFormat),
RADMON_INITIALIZE_COMMAND(CreateSensitiveDetector),
RADMON_INITIALIZE_COMMAND(SetSensitiveDetectorType),
RADMON_INITIALIZE_COMMAND(RemoveSensitiveDetector),
RADMON_INITIALIZE_COMMAND(CreateSensitiveDetectorType),
RADMON_INITIALIZE_COMMAND(RemoveSensitiveDetectorType),
RADMON_INITIALIZE_COMMAND(AppendDataAnalysisToSensitiveDetectorType),
RADMON_INITIALIZE_COMMAND(SetDataAnalysisType),
RADMON_INITIALIZE_COMMAND(RemoveDataAnalysis),
RADMON_INITIALIZE_COMMAND(SetDataAnalysisAttribute),
RADMON_INITIALIZE_COMMAND(ClearDataAnalysisAttribute),
RADMON_INITIALIZE_COMMAND(DumpLayout),
RADMON_INITIALIZE_COMMAND(Load),
RADMON_INITIALIZE_COMMAND(Save)
{
if (layout==0)
G4Exception("RadmonAnalysisMessenger::RadmonAnalysisMessenger: layout==0.");
RADMON_CREATE_COMMAND_1ARG (SetOutputFileName, "Sets the name of the analysis file", "fileName");
RADMON_CREATE_COMMAND_1ARG (SetOutputFileFormat, "Sets the format of the analysis file", "format");
RADMON_CREATE_COMMAND_2ARGS(CreateSensitiveDetector, "Creates a sensitive detector", "sensitiveDetectorName", "sensitiveDetectorType");
RADMON_CREATE_COMMAND_2ARGS(SetSensitiveDetectorType, "Changes the type of sensitive detector", "sensitiveDetectorName", "sensitiveDetectorType");
RADMON_CREATE_COMMAND_1ARG (RemoveSensitiveDetector, "Removes a sensitive detector", "sensitiveDetectorName");
RADMON_CREATE_COMMAND_1ARG (CreateSensitiveDetectorType, "Creates a sensitive detector type", "sensitiveDetectorType");
RADMON_CREATE_COMMAND_1ARG (RemoveSensitiveDetectorType, "Removes a sensitive detector type", "sensitiveDetectorType");
RADMON_CREATE_COMMAND_2ARGS(AppendDataAnalysisToSensitiveDetectorType, "Appends a analysis module to the sensitive detector type", "sensitiveDetectorType", "analysisModuleLabel");
RADMON_CREATE_COMMAND_3ARGS(SetDataAnalysisType, "Sets the type of analysis module", "sensitiveDetectorType", "analysisModuleLabel", "analysisModuleType");
RADMON_CREATE_COMMAND_2ARGS(RemoveDataAnalysis, "Removes a analysis module from the sensitive detector type", "sensitiveDetectorType", "analysisModuleLabel");
RADMON_CREATE_COMMAND_4ARGS(SetDataAnalysisAttribute, "Sets an attribute of a analysis module", "sensitiveDetectorType", "analysisModuleLabel", "attributeName", "attributeValue");
RADMON_CREATE_COMMAND_3ARGS(ClearDataAnalysisAttribute, "Clears an attribute of a analysis module", "sensitiveDetectorType", "analysisModuleLabel", "attributeName");
RADMON_CREATE_COMMAND_0ARGS(DumpLayout, "Dumps the layout");
RADMON_CREATE_COMMAND_1ARG (Load, "Loads the configuration from file", "fileName");
RADMON_CREATE_COMMAND_1ARG (Save, "Saves the configuration from file", "fileName");
}
RadmonAnalysisMessenger :: ~RadmonAnalysisMessenger()
{
RADMON_DESTROY_COMMAND(Save);
RADMON_DESTROY_COMMAND(Load);
RADMON_DESTROY_COMMAND(DumpLayout);
RADMON_DESTROY_COMMAND(ClearDataAnalysisAttribute);
RADMON_DESTROY_COMMAND(SetDataAnalysisAttribute);
RADMON_DESTROY_COMMAND(RemoveDataAnalysis);
RADMON_DESTROY_COMMAND(SetDataAnalysisType);
RADMON_DESTROY_COMMAND(AppendDataAnalysisToSensitiveDetectorType);
RADMON_DESTROY_COMMAND(RemoveSensitiveDetectorType);
RADMON_DESTROY_COMMAND(CreateSensitiveDetectorType);
RADMON_DESTROY_COMMAND(RemoveSensitiveDetector);
RADMON_DESTROY_COMMAND(SetSensitiveDetectorType);
RADMON_DESTROY_COMMAND(CreateSensitiveDetector);
RADMON_DESTROY_COMMAND(SetOutputFileFormat);
RADMON_DESTROY_COMMAND(SetOutputFileName);
}
G4String RadmonAnalysisMessenger :: GetCurrentValue(G4UIcommand * /* command */)
{
G4cout << "RadmonAnalysisMessenger::GetCurrentValue(): Not supported" << G4endl;
return G4String();
}
void RadmonAnalysisMessenger :: SetNewValue(G4UIcommand * command, G4String newValue)
{
RADMON_BEGIN_LIST_SET_COMMANDS
RADMON_SET_COMMAND(SetOutputFileName)
RADMON_SET_COMMAND(SetOutputFileFormat)
RADMON_SET_COMMAND(CreateSensitiveDetector)
RADMON_SET_COMMAND(SetSensitiveDetectorType)
RADMON_SET_COMMAND(RemoveSensitiveDetector)
RADMON_SET_COMMAND(CreateSensitiveDetectorType)
RADMON_SET_COMMAND(RemoveSensitiveDetectorType)
RADMON_SET_COMMAND(AppendDataAnalysisToSensitiveDetectorType)
RADMON_SET_COMMAND(SetDataAnalysisType)
RADMON_SET_COMMAND(RemoveDataAnalysis)
RADMON_SET_COMMAND(SetDataAnalysisAttribute)
RADMON_SET_COMMAND(ClearDataAnalysisAttribute)
RADMON_SET_COMMAND(DumpLayout)
RADMON_SET_COMMAND(Load)
RADMON_SET_COMMAND(Save)
RADMON_END_LIST_SET_COMMANDS
}
// Events
void RadmonAnalysisMessenger :: OnSetOutputFileName(const G4String & value)
{
G4String args;
if (!ProcessArguments(value, 1, &args))
return;
analysisLayout->SetOutputFileName(args);
}
void RadmonAnalysisMessenger :: OnSetOutputFileFormat(const G4String & value)
{
G4String args;
if (!ProcessArguments(value, 1, &args))
return;
analysisLayout->SetOutputFileFormat(args);
}
void RadmonAnalysisMessenger :: OnCreateSensitiveDetector(const G4String & value)
{
G4String args[2];
if (!ProcessArguments(value, 2, args))
return;
analysisLayout->CreateSensitiveDetector(args[0], args[1]);
}
void RadmonAnalysisMessenger :: OnSetSensitiveDetectorType(const G4String & value)
{
G4String args[2];
if (!ProcessArguments(value, 2, args))
return;
analysisLayout->SetSensitiveDetectorType(args[0], args[1]);
}
void RadmonAnalysisMessenger :: OnRemoveSensitiveDetector(const G4String & value)
{
G4String args;
if (!ProcessArguments(value, 1, &args))
return;
analysisLayout->RemoveSensitiveDetector(args);
}
void RadmonAnalysisMessenger :: OnCreateSensitiveDetectorType(const G4String & value)
{
G4String args;
if (!ProcessArguments(value, 1, &args))
return;
analysisLayout->CreateSensitiveDetectorType(args);
}
void RadmonAnalysisMessenger :: OnRemoveSensitiveDetectorType(const G4String & value)
{
G4String args;
if (!ProcessArguments(value, 1, &args))
return;
analysisLayout->RemoveSensitiveDetectorType(args);
}
void RadmonAnalysisMessenger :: OnAppendDataAnalysisToSensitiveDetectorType(const G4String & value)
{
G4String args[2];
if (!ProcessArguments(value, 2, args))
return;
analysisLayout->AppendDataAnalysisToSensitiveDetectorType(args[0], args[1]);
}
void RadmonAnalysisMessenger :: OnSetDataAnalysisType(const G4String & value)
{
G4String args[3];
if (!ProcessArguments(value, 3, args))
return;
analysisLayout->SetDataAnalysisType(args[0], args[1], args[2]);
}
void RadmonAnalysisMessenger :: OnRemoveDataAnalysis(const G4String & value)
{
G4String args[2];
if (!ProcessArguments(value, 2, args))
return;
analysisLayout->RemoveDataAnalysis(args[0], args[1]);
}
void RadmonAnalysisMessenger :: OnSetDataAnalysisAttribute(const G4String & value)
{
G4String args[4];
if (!ProcessArguments(value, 4, args))
return;
analysisLayout->SetDataAnalysisAttribute(args[0], args[1], args[2], args[3]);
}
void RadmonAnalysisMessenger :: OnClearDataAnalysisAttribute(const G4String & value)
{
G4String args[3];
if (!ProcessArguments(value, 3, args))
return;
analysisLayout->ClearDataAnalysisAttribute(args[0], args[1], args[2]);
}
void RadmonAnalysisMessenger :: OnDumpLayout(const G4String & /* value */)
{
analysisLayout->DumpLayout(G4cout);
G4cout << G4endl;
}
void RadmonAnalysisMessenger :: OnLoad(const G4String & value)
{
G4String args;
if (!ProcessArguments(value, 1, &args))
return;
std::istream * in(OpenForInput(args));
if (!in)
return;
if (!analysisLayout->Load(*in))
G4cout << "RadmonAnalysisMessenger::OnLoad(): Error reading from file \"" << args << "\"." << G4endl;
delete in;
}
void RadmonAnalysisMessenger :: OnSave(const G4String & value)
{
G4String args;
if (!ProcessArguments(value, 1, &args))
return;
std::ostream * out(OpenForOutput(args));
if (!out)
return;
if (!analysisLayout->Save(*out))
G4cout << "RadmonAnalysisMessenger::OnSave(): Cannot write layout into file \"" << args << "\"." << G4endl;
delete out;
}
@@ -0,0 +1,212 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonAnalysisSensitiveDetectorTypeLayout.cc
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonAnalysisSensitiveDetectorTypeLayout.cc,v 1.3 2006/06/29 16:07:41 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Include files
#include "RadmonAnalysisSensitiveDetectorTypeLayout.hh"
#include "RadmonDumpStyle.hh"
#include "G4UnitsTable.hh"
#include <iomanip>
RadmonAnalysisSensitiveDetectorTypeLayout :: RadmonAnalysisSensitiveDetectorTypeLayout(const RadmonAnalysisSensitiveDetectorTypeLayout & copy)
:
sensitiveDetectorLabel(copy.sensitiveDetectorLabel),
dataAnalysesCollection(copy.dataAnalysesCollection)
{
}
RadmonAnalysisSensitiveDetectorTypeLayout & RadmonAnalysisSensitiveDetectorTypeLayout :: operator=(const RadmonAnalysisSensitiveDetectorTypeLayout & copy)
{
sensitiveDetectorLabel=copy.sensitiveDetectorLabel;
dataAnalysesCollection=copy.dataAnalysesCollection;
return (*this);
}
G4int RadmonAnalysisSensitiveDetectorTypeLayout :: GetNDataAnalyses(void) const
{
return dataAnalysesCollection.GetNItems();
}
G4bool RadmonAnalysisSensitiveDetectorTypeLayout :: Empty(void) const
{
return dataAnalysesCollection.Empty();
}
const RadmonDataAnalysisLayout & RadmonAnalysisSensitiveDetectorTypeLayout :: GetDataAnalysis(G4int index) const
{
return dataAnalysesCollection.GetItem(index);
}
RadmonDataAnalysisLayout & RadmonAnalysisSensitiveDetectorTypeLayout :: GetDataAnalysis(G4int index)
{
return dataAnalysesCollection.GetItem(index);
}
G4bool RadmonAnalysisSensitiveDetectorTypeLayout :: ExistsDataAnalysisByLabel(const G4String & dataAnalysisLabel) const
{
return dataAnalysesCollection.ExistsItemByLabel(dataAnalysisLabel);
}
G4int RadmonAnalysisSensitiveDetectorTypeLayout :: MultiplicityDataAnalysisByLabel(const G4String & dataAnalysisLabel) const
{
return dataAnalysesCollection.MultiplicityItemByLabel(dataAnalysisLabel);
}
const RadmonDataAnalysisLayout & RadmonAnalysisSensitiveDetectorTypeLayout :: FindDataAnalysisByLabel(const G4String & dataAnalysisLabel, G4int count) const
{
return dataAnalysesCollection.FindItemByLabel(dataAnalysisLabel, count);
}
RadmonDataAnalysisLayout & RadmonAnalysisSensitiveDetectorTypeLayout :: FindDataAnalysisByLabel(const G4String & dataAnalysisLabel, G4int count)
{
return dataAnalysesCollection.FindItemByLabel(dataAnalysisLabel, count);
}
RadmonDataAnalysisLayout & RadmonAnalysisSensitiveDetectorTypeLayout :: AppendDataAnalysis(void)
{
return dataAnalysesCollection.AppendItem();
}
RadmonDataAnalysisLayout & RadmonAnalysisSensitiveDetectorTypeLayout :: PrependDataAnalysis(void)
{
return dataAnalysesCollection.PrependItem();
}
void RadmonAnalysisSensitiveDetectorTypeLayout :: RemoveDataAnalysisByLabel(const G4String & dataAnalysisLabel, G4int count)
{
dataAnalysesCollection.RemoveItemByLabel(dataAnalysisLabel, count);
}
void RadmonAnalysisSensitiveDetectorTypeLayout :: RemoveDataAnalysesByLabel(const G4String & dataAnalysisLabel)
{
dataAnalysesCollection.RemoveItemsByLabel(dataAnalysisLabel);
}
void RadmonAnalysisSensitiveDetectorTypeLayout :: RemoveDataAnalysis(G4int index)
{
dataAnalysesCollection.RemoveItem(index);
}
void RadmonAnalysisSensitiveDetectorTypeLayout :: RemoveDataAnalysesByRange(G4int first, G4int last)
{
dataAnalysesCollection.RemoveItemsByRange(first, last);
}
void RadmonAnalysisSensitiveDetectorTypeLayout :: RemoveAllDataAnalyses(void)
{
dataAnalysesCollection.RemoveAllItems();
}
void RadmonAnalysisSensitiveDetectorTypeLayout :: DumpLayout(std::ostream & out, const G4String & indent) const
{
G4int width(RADMONDUMP_INDENT_WIDTH-indent.length());
if (width<0)
width=0;
out << indent << std::setw(width); out.setf(std::ostream::left, std::ostream::adjustfield); out << "Label"; out.setf(std::ostream::right, std::ostream::adjustfield); out << " = \"" << sensitiveDetectorLabel << "\"\n";
G4String indent2(indent);
indent2.prepend(" ");
const G4int n(dataAnalysesCollection.GetNItems());
if (n==0)
{
out << indent2 << "No data analyses defined.\n";
return;
}
G4String indent3(indent2);
indent3.prepend(" ");
for(G4int i(0); i<n; i++)
{
out << indent2 << "Data analysis # " << i << '\n';
GetDataAnalysis(i).DumpLayout(out, indent3);
}
}
@@ -0,0 +1,104 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonDataAnalysisDepositedEnergy.cc
// Creation date: Nov 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonDataAnalysisDepositedEnergy.cc,v 1.3 2006/06/29 16:07:43 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
#include "RadmonDataAnalysisDepositedEnergy.hh"
#include "RadmonHitsManager.hh"
#include "G4Step.hh"
#include "AIDA/ITuple.h"
RadmonDataAnalysisDepositedEnergy :: RadmonDataAnalysisDepositedEnergy()
:
RadmonVDataAnalysisWithLabel("DepositedEnergy"),
indexHitEnergyDeposit(RadmonHitsManager::Instance()->ReserveIdByLabel("EnergyDeposit"))
{
}
RadmonVDataAnalysisWithLabel * RadmonDataAnalysisDepositedEnergy :: New(void) const
{
return new RadmonDataAnalysisDepositedEnergy;
}
G4String RadmonDataAnalysisDepositedEnergy :: ObtainColumnsDeclaration(const G4String & prefix)
{
G4String result("double ");
result+=prefix;
result+="_EnergyDeposit";
return result;
}
void RadmonDataAnalysisDepositedEnergy :: InitializeFromTuple(const G4String & prefix, const AIDA::ITuple * tuple)
{
indexTupleEnergyDeposit=tuple->findColumn(prefix+"_EnergyDeposit");
}
void RadmonDataAnalysisDepositedEnergy :: StoreIntoTuple(RadmonHitsCollection * hitsCollection, AIDA::ITuple * tuple)
{
G4int n(hitsCollection->entries());
G4double totalEnergy(0);
while (n>0)
{
n--;
totalEnergy+=(*hitsCollection)[n]->RetrieveById(indexHitEnergyDeposit);
}
tuple->fill(indexTupleEnergyDeposit, totalEnergy/MeV);
}
void RadmonDataAnalysisDepositedEnergy :: StoreIntoHit(G4Step * step, RadmonHit * hit)
{
hit->StoreById(indexHitEnergyDeposit, step->GetTotalEnergyDeposit());
}
@@ -0,0 +1,58 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonDataAnalysisLayout.cc
// Creation date: Nov 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonDataAnalysisLayout.cc,v 1.1.2.2 2006/06/29 16:07:45 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Include files
#include "RadmonDataAnalysisLayout.hh"
#include "RadmonDumpStyle.hh"
#include "G4UnitsTable.hh"
#include <iomanip>
void RadmonDataAnalysisLayout :: DumpLayout(std::ostream & out, const G4String & indent) const
{
G4int width(RADMONDUMP_INDENT_WIDTH-indent.length());
if (width<0)
width=0;
out << indent << std::setw(width); out.setf(std::ostream::left, std::ostream::adjustfield); out << "Label"; out.setf(std::ostream::right, std::ostream::adjustfield); out << " = \"" << dataAnalysisLabel << "\"\n"
<< indent << std::setw(width); out.setf(std::ostream::left, std::ostream::adjustfield); out << "Type"; out.setf(std::ostream::right, std::ostream::adjustfield); out << " = \"" << dataAnalysisType << "\"\n"
<< indent << "Attributes:\n";
G4String indent2(indent);
indent2.prepend(" ");
DumpAttributesLayout(out, indent2);
}
@@ -0,0 +1,85 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonDataAnalysisWithLabelFactory.cc
// Creation date: Nov 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonDataAnalysisWithLabelFactory.cc,v 1.3 2006/06/29 16:07:47 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Include files
#include "RadmonDataAnalysisWithLabelFactory.hh"
#include "RadmonDataAnalysisWithLabelMessenger.hh"
#include "RadmonVDataAnalysisWithLabel.hh"
RadmonDataAnalysisWithLabelFactory :: ~RadmonDataAnalysisWithLabelFactory()
{
DataAnalyses::iterator i(dataAnalyses.begin());
DataAnalyses::iterator end(dataAnalyses.end());
RadmonDataAnalysisWithLabelMessenger * messenger(RadmonDataAnalysisWithLabelMessenger::Instance());
while (i!=end)
{
messenger->RemoveAvailableDataAnalysis((*i)->GetLabel());
delete (*i);
i++;
}
}
RadmonVDataAnalysis * RadmonDataAnalysisWithLabelFactory :: CreateDataAnalysis(const G4String & dataAnalysisName)
{
DataAnalyses::iterator i(dataAnalyses.begin());
DataAnalyses::iterator end(dataAnalyses.end());
while (i!=end)
{
if ((*i)->GetLabel()==dataAnalysisName)
return (*i)->New();
i++;
}
return 0;
}
void RadmonDataAnalysisWithLabelFactory :: AppendDataAnalysisWithLabel(RadmonVDataAnalysisWithLabel * dataAnalysis)
{
dataAnalyses.push_back(dataAnalysis);
RadmonDataAnalysisWithLabelMessenger * messenger(RadmonDataAnalysisWithLabelMessenger::Instance());
messenger->AddAvailableDataAnalysis(dataAnalysis->GetLabel());
}
@@ -0,0 +1,146 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//[B
// File name: RadmonDataAnalysisWithLabelMessenger.cc
// Creation date: Nov 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonDataAnalysisWithLabelMessenger.cc,v 1.3 2006/06/29 16:07:49 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Messenger commands path
#define COMMANDS_PATH "/radmon/dataAnalysisFactory/"
// Include files
#include "RadmonDataAnalysisWithLabelMessenger.hh"
RadmonDataAnalysisWithLabelMessenger * RadmonDataAnalysisWithLabelMessenger :: Instance(void)
{
if (instance==0)
{
instance=new RadmonDataAnalysisWithLabelMessenger;
if (!instance)
G4Exception("RadmonDataAnalysisWithLabelMessenger::Instance: RadmonDataAnalysisWithLabelMessenger singleton not allocated.");
}
return instance;
}
void RadmonDataAnalysisWithLabelMessenger :: AddAvailableDataAnalysis(const G4String & name)
{
availableDataAnalyses.insert(name);
}
void RadmonDataAnalysisWithLabelMessenger :: RemoveAvailableDataAnalysis(const G4String & name)
{
availableDataAnalyses.erase(name);
}
RadmonDataAnalysisWithLabelMessenger :: RadmonDataAnalysisWithLabelMessenger()
:
RadmonMessenger(COMMANDS_PATH, "Interactive labelled analysis data factory commands."),
RADMON_INITIALIZE_COMMAND(Dump)
{
RADMON_CREATE_COMMAND_0ARGS(Dump, "Print out the current analysis data constructors");
}
RadmonDataAnalysisWithLabelMessenger :: ~RadmonDataAnalysisWithLabelMessenger()
{
RADMON_DESTROY_COMMAND(Dump);
}
G4String RadmonDataAnalysisWithLabelMessenger :: GetCurrentValue(G4UIcommand * /* command */)
{
G4cout << "RadmonDataAnalysisWithLabelMessenger::GetCurrentValue(): Not supported" << G4endl;
return G4String();
}
void RadmonDataAnalysisWithLabelMessenger :: SetNewValue(G4UIcommand * command, G4String newValue)
{
RADMON_BEGIN_LIST_SET_COMMANDS
RADMON_SET_COMMAND(Dump)
RADMON_END_LIST_SET_COMMANDS
}
// Events
void RadmonDataAnalysisWithLabelMessenger :: OnDump(const G4String & /* value */)
{
G4String indent("- ");
G4String indent2(indent);
indent2.prepend(" ");
G4cout << indent << "Available analysis data:\n";
AvailableDataAnalyses::const_iterator i(availableDataAnalyses.begin());
AvailableDataAnalyses::const_iterator end(availableDataAnalyses.end());
if (i==end)
G4cout << indent2 << "No analysis data available.\n";
else
{
while (i!=end)
{
G4cout << indent2 << (*i) << '\n';
i++;
}
}
G4cout << G4endl;
}
RadmonDataAnalysisWithLabelMessenger * RadmonDataAnalysisWithLabelMessenger :: instance(0);
@@ -0,0 +1,57 @@
# $Id: GNUmakefile,v 1.7 2005/11/25 01:56:26 capra Exp $
# --------------------------------------------------------------------
# GNUmakefile for exaple subpackage
# R. Capra, 09 Sep 2005
# --------------------------------------------------------------------
name := Radmon
ifndef G4INSTALL
G4INSTALL = ../../../..
endif
include $(G4INSTALL)/config/architecture.gmk
include $(G4INSTALL)/config/G4UI_USE.gmk
include $(G4INSTALL)/config/G4VIS_USE.gmk
include $(G4INSTALL)/config/interactivity.gmk
CPPFLAGS += -I$(G4BASE)/global/management/include \
-I$(G4BASE)/global/HEPGeometry/include \
-I$(G4BASE)/global/HEPRandom/include \
-I$(G4BASE)/intercoms/include \
-I$(G4BASE)/interfaces/basic/include \
-I$(G4BASE)/interfaces/common/include \
-I$(G4BASE)/run/include \
-I$(G4BASE)/event/include \
-I$(G4BASE)/tracking/include \
-I$(G4BASE)/track/include \
-I$(G4BASE)/geometry/management/include \
-I$(G4BASE)/geometry/navigation/include \
-I$(G4BASE)/geometry/volumes/include \
-I$(G4BASE)/geometry/solids/CSG/include \
-I$(G4BASE)/geometry/solids/Boolean/include \
-I$(G4BASE)/particles/management/include \
-I$(G4BASE)/materials/include \
-I$(G4BASE)/processes/management/include \
-I$(G4BASE)/processes/cuts/include \
-I$(G4BASE)/digits_hits/hits/include \
-I$(G4BASE)/digits_hits/digits/include \
-I$(G4BASE)/visualization/management/include \
-I$(G4BASE)/graphics_reps/include \
-I../generalPurpose/include \
-I../generator/include \
-I../detector/include \
-I../materials/include \
-I../physics/include \
-I../analysis/include \
-I../sensitivity/include \
-I../userActions/include
ifdef G4ANALYSIS_USE
CPPFLAGS += `aida-config --include`
CPPFLAGS += -DG4ANALYSIS_USE
LDFLAGS += `aida-config --lib`
LOADLIBS += `aida-config --lib`
endif
include $(G4INSTALL)/config/common.gmk
@@ -0,0 +1,123 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonApplication.hh
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonApplication.hh,v 1.8 2006/06/29 16:07:51 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Description: Radmon application
//
#ifndef RADMONAPPLICATION_HH
#define RADMONAPPLICATION_HH
// Include files
#include "globals.hh"
#include "RadmonApplicationDetectorSetup.hh"
#include "RadmonApplicationGeneratorSetup.hh"
#include "RadmonApplicationPhysicsSetup.hh"
#ifdef G4ANALYSIS_USE
#include "RadmonApplicationAnalysisSetup.hh"
#endif /* G4ANALYSIS_USE */
// Forward declarations
class RadmonApplicationOptions;
class G4RunManager;
class RadmonDetectorLayout;
class RadmonGeneratorLayout;
class RadmonPhysicsLayout;
class RadmonAnalysisLayout;
class RadmonDetectorLabelledEntitiesConstructorsFactory;
class RadmonGeneratorsWithLabelFactory;
class RadmonSubPhysicsListWithLabelFactory;
class RadmonDataAnalysisWithLabelFactory;
class RadmonAnalysis;
class G4VisManager;
class G4UImanager;
class RadmonDetectorMessenger;
class RadmonGeneratorMessenger;
class RadmonPhysicsMessenger;
class RadmonAnalysisMessenger;
class RadmonApplicationMessenger;
class G4UIsession;
class G4UIdirectory;
class RadmonApplication : public RadmonApplicationDetectorSetup, public RadmonApplicationGeneratorSetup, public RadmonApplicationPhysicsSetup
#ifdef G4ANALYSIS_USE
, public RadmonApplicationAnalysisSetup
#endif /* G4ANALYSIS_USE */
{
public:
RadmonApplication(const RadmonApplicationOptions & options);
~RadmonApplication();
inline G4bool Valid(void) const;
private:
G4bool RunMacro(const RadmonApplicationOptions & options, const char * fileName);
// Hidden constructors and operators
RadmonApplication();
RadmonApplication(const RadmonApplication & copy);
RadmonApplication & operator=(const RadmonApplication & copy);
// Private attributes
G4bool valid;
G4RunManager * runManager;
RadmonDetectorLayout * detectorLayout;
RadmonGeneratorLayout * generatorLayout;
RadmonPhysicsLayout * physicsLayout;
#ifdef G4ANALYSIS_USE
RadmonAnalysisLayout * analysisLayout;
#endif /* G4ANALYSIS_USE */
RadmonDetectorLabelledEntitiesConstructorsFactory * detectorsFactory;
RadmonGeneratorsWithLabelFactory * generatorsFactory;
RadmonSubPhysicsListWithLabelFactory * physicsFactory;
#ifdef G4ANALYSIS_USE
RadmonDataAnalysisWithLabelFactory * analysisFactory;
RadmonAnalysis * analysis;
#endif /* G4ANALYSIS_USE */
#ifdef G4VIS_USE
G4VisManager * visManager;
#endif /* G4VIS_USE */
G4UImanager * uiManager;
RadmonDetectorMessenger * detectorMessenger;
RadmonGeneratorMessenger * generatorMessenger;
RadmonPhysicsMessenger * physicsMessenger;
#ifdef G4ANALYSIS_USE
RadmonAnalysisMessenger * analysisMessenger;
#endif /* G4ANALYSIS_USE */
RadmonApplicationMessenger * applicationMessenger;
G4UIsession * session;
G4UIdirectory * directory;
};
#include "RadmonApplication.icc"
#endif /* RADMONAPPLICATION_HH */
@@ -0,0 +1,42 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonApplication.icc
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonApplication.icc,v 1.3 2006/06/29 16:07:53 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
#ifndef RADMONAPPLICATION_HH
#error "RadmonApplication.icc cannot be included directly. Please use RadmonApplication.hh"
#else /* RADMONAPPLICATION_HH */
inline G4bool RadmonApplication :: Valid(void) const
{
return valid;
}
#endif /* RADMONAPPLICATION_HH */
@@ -0,0 +1,66 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonApplicationAnalysisSetup.hh
// Creation date: Oct 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonApplicationAnalysisSetup.hh,v 1.3 2006/06/29 16:07:55 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Description: Radmon application analysis setup
//
#ifndef RADMONAPPLICATIONANALYSISSETUP_HH
#define RADMONAPPLICATIONANALYSISSETUP_HH
// Inglude files
#include "globals.hh"
// Forward declarations
class RadmonApplicationOptions;
class RadmonDataAnalysisWithLabelFactory;
class RadmonApplicationAnalysisSetup
{
public:
inline RadmonApplicationAnalysisSetup(const RadmonApplicationOptions & options);
inline ~RadmonApplicationAnalysisSetup();
protected:
G4bool CreateDataAnalysis(RadmonDataAnalysisWithLabelFactory * factory);
// Hidden constructors and operators
RadmonApplicationAnalysisSetup();
RadmonApplicationAnalysisSetup(const RadmonApplicationAnalysisSetup & copy);
RadmonApplicationAnalysisSetup & operator=(const RadmonApplicationAnalysisSetup & copy);
// Private attributes
const RadmonApplicationOptions & currentOptions;
};
#include "RadmonApplicationAnalysisSetup.icc"
#endif /* RADMONAPPLICATIONANALYSISSETUP_HH */
@@ -0,0 +1,49 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonApplicationAnalysisSetup.icc
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonApplicationAnalysisSetup.icc,v 1.3 2006/06/29 16:07:57 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
#ifndef RADMONAPPLICATIONANALYSISSETUP_HH
#error "RadmonApplicationAnalysisSetup.icc cannot be included directly. Please use RadmonApplicationAnalysisSetup.hh"
#else /* RADMONAPPLICATIONANALYSISSETUP_HH */
inline RadmonApplicationAnalysisSetup :: RadmonApplicationAnalysisSetup(const RadmonApplicationOptions & options)
:
currentOptions(options)
{
}
inline RadmonApplicationAnalysisSetup :: ~RadmonApplicationAnalysisSetup()
{
}
#endif /* RADMONAPPLICATIONANALYSISSETUP_HH */
@@ -0,0 +1,66 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonApplicationDetectorSetup.hh
// Creation date: Oct 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonApplicationDetectorSetup.hh,v 1.3 2006/06/29 16:07:59 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Description: Radmon application detector entity constructors setup
//
#ifndef RADMONAPPLICATIONDETECTORSETUP_HH
#define RADMONAPPLICATIONDETECTORSETUP_HH
// Inglude files
#include "globals.hh"
// Forward declarations
class RadmonApplicationOptions;
class RadmonDetectorLabelledEntitiesConstructorsFactory;
class RadmonApplicationDetectorSetup
{
public:
inline RadmonApplicationDetectorSetup(const RadmonApplicationOptions & options);
inline ~RadmonApplicationDetectorSetup();
protected:
G4bool CreateDetectorEntityConstructors(RadmonDetectorLabelledEntitiesConstructorsFactory * factory);
// Hidden constructors and operators
RadmonApplicationDetectorSetup();
RadmonApplicationDetectorSetup(const RadmonApplicationDetectorSetup & copy);
RadmonApplicationDetectorSetup & operator=(const RadmonApplicationDetectorSetup & copy);
// Private attributes
const RadmonApplicationOptions & currentOptions;
};
#include "RadmonApplicationDetectorSetup.icc"
#endif /* RADMONAPPLICATIONDETECTORSETUP_HH */
@@ -0,0 +1,49 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonApplicationDetectorSetup.icc
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonApplicationDetectorSetup.icc,v 1.3 2006/06/29 16:08:01 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
#ifndef RADMONAPPLICATIONDETECTORSETUP_HH
#error "RadmonApplicationDetectorSetup.icc cannot be included directly. Please use RadmonApplicationDetectorSetup.hh"
#else /* RADMONAPPLICATIONDETECTORSETUP_HH */
inline RadmonApplicationDetectorSetup :: RadmonApplicationDetectorSetup(const RadmonApplicationOptions & options)
:
currentOptions(options)
{
}
inline RadmonApplicationDetectorSetup :: ~RadmonApplicationDetectorSetup()
{
}
#endif /* RADMONAPPLICATIONDETECTORSETUP_HH */
@@ -0,0 +1,64 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonApplicationEventNumbering.hh
// Creation date: Nov 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonApplicationEventNumbering.hh,v 1.3 2006/06/29 16:08:03 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Description: Dumps event id
//
#ifndef RADMONAPPLICATIONEVENTNUMBERING_HH
#define RADMONAPPLICATIONEVENTNUMBERING_HH
// Include files
#include "RadmonEventActionObserver.hh"
#include "globals.hh"
class RadmonApplicationEventNumbering : public RadmonEventActionObserver
{
public:
inline RadmonApplicationEventNumbering();
inline virtual ~RadmonApplicationEventNumbering();
inline void SetDumpEvery(G4int events);
virtual void OnBeginOfEvent(const G4Event * event);
inline virtual void OnEndOfEvent(const G4Event * event);
private:
RadmonApplicationEventNumbering(const RadmonApplicationEventNumbering & copy);
RadmonApplicationEventNumbering & operator=(const RadmonApplicationEventNumbering & copy);
G4int dumpEvery;
};
// Inline implementations
#include "RadmonApplicationEventNumbering.icc"
#endif /* RADMONAPPLICATIONEVENTNUMBERING_HH */
@@ -0,0 +1,66 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonApplicationEventNumbering.icc
// Creation date: Nov 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonApplicationEventNumbering.icc,v 1.3 2006/06/29 16:08:05 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
#ifndef RADMONAPPLICATIONEVENTNUMBERING_HH
#error "RadmonApplicationEventNumbering.icc cannot be included directly. Please use RadmonApplicationEventNumbering.hh"
#else /* RADMONAPPLICATIONEVENTNUMBERING_HH */
inline RadmonApplicationEventNumbering :: RadmonApplicationEventNumbering()
:
dumpEvery(0)
{
}
inline RadmonApplicationEventNumbering :: ~RadmonApplicationEventNumbering()
{
}
inline void RadmonApplicationEventNumbering :: SetDumpEvery(G4int events)
{
dumpEvery=events;
}
inline void RadmonApplicationEventNumbering :: OnEndOfEvent(const G4Event * /* event */)
{
}
#endif /* RADMONAPPLICATIONEVENTNUMBERING_HH */
@@ -0,0 +1,65 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonApplicationEventTracks.hh
// Creation date: Nov 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonApplicationEventTracks.hh,v 1.3 2006/06/29 16:08:07 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Description: Dumps event id
//
#ifndef RADMONAPPLICATIONEVENTTRACKS_HH
#define RADMONAPPLICATIONEVENTTRACKS_HH
// Include files
#include "RadmonEventActionObserver.hh"
#include "globals.hh"
class RadmonApplicationEventTracks : public RadmonEventActionObserver
{
public:
inline RadmonApplicationEventTracks();
inline virtual ~RadmonApplicationEventTracks();
inline void Enable(void);
inline void Disable(void);
inline virtual void OnBeginOfEvent(const G4Event * event);
virtual void OnEndOfEvent(const G4Event * event);
private:
RadmonApplicationEventTracks(const RadmonApplicationEventTracks & copy);
RadmonApplicationEventTracks & operator=(const RadmonApplicationEventTracks & copy);
G4bool enable;
};
// Inline implementations
#include "RadmonApplicationEventTracks.icc"
#endif /* RADMONAPPLICATIONEVENTTRACKS_HH */
@@ -0,0 +1,73 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonApplicationEventTracks.icc
// Creation date: Nov 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonApplicationEventTracks.icc,v 1.3 2006/06/29 16:08:09 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
#ifndef RADMONAPPLICATIONEVENTTRACKS_HH
#error "RadmonApplicationEventTracks.icc cannot be included directly. Please use RadmonApplicationEventTracks.hh"
#else /* RADMONAPPLICATIONEVENTTRACKS_HH */
inline RadmonApplicationEventTracks :: RadmonApplicationEventTracks()
:
enable(false)
{
}
inline RadmonApplicationEventTracks :: ~RadmonApplicationEventTracks()
{
}
inline void RadmonApplicationEventTracks :: Enable(void)
{
enable=true;
}
inline void RadmonApplicationEventTracks :: Disable(void)
{
enable=false;
}
inline void RadmonApplicationEventTracks :: OnBeginOfEvent(const G4Event * /* event */)
{
}
#endif /* RADMONAPPLICATIONEVENTTRACKS_HH */
@@ -0,0 +1,66 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonApplicationGeneratorSetup.hh
// Creation date: Oct 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonApplicationGeneratorSetup.hh,v 1.3 2006/06/29 16:08:11 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Description: Radmon application generators algoritms setup
//
#ifndef RADMONAPPLICATIONGENERATORSETUP_HH
#define RADMONAPPLICATIONGENERATORSETUP_HH
// Inglude files
#include "globals.hh"
// Forward declarations
class RadmonApplicationOptions;
class RadmonGeneratorsWithLabelFactory;
class RadmonApplicationGeneratorSetup
{
public:
inline RadmonApplicationGeneratorSetup(const RadmonApplicationOptions & options);
inline ~RadmonApplicationGeneratorSetup();
protected:
G4bool CreateGenerators(RadmonGeneratorsWithLabelFactory * factory);
// Hidden constructors and operators
RadmonApplicationGeneratorSetup();
RadmonApplicationGeneratorSetup(const RadmonApplicationGeneratorSetup & copy);
RadmonApplicationGeneratorSetup & operator=(const RadmonApplicationGeneratorSetup & copy);
// Private attributes
const RadmonApplicationOptions & currentOptions;
};
#include "RadmonApplicationGeneratorSetup.icc"
#endif /* RADMONAPPLICATIONGENERATORSETUP_HH */
@@ -0,0 +1,49 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonApplicationGeneratorSetup.icc
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonApplicationGeneratorSetup.icc,v 1.3 2006/06/29 16:08:13 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
#ifndef RADMONAPPLICATIONGENERATORSETUP_HH
#error "RadmonApplicationGeneratorSetup.icc cannot be included directly. Please use RadmonApplicationGeneratorSetup.hh"
#else /* RADMONAPPLICATIONGENERATORSETUP_HH */
inline RadmonApplicationGeneratorSetup :: RadmonApplicationGeneratorSetup(const RadmonApplicationOptions & options)
:
currentOptions(options)
{
}
inline RadmonApplicationGeneratorSetup :: ~RadmonApplicationGeneratorSetup()
{
}
#endif /* RADMONAPPLICATIONGENERATORSETUP_HH */
@@ -0,0 +1,75 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonApplicationMessenger.hh
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonApplicationMessenger.hh,v 1.1.2.2 2006/06/29 16:08:15 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Description: UI commands for managing application level options
//
#ifndef RADMONAPPLICATIONMESSENGER_HH
#define RADMONAPPLICATIONMESSENGER_HH
// Include files
#include "RadmonMessenger.hh"
#include "G4String.hh"
// Forward declarations
class RadmonApplicationEventNumbering;
class RadmonApplicationEventTracks;
class RadmonApplicationRunNumbering;
class RadmonApplicationMessenger : public RadmonMessenger
{
public:
RadmonApplicationMessenger();
~RadmonApplicationMessenger();
virtual G4String GetCurrentValue(G4UIcommand * command);
virtual void SetNewValue(G4UIcommand * command, G4String newValue);
private:
// Hidden constructors and operators
RadmonApplicationMessenger(const RadmonApplicationMessenger & copy);
RadmonApplicationMessenger & operator=(const RadmonApplicationMessenger & copy);
// Commands
RadmonApplicationEventNumbering * eventNumbering;
RadmonApplicationEventTracks * eventTracks;
RadmonApplicationRunNumbering * runNumbering;
RADMON_DECLARE_COMMAND(EnableRunsDump);
RADMON_DECLARE_COMMAND(DisableRunsDump);
RADMON_DECLARE_COMMAND(DumpEventsEvery);
RADMON_DECLARE_COMMAND(DisableEventsDump);
RADMON_DECLARE_COMMAND(EnableTracksVisualisation);
RADMON_DECLARE_COMMAND(DisableTracksVisualisation);
};
#endif /* RADMONAPPLICATIONMESSENGER_HH */
@@ -0,0 +1,79 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonApplicationOptions.hh
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonApplicationOptions.hh,v 1.3 2006/06/29 16:08:17 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Description: Supporting class for application startup
//
#ifndef RADMONAPPLICATIONOPTIONS_HH
#define RADMONAPPLICATIONOPTIONS_HH
// Include files
#include "globals.hh"
#include "G4String.hh"
class RadmonApplicationOptions
{
public:
RadmonApplicationOptions(int argc, char * * argv);
inline ~RadmonApplicationOptions();
inline G4bool Valid(void) const;
inline G4bool Interactive(void) const;
inline G4bool Help(void) const;
inline G4bool Verbose(void) const;
inline const char * ApplicationName(void) const;
inline const char * FileName(void) const;
inline const char * StartupFileName(void) const;
void DumpHelp(void) const;
private:
// Hidden constructors and operators
RadmonApplicationOptions(const RadmonApplicationOptions & copy);
RadmonApplicationOptions & operator=(const RadmonApplicationOptions & copy);
// Private attributes
G4bool valid;
G4bool interactive;
G4bool verbose;
G4bool help;
const char * applicationName;
const char * fileName;
const char * startupFileName;
};
#include "RadmonApplicationOptions.icc"
#endif /* RADMONAPPLICATIONOPTIONS_HH */
@@ -0,0 +1,94 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonApplicationOptions.icc
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonApplicationOptions.icc,v 1.3 2006/06/29 16:08:19 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
#ifndef RADMONAPPLICATIONOPTIONS_HH
#error "RadmonApplicationOptions.icc cannot be included directly. Please use RadmonApplicationOptions.hh"
#else /* RADMONAPPLICATIONOPTIONS_HH */
inline RadmonApplicationOptions :: ~RadmonApplicationOptions()
{
}
inline G4bool RadmonApplicationOptions :: Valid(void) const
{
return valid;
}
inline G4bool RadmonApplicationOptions :: Interactive(void) const
{
return interactive;
}
inline G4bool RadmonApplicationOptions :: Help(void) const
{
return help;
}
inline G4bool RadmonApplicationOptions :: Verbose(void) const
{
return verbose;
}
inline const char * RadmonApplicationOptions :: ApplicationName(void) const
{
return applicationName;
}
inline const char * RadmonApplicationOptions :: FileName(void) const
{
return fileName;
}
inline const char * RadmonApplicationOptions :: StartupFileName(void) const
{
return startupFileName;
}
#endif /* RADMONAPPLICATIONOPTIONS_HH */
@@ -0,0 +1,66 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonApplicationPhysicsSetup.hh
// Creation date: Oct 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonApplicationPhysicsSetup.hh,v 1.3 2006/06/29 16:08:21 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Description: Radmon application generators algoritms setup
//
#ifndef RADMONAPPLICATIONPHYSICSSETUP_HH
#define RADMONAPPLICATIONPHYSICSSETUP_HH
// Inglude files
#include "globals.hh"
// Forward declarations
class RadmonApplicationOptions;
class RadmonSubPhysicsListWithLabelFactory;
class RadmonApplicationPhysicsSetup
{
public:
inline RadmonApplicationPhysicsSetup(const RadmonApplicationOptions & options);
inline ~RadmonApplicationPhysicsSetup();
protected:
G4bool CreateSubPhysicsList(RadmonSubPhysicsListWithLabelFactory * factory);
// Hidden constructors and operators
RadmonApplicationPhysicsSetup();
RadmonApplicationPhysicsSetup(const RadmonApplicationPhysicsSetup & copy);
RadmonApplicationPhysicsSetup & operator=(const RadmonApplicationPhysicsSetup & copy);
// Private attributes
const RadmonApplicationOptions & currentOptions;
};
#include "RadmonApplicationPhysicsSetup.icc"
#endif /* RADMONAPPLICATIONPHYSICSSETUP_HH */
@@ -0,0 +1,49 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonApplicationPhysicsSetup.icc
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonApplicationPhysicsSetup.icc,v 1.3 2006/06/29 16:08:23 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
#ifndef RADMONAPPLICATIONPHYSICSSETUP_HH
#error "RadmonApplicationPhysicsSetup.icc cannot be included directly. Please use RadmonApplicationPhysicsSetup.hh"
#else /* RADMONAPPLICATIONPHYSICSSETUP_HH */
inline RadmonApplicationPhysicsSetup :: RadmonApplicationPhysicsSetup(const RadmonApplicationOptions & options)
:
currentOptions(options)
{
}
inline RadmonApplicationPhysicsSetup :: ~RadmonApplicationPhysicsSetup()
{
}
#endif /* RADMONAPPLICATIONPHYSICSSETUP_HH */
@@ -0,0 +1,65 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonApplicationRunNumbering.hh
// Creation date: Nov 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonApplicationRunNumbering.hh,v 1.3 2006/06/29 16:08:25 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Description: Dumps run id
//
#ifndef RADMONAPPLICATIONRUNNUMBERING_HH
#define RADMONAPPLICATIONRUNNUMBERING_HH
// Include files
#include "RadmonRunActionObserver.hh"
#include "globals.hh"
class RadmonApplicationRunNumbering : public RadmonRunActionObserver
{
public:
inline RadmonApplicationRunNumbering();
inline virtual ~RadmonApplicationRunNumbering();
inline void Enable(void);
inline void Disable(void);
virtual void OnBeginOfRun(const G4Run * run);
inline virtual void OnEndOfRun(const G4Run * run);
private:
RadmonApplicationRunNumbering(const RadmonApplicationRunNumbering & copy);
RadmonApplicationRunNumbering & operator=(const RadmonApplicationRunNumbering & copy);
G4bool enable;
};
// Inline implementations
#include "RadmonApplicationRunNumbering.icc"
#endif /* RADMONAPPLICATIONRUNNUMBERING_HH */
@@ -0,0 +1,73 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonApplicationRunNumbering.icc
// Creation date: Nov 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonApplicationRunNumbering.icc,v 1.3 2006/06/29 16:08:27 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
#ifndef RADMONAPPLICATIONRUNNUMBERING_HH
#error "RadmonApplicationRunNumbering.icc cannot be included directly. Please use RadmonApplicationRunNumbering.hh"
#else /* RADMONAPPLICATIONRUNNUMBERING_HH */
inline RadmonApplicationRunNumbering :: RadmonApplicationRunNumbering()
:
enable(false)
{
}
inline RadmonApplicationRunNumbering :: ~RadmonApplicationRunNumbering()
{
}
inline void RadmonApplicationRunNumbering :: Enable(void)
{
enable=true;
}
inline void RadmonApplicationRunNumbering :: Disable(void)
{
enable=false;
}
inline void RadmonApplicationRunNumbering :: OnEndOfRun(const G4Run * /* run */)
{
}
#endif /* RADMONAPPLICATIONRUNNUMBERING_HH */
@@ -0,0 +1,529 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonApplication.cc
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonApplication.cc,v 1.12.2.2 2006/06/29 16:08:29 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Include files
#include "RadmonApplication.hh"
#include "RadmonApplicationOptions.hh"
#include "RadmonDetectorLayout.hh"
#include "RadmonDetectorConstruction.hh"
#include "RadmonDetectorLabelledEntitiesConstructorsFactory.hh"
#include "RadmonDetectorMessenger.hh"
#include "RadmonGeneratorLayout.hh"
#include "RadmonPrimaryGeneratorAction.hh"
#include "RadmonGeneratorsWithLabelFactory.hh"
#include "RadmonGeneratorMessenger.hh"
#include "RadmonPhysicsLayout.hh"
#include "RadmonPhysicsList.hh"
#include "RadmonSubPhysicsListWithLabelFactory.hh"
#include "RadmonPhysicsMessenger.hh"
#ifdef G4ANALYSIS_USE
#include "RadmonAnalysisLayout.hh"
#include "RadmonAnalysis.hh"
#include "RadmonDataAnalysisWithLabelFactory.hh"
#include "RadmonAnalysisMessenger.hh"
#endif /* G4ANALYSIS_USE */
#include "RadmonEventAction.hh"
#include "RadmonSteppingAction.hh"
#include "RadmonApplicationMessenger.hh"
#include "G4RunManager.hh"
#include "G4UImanager.hh"
#include "G4UIdirectory.hh"
#include "G4UIterminal.hh"
#include "G4UItcsh.hh"
#ifdef G4VIS_USE
#include "G4VisExecutive.hh"
#endif /* G4VIS_USE */
RadmonApplication :: RadmonApplication(const RadmonApplicationOptions & options)
:
RadmonApplicationDetectorSetup(options),
RadmonApplicationGeneratorSetup(options),
RadmonApplicationPhysicsSetup(options),
#ifdef G4ANALYSIS_USE
RadmonApplicationAnalysisSetup(options),
#endif /* G4ANALYSIS_USE */
valid(false),
runManager(0),
detectorLayout(0),
generatorLayout(0),
physicsLayout(0),
#ifdef G4ANALYSIS_USE
analysisLayout(0),
#endif /* G4ANALYSIS_USE */
detectorsFactory(0),
generatorsFactory(0),
physicsFactory(0),
#ifdef G4ANALYSIS_USE
analysisFactory(0),
analysis(0),
#endif /* G4ANALYSIS_USE */
#ifdef G4VIS_USE
visManager(0),
#endif /* G4VIS_USE */
uiManager(0),
detectorMessenger(0),
generatorMessenger(0),
physicsMessenger(0),
#ifdef G4ANALYSIS_USE
analysisMessenger(0),
#endif /* G4ANALYSIS_USE */
applicationMessenger(0),
session(0),
directory(0)
{
// Construct the default run manager
runManager=new G4RunManager();
if (runManager==0)
{
G4cerr << options.ApplicationName() << ": Run manager not allocated." << G4endl;
return;
}
// Construct the detector layout
detectorLayout=new RadmonDetectorLayout;
if (detectorLayout==0)
{
G4cerr << options.ApplicationName() << ": Detector layout not allocated." << G4endl;
return;
}
// Construct the generator layout
generatorLayout=new RadmonGeneratorLayout;
if (generatorLayout==0)
{
G4cerr << options.ApplicationName() << ": Generator layout not allocated." << G4endl;
return;
}
// Construct the physics list layout
physicsLayout=new RadmonPhysicsLayout;
if (physicsLayout==0)
{
G4cerr << options.ApplicationName() << ": Physics list layout not allocated." << G4endl;
return;
}
// Construct the analysis list layout
#ifdef G4ANALYSIS_USE
analysisLayout=new RadmonAnalysisLayout;
if (analysisLayout==0)
{
G4cerr << options.ApplicationName() << ": Analysis layout not allocated." << G4endl;
return;
}
#endif /* G4ANALYSIS_USE */
// Construct the detectors factory
detectorsFactory=new RadmonDetectorLabelledEntitiesConstructorsFactory;
if (detectorsFactory==0)
{
G4cerr << options.ApplicationName() << ": Detectors factory not allocated." << G4endl;
return;
}
// Construct the entity constructors
if (!CreateDetectorEntityConstructors(detectorsFactory))
{
G4cerr << options.ApplicationName() << ": Entity constructors not allocated." << G4endl;
return;
}
// Construct the generators factory
generatorsFactory=new RadmonGeneratorsWithLabelFactory;
if (generatorsFactory==0)
{
G4cerr << options.ApplicationName() << ": Generators factory not allocated." << G4endl;
return;
}
// Construct the generators algorithms
if (!CreateGenerators(generatorsFactory))
{
G4cerr << options.ApplicationName() << ": Generator algorithms not allocated." << G4endl;
return;
}
// Construct the physics list factory
physicsFactory=new RadmonSubPhysicsListWithLabelFactory;
if (physicsFactory==0)
{
G4cerr << options.ApplicationName() << ": Physics list factory not allocated." << G4endl;
return;
}
// Construct the sub physics lists
if (!CreateSubPhysicsList(physicsFactory))
{
G4cerr << options.ApplicationName() << ": Sub physics lists not allocated." << G4endl;
return;
}
// Construct the analysis list factory
#ifdef G4ANALYSIS_USE
analysisFactory=new RadmonDataAnalysisWithLabelFactory;
if (analysisFactory==0)
{
G4cerr << options.ApplicationName() << ": Analysis factory not allocated." << G4endl;
return;
}
// Construct the data analyses
if (!CreateDataAnalysis(analysisFactory))
{
G4cerr << options.ApplicationName() << ": Data analyses not allocated." << G4endl;
return;
}
#endif /* G4ANALYSIS_USE */
// Construct the physics list
RadmonPhysicsList * physicsList(new RadmonPhysicsList(physicsLayout, physicsFactory));
if (physicsList==0)
{
G4cerr << options.ApplicationName() << ": Physics list not allocated." << G4endl;
return;
}
// The subphysics list factory will be owned by the physicsList
physicsFactory=0;
runManager->SetUserInitialization(physicsList);
// Construct the detector construction
RadmonDetectorConstruction * detectorConstruction(new RadmonDetectorConstruction(detectorLayout, detectorsFactory));
if (detectorConstruction==0)
{
G4cerr << options.ApplicationName() << ": Detector construction not allocated." << G4endl;
return;
}
// The detectors factory will be owned by the detectorConstruction
detectorsFactory=0;
runManager->SetUserInitialization(detectorConstruction);
// Construct the primary generator
RadmonPrimaryGeneratorAction * primaryGenerator(new RadmonPrimaryGeneratorAction(generatorLayout, generatorsFactory));
if (detectorConstruction==0)
{
G4cerr << options.ApplicationName() << ": Primary generator not allocated." << G4endl;
return;
}
// The primary generators factory will be owned by the primaryGenerator
generatorsFactory=0;
runManager->SetUserAction(primaryGenerator);
// Construct the analysis
#ifdef G4ANALYSIS_USE
AIDA::IAnalysisFactory * aida(AIDA_createAnalysisFactory());
if (aida==0)
{
G4cerr << options.ApplicationName() << ": AIDA_createAnalysisFactory returned 0." << G4endl;
return;
}
analysis=new RadmonAnalysis(analysisLayout, analysisFactory, aida);
if (analysis==0)
{
delete aida;
G4cerr << options.ApplicationName() << ": Analysis not allocated." << G4endl;
return;
}
// The data analyses factory will be owned by the analysis
analysisFactory=0;
RadmonEventAction * eventAction(RadmonEventAction::Instance());
eventAction->AttachObserver(analysis);
#endif /* G4ANALYSIS_USE */
// Initialize the run manager (disabled in order to have UI physics list)
// runManager->Initialize();
// Construct the visualization manager
#ifdef G4VIS_USE
G4VisManager * visManager(new G4VisExecutive);
if (visManager==0)
{
G4cerr << options.ApplicationName() << ": Vis manager not allocated." << G4endl;
return;
}
visManager->Initialize();
#endif /* G4VIS_USE */
// Gets the user interface
uiManager = G4UImanager::GetUIpointer();
if (uiManager==0)
{
G4cerr << options.ApplicationName() << ": UI manager not allocated." << G4endl;
return;
}
// Construct the Radmon directory
directory = new G4UIdirectory("/radmon/");
if (directory==0)
{
G4cerr << options.ApplicationName() << ": Radmon directory not allocated." << G4endl;
return;
}
directory->SetGuidance("Radmon application directory.");
// Construct the messenger to modify the detector layout
detectorMessenger=new RadmonDetectorMessenger(detectorLayout);
if (detectorMessenger==0)
{
G4cerr << options.ApplicationName() << ": Detector layout messenger not allocated." << G4endl;
return;
}
// Construct the messenger to modify the generator layout
generatorMessenger=new RadmonGeneratorMessenger(generatorLayout);
if (generatorMessenger==0)
{
G4cerr << options.ApplicationName() << ": Generator layout messenger not allocated." << G4endl;
return;
}
// Construct the messenger to modify the physics list layout
physicsMessenger=new RadmonPhysicsMessenger(physicsLayout);
if (physicsMessenger==0)
{
G4cerr << options.ApplicationName() << ": Physics list layout messenger not allocated." << G4endl;
return;
}
// Construct the messenger to modify the analysis layout
#ifdef G4ANALYSIS_USE
analysisMessenger=new RadmonAnalysisMessenger(analysisLayout);
if (analysisMessenger==0)
{
G4cerr << options.ApplicationName() << ": Analysis layout messenger not allocated." << G4endl;
return;
}
#endif /* G4ANALYSIS_USE */
// Construct the messenger to modify applications options
applicationMessenger=new RadmonApplicationMessenger;
if (applicationMessenger==0)
{
G4cerr << options.ApplicationName() << ": Application messenger not allocated." << G4endl;
return;
}
// Construct the interactive session
if (options.Interactive())
{
session=new G4UIterminal(new G4UItcsh);
if (session==0)
{
G4cerr << options.ApplicationName() << ": Interactive session not allocated." << G4endl;
return;
}
}
// Runs startup macros
RunMacro(options, options.StartupFileName());
if (options.FileName())
if (!RunMacro(options, options.FileName()))
{
G4cerr << options.ApplicationName() << ": File \"" << options.FileName() << "\" not found." << G4endl;
return;
}
// Runs the interactive session
if (options.Interactive())
{
if (options.Verbose())
G4cout << options.ApplicationName() << ": Interactive session starts ..." << G4endl;
session->SessionStart();
}
valid=true;
}
RadmonApplication :: ~RadmonApplication()
{
// Desctruct the interactive session
delete session;
// Destruct the messenger to modify applications options
delete applicationMessenger;
// Destruct the analysis messenger to modify the layout
#ifdef G4ANALYSIS_USE
delete analysisMessenger;
#endif /* G4ANALYSIS_USE */
// Destruct the physics list messenger to modify the layout
delete physicsMessenger;
// Destruct the generator messenger to modify the layout
delete generatorMessenger;
// Destruct the detector messenger to modify the layout
delete detectorMessenger;
// Destruct the Radmon directory
delete directory;
// Destruct the visualization manager
#ifdef G4VIS_USE
delete visManager;
#endif /* G4VIS_USE */
// Destruct the analysis
#ifdef G4ANALYSIS_USE
delete analysis;
// Destruct the analyses factory
delete analysisFactory;
#endif /* G4ANALYSIS_USE */
// Destruct the sub physics list factory
delete physicsFactory;
// Destruct the generators factory
delete generatorsFactory;
// Destruct the detectors factory
delete detectorsFactory;
// Destruct the default run manager
delete runManager;
// Destruct the analysis layout
#ifdef G4ANALYSIS_USE
delete analysisLayout;
#endif /* G4ANALYSIS_USE */
// Destruct the physics list layout
delete physicsLayout;
// Destruct the generator layout
delete generatorLayout;
// Destruct the detector layout
delete detectorLayout;
}
G4bool RadmonApplication :: RunMacro(const RadmonApplicationOptions & options, const char * fileName)
{
std::ifstream test(fileName);
if (!test.good())
return false;
test.close();
if (options.Verbose())
G4cout << options.ApplicationName() << ": Running macro \"" << fileName << "\" ..." << G4endl;
G4String command("/control/execute ");
command+=fileName;
uiManager->ApplyCommand(command);
return true;
}
@@ -0,0 +1,66 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonApplicationAnalysisSetup.cc
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonApplicationAnalysisSetup.cc,v 1.3.2.2 2006/06/29 16:08:31 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Include files
#include "RadmonApplicationAnalysisSetup.hh"
#include "RadmonApplicationOptions.hh"
#ifdef G4ANALYSIS_USE
#include "RadmonDataAnalysisDepositedEnergy.hh"
#include "RadmonDataAnalysisWithLabelFactory.hh"
#define DECLARE_ANALYSIS_CONSTRUCTOR(name) constructor=new name(); \
if (constructor==0) \
{ \
G4cerr << currentOptions.ApplicationName() << ": Cannot allocate " #name "." << G4endl; \
return false; \
} \
factory->AppendDataAnalysisWithLabel(constructor)
G4bool RadmonApplicationAnalysisSetup :: CreateDataAnalysis(RadmonDataAnalysisWithLabelFactory * factory)
{
RadmonVDataAnalysisWithLabel * constructor;
DECLARE_ANALYSIS_CONSTRUCTOR(RadmonDataAnalysisDepositedEnergy);
return true;
}
#else /* G4ANALYSIS_USE */
G4bool RadmonApplicationAnalysisSetup :: CreateDataAnalysis(RadmonDataAnalysisWithLabelFactory * /* factory */)
{
return false;
}
#endif /* G4ANALYSIS_USE */
@@ -0,0 +1,92 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonApplicationDetectorSetup.cc
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonApplicationDetectorSetup.cc,v 1.1.2.2 2006/06/29 16:08:33 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Include files
#include "RadmonApplicationDetectorSetup.hh"
#include "RadmonApplicationOptions.hh"
#include "RadmonDetectorLabelledEntitiesConstructorsFactory.hh"
#include "RadmonDetectorFlatVolumeConstructor.hh"
#include "RadmonDetectorFlatVolumeWithHoleConstructor.hh"
#include "RadmonDetectorFlatVolumeWithGroundConstructor.hh"
#include "RadmonDetectorFlatVolumeWithGroundAndKeyMarksConstructor.hh"
#include "RadmonDetectorFlatVolumeWithGroundAndKeyMarksAndHoleConstructor.hh"
#include "RadmonDetectorFlatVolumeWithTracksConstructor.hh"
#include "RadmonDetectorFlatVolumeWithPinsConstructor.hh"
#include "RadmonDetectorFlatVolumeWithPadsConstructor.hh"
#include "RadmonDetectorFlatVolumeWithTracksAndHoleConstructor.hh"
#include "RadmonDetectorCarvedFlatVolumeWithHoleConstructor.hh"
#include "RadmonDetectorCarvedFlatVolumeConstructor.hh"
#include "RadmonDetectorCarvedFlatVolumeWithGroundConstructor.hh"
#include "RadmonDetectorCarvedFlatVolumeWithGroundAndKeyMarksConstructor.hh"
#include "RadmonDetectorCarvedFlatVolumeWithGroundAndKeyMarksAndHoleConstructor.hh"
#include "RadmonDetectorCarvedFlatVolumeWithTracksConstructor.hh"
#include "RadmonDetectorCarvedFlatVolumeWithPinsConstructor.hh"
#include "RadmonDetectorCarvedFlatVolumeWithTracksAndHoleConstructor.hh"
#define DECLARE_DETECTOR_CONSTRUCTOR(name) constructor=new name(); \
if (constructor==0) \
{ \
G4cerr << currentOptions.ApplicationName() << ": Cannot allocate " #name "." << G4endl; \
return false; \
} \
factory->AppendLabelledEntityConstructor(constructor)
G4bool RadmonApplicationDetectorSetup :: CreateDetectorEntityConstructors(RadmonDetectorLabelledEntitiesConstructorsFactory * factory)
{
RadmonVDetectorLabelledEntityConstructor * constructor;
DECLARE_DETECTOR_CONSTRUCTOR(RadmonDetectorFlatVolumeConstructor);
DECLARE_DETECTOR_CONSTRUCTOR(RadmonDetectorFlatVolumeWithHoleConstructor);
DECLARE_DETECTOR_CONSTRUCTOR(RadmonDetectorFlatVolumeWithGroundConstructor);
DECLARE_DETECTOR_CONSTRUCTOR(RadmonDetectorFlatVolumeWithGroundAndKeyMarksConstructor);
DECLARE_DETECTOR_CONSTRUCTOR(RadmonDetectorFlatVolumeWithGroundAndKeyMarksAndHoleConstructor);
DECLARE_DETECTOR_CONSTRUCTOR(RadmonDetectorFlatVolumeWithTracksConstructor);
DECLARE_DETECTOR_CONSTRUCTOR(RadmonDetectorFlatVolumeWithPinsConstructor);
DECLARE_DETECTOR_CONSTRUCTOR(RadmonDetectorFlatVolumeWithTracksAndHoleConstructor);
DECLARE_DETECTOR_CONSTRUCTOR(RadmonDetectorFlatVolumeWithPadsConstructor);
DECLARE_DETECTOR_CONSTRUCTOR(RadmonDetectorCarvedFlatVolumeConstructor);
DECLARE_DETECTOR_CONSTRUCTOR(RadmonDetectorCarvedFlatVolumeWithHoleConstructor);
DECLARE_DETECTOR_CONSTRUCTOR(RadmonDetectorCarvedFlatVolumeWithTracksConstructor);
DECLARE_DETECTOR_CONSTRUCTOR(RadmonDetectorCarvedFlatVolumeWithPinsConstructor);
DECLARE_DETECTOR_CONSTRUCTOR(RadmonDetectorCarvedFlatVolumeWithTracksAndHoleConstructor);
DECLARE_DETECTOR_CONSTRUCTOR(RadmonDetectorCarvedFlatVolumeWithGroundConstructor);
DECLARE_DETECTOR_CONSTRUCTOR(RadmonDetectorCarvedFlatVolumeWithGroundAndKeyMarksConstructor);
DECLARE_DETECTOR_CONSTRUCTOR(RadmonDetectorCarvedFlatVolumeWithGroundAndKeyMarksAndHoleConstructor);
return true;
}
@@ -0,0 +1,48 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonApplicationEventNumbering.cc
// Creation date: Nov 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonApplicationEventNumbering.cc,v 1.3 2006/06/29 16:08:35 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Include files
#include "RadmonApplicationEventNumbering.hh"
#include "G4Event.hh"
void RadmonApplicationEventNumbering :: OnBeginOfEvent(const G4Event * event)
{
if (dumpEvery==0)
return;
G4int eventId(event->GetEventID());
if ((eventId%dumpEvery) == 0)
G4cout << "RadmonApplicationEventNumbering::OnBeginOfEvent: Begin of event " << eventId << '.' << G4endl;
}
@@ -0,0 +1,58 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonApplicationEventTracks.cc
// Creation date: Nov 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonApplicationEventTracks.cc,v 1.3 2006/06/29 16:08:37 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Include files
#include "RadmonApplicationEventTracks.hh"
#include "G4Event.hh"
#include "G4VVisManager.hh"
#include "G4TrajectoryContainer.hh"
#include "G4VTrajectory.hh"
void RadmonApplicationEventTracks :: OnEndOfEvent(const G4Event * event)
{
if (!G4VVisManager::GetConcreteInstance())
return;
G4TrajectoryContainer * trajectoryContainer(event->GetTrajectoryContainer());
if (!trajectoryContainer)
return;
G4int nTrajectories(trajectoryContainer->entries());
while (nTrajectories)
{
nTrajectories--;
(*trajectoryContainer)[nTrajectories]->DrawTrajectory(0);
}
}
@@ -0,0 +1,70 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonApplicationGeneratorSetup.cc
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonApplicationGeneratorSetup.cc,v 1.3 2006/06/29 16:08:39 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Include files
#include "RadmonApplicationGeneratorSetup.hh"
#include "RadmonApplicationOptions.hh"
#include "RadmonGeneratorFixedPosition.hh"
#include "RadmonGeneratorFixedDirection.hh"
#include "RadmonGeneratorFixedEnergy.hh"
#include "RadmonGeneratorFixedParticle.hh"
#include "RadmonGeneratorUniformSphere.hh"
#include "RadmonGeneratorUniformPlane.hh"
#include "RadmonGeneratorsWithLabelFactory.hh"
#define DECLARE_GENERATOR_CONSTRUCTOR(name) constructor=new name(); \
if (constructor==0) \
{ \
G4cerr << currentOptions.ApplicationName() << ": Cannot allocate " #name "." << G4endl; \
return false; \
} \
factory->AppendGenerator(constructor)
G4bool RadmonApplicationGeneratorSetup :: CreateGenerators(RadmonGeneratorsWithLabelFactory * factory)
{
RadmonVGeneratorWithLabel * constructor;
DECLARE_GENERATOR_CONSTRUCTOR(RadmonGeneratorFixedPosition);
DECLARE_GENERATOR_CONSTRUCTOR(RadmonGeneratorFixedDirection);
DECLARE_GENERATOR_CONSTRUCTOR(RadmonGeneratorFixedEnergy);
DECLARE_GENERATOR_CONSTRUCTOR(RadmonGeneratorFixedParticle);
DECLARE_GENERATOR_CONSTRUCTOR(RadmonGeneratorUniformSphere);
DECLARE_GENERATOR_CONSTRUCTOR(RadmonGeneratorUniformPlane);
return true;
}
@@ -0,0 +1,185 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonApplicationMessenger.cc
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonApplicationMessenger.cc,v 1.1.2.2 2006/06/29 16:08:41 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Messenger commands path
#define COMMANDS_PATH "/radmon/application/"
// Include files
#include "RadmonApplicationMessenger.hh"
#include "RadmonApplicationEventNumbering.hh"
#include "RadmonApplicationEventTracks.hh"
#include "RadmonApplicationRunNumbering.hh"
#include "RadmonEventAction.hh"
#include "RadmonRunAction.hh"
RadmonApplicationMessenger :: RadmonApplicationMessenger()
:
RadmonMessenger(COMMANDS_PATH, "Interactive application options."),
eventNumbering(new RadmonApplicationEventNumbering),
eventTracks(new RadmonApplicationEventTracks),
runNumbering(new RadmonApplicationRunNumbering),
RADMON_INITIALIZE_COMMAND(EnableRunsDump),
RADMON_INITIALIZE_COMMAND(DisableRunsDump),
RADMON_INITIALIZE_COMMAND(DumpEventsEvery),
RADMON_INITIALIZE_COMMAND(DisableEventsDump),
RADMON_INITIALIZE_COMMAND(EnableTracksVisualisation),
RADMON_INITIALIZE_COMMAND(DisableTracksVisualisation)
{
RadmonEventAction * eventAction(RadmonEventAction::Instance());
eventAction->AttachObserver(eventNumbering);
eventAction->AttachObserver(eventTracks);
RadmonRunAction * runAction(RadmonRunAction::Instance());
runAction->AttachObserver(runNumbering);
RADMON_CREATE_COMMAND_0ARGS(EnableRunsDump, "Disables the run number dump");
RADMON_CREATE_COMMAND_0ARGS(DisableRunsDump, "Enables the run number dump");
RADMON_CREATE_COMMAND_1ARG (DumpEventsEvery, "Enables the event number dump every n events", "nEvents");
RADMON_CREATE_COMMAND_0ARGS(DisableEventsDump, "Disables the event number dump");
#ifdef G4VIS_USE
RADMON_CREATE_COMMAND_0ARGS(EnableTracksVisualisation, "Enables the tracks plotting at the end of the event");
RADMON_CREATE_COMMAND_0ARGS(DisableTracksVisualisation, "Disables the tracks plotting at the end of the event");
#endif /* G4VIS_USE */
}
RadmonApplicationMessenger :: ~RadmonApplicationMessenger()
{
#ifdef G4VIS_USE
RADMON_DESTROY_COMMAND(DisableTracksVisualisation);
RADMON_DESTROY_COMMAND(EnableTracksVisualisation);
#endif /* G4VIS_USE */
RADMON_DESTROY_COMMAND(DisableEventsDump);
RADMON_DESTROY_COMMAND(DumpEventsEvery);
RADMON_DESTROY_COMMAND(DisableRunsDump);
RADMON_DESTROY_COMMAND(EnableRunsDump);
RadmonEventAction * eventAction(RadmonEventAction::Instance());
eventAction->DetachObserver(eventNumbering);
delete eventNumbering;
eventAction->DetachObserver(eventTracks);
delete eventTracks;
RadmonRunAction * runAction(RadmonRunAction::Instance());
runAction->DetachObserver(runNumbering);
delete runNumbering;
}
G4String RadmonApplicationMessenger :: GetCurrentValue(G4UIcommand * /* command */)
{
G4cout << "RadmonApplicationMessenger::GetCurrentValue(): Not supported" << G4endl;
return G4String();
}
void RadmonApplicationMessenger :: SetNewValue(G4UIcommand * command, G4String newValue)
{
RADMON_BEGIN_LIST_SET_COMMANDS
RADMON_SET_COMMAND(EnableRunsDump)
RADMON_SET_COMMAND(DisableRunsDump)
RADMON_SET_COMMAND(DumpEventsEvery)
RADMON_SET_COMMAND(DisableEventsDump)
RADMON_SET_COMMAND(EnableTracksVisualisation)
RADMON_SET_COMMAND(DisableTracksVisualisation)
RADMON_END_LIST_SET_COMMANDS
}
// Events
void RadmonApplicationMessenger :: OnEnableRunsDump(const G4String & /* value */)
{
runNumbering->Enable();
}
void RadmonApplicationMessenger :: OnDisableRunsDump(const G4String & /* value */)
{
runNumbering->Disable();
}
void RadmonApplicationMessenger :: OnDumpEventsEvery(const G4String & value)
{
G4String args;
if (!ProcessArguments(value, 1, & args))
return;
G4int every(G4UIcommand::ConvertToInt(args));
if (every<=0)
{
G4cout << "RadmonApplicationMessenger::OnDumpEventsEvery: nEvents must be positive." << G4endl;
return;
}
eventNumbering->SetDumpEvery(every);
}
void RadmonApplicationMessenger :: OnDisableEventsDump(const G4String & /* value */)
{
eventNumbering->SetDumpEvery(0);
}
void RadmonApplicationMessenger :: OnEnableTracksVisualisation(const G4String & /* value */)
{
eventTracks->Enable();
}
void RadmonApplicationMessenger :: OnDisableTracksVisualisation(const G4String & /* value */)
{
eventTracks->Disable();
}
@@ -0,0 +1,114 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonApplicationOptions.cc
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonApplicationOptions.cc,v 1.5 2006/06/29 16:08:43 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Include files
#include "RadmonApplicationOptions.hh"
RadmonApplicationOptions :: RadmonApplicationOptions(int argc, char * * argv)
:
valid(true),
interactive(true),
verbose(false),
help(false),
applicationName(argv[0]),
fileName(0),
startupFileName(".startup.mac")
{
int i(1);
G4bool fileNameGiven(false);
while (i<argc)
{
if (argv[i][0]=='-' && argv[i][2]==0)
{
switch(argv[i][1])
{
case '?':
case 'H':
case 'h':
help=true;
return;
case 'b':
case 'B':
interactive=false;
break;
case 'v':
case 'V':
verbose=true;
break;
default:
G4cerr << applicationName << ": Command " << argv[i] << " unknown. Run \"" << applicationName << " -h\" for help." << G4endl;
valid=false;
return;
}
}
else
{
if (fileNameGiven)
{
G4cerr << applicationName << ": Bad syntax. Run \"" << applicationName << " -h\" for help." << G4endl;
valid=false;
return;
}
fileNameGiven=true;
fileName=argv[i];
}
i++;
}
}
void RadmonApplicationOptions :: DumpHelp(void) const
{
G4cout << "Usage: " << applicationName << " [-h|-H|-?] [-b] [-v] [<filename>]" << G4endl;
G4cout << G4endl;
G4cout << "-h -H -? Usage help" << G4endl;
G4cout << "-b Force non-interactive mode" << G4endl;
G4cout << "-v Verbose output" << G4endl;
G4cout << "<filename> Name of the macro to be run" << G4endl;
G4cout << G4endl;
G4cout << "If \"" << startupFileName << "\" is present, it will be run before anything else." << G4endl;
G4cout << G4endl;
}
@@ -0,0 +1,86 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonApplicationPhysicsSetup.cc
// Creation date: Nov 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonApplicationPhysicsSetup.cc,v 1.4.2.2 2006/06/29 16:08:45 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Include files
#include "RadmonApplicationPhysicsSetup.hh"
#include "RadmonApplicationOptions.hh"
#include "RadmonSubPhysicsListWithLabelFactory.hh"
#include "RadmonPhysicsElectronEEDL.hh"
#include "RadmonPhysicsElectronStandard.hh"
#include "RadmonPhysicsPhotonEPDL.hh"
#include "RadmonPhysicsPhotonStandard.hh"
#include "RadmonPhysicsPositronStandard.hh"
#include "RadmonPhysicsMuonStandard.hh"
#include "RadmonPhysicsTauStandard.hh"
#include "RadmonPhysicsNuclear.hh"
#include "RadmonPhysicsDecay.hh"
#include "RadmonPhysicsNeutronBinary.hh"
#include "RadmonPhysicsNeutronBertini.hh"
#include "RadmonPhysicsHadronsBinary.hh"
#include "RadmonPhysicsHadronsBertini.hh"
#include "RadmonPhysicsICRUIonization.hh"
#include "RadmonPhysicsProductionCuts.hh"
#define DECLARE_SUBPHYSICS_LIST(name) subPhysicsList=new name(); \
if (subPhysicsList==0) \
{ \
G4cerr << currentOptions.ApplicationName() << ": Cannot allocate " #name "." << G4endl; \
return false; \
} \
factory->AppendSubPhysicsListWithLabel(subPhysicsList)
G4bool RadmonApplicationPhysicsSetup :: CreateSubPhysicsList(RadmonSubPhysicsListWithLabelFactory * factory)
{
RadmonVSubPhysicsListWithLabel * subPhysicsList;
DECLARE_SUBPHYSICS_LIST(RadmonPhysicsElectronEEDL);
DECLARE_SUBPHYSICS_LIST(RadmonPhysicsElectronStandard);
DECLARE_SUBPHYSICS_LIST(RadmonPhysicsPhotonEPDL);
DECLARE_SUBPHYSICS_LIST(RadmonPhysicsPhotonStandard);
DECLARE_SUBPHYSICS_LIST(RadmonPhysicsPositronStandard);
DECLARE_SUBPHYSICS_LIST(RadmonPhysicsMuonStandard);
DECLARE_SUBPHYSICS_LIST(RadmonPhysicsTauStandard);
DECLARE_SUBPHYSICS_LIST(RadmonPhysicsNuclear);
DECLARE_SUBPHYSICS_LIST(RadmonPhysicsDecay);
DECLARE_SUBPHYSICS_LIST(RadmonPhysicsNeutronBinary);
DECLARE_SUBPHYSICS_LIST(RadmonPhysicsNeutronBertini);
DECLARE_SUBPHYSICS_LIST(RadmonPhysicsHadronsBinary);
DECLARE_SUBPHYSICS_LIST(RadmonPhysicsHadronsBertini);
DECLARE_SUBPHYSICS_LIST(RadmonPhysicsICRUIonization);
DECLARE_SUBPHYSICS_LIST(RadmonPhysicsProductionCuts);
return true;
}
@@ -0,0 +1,45 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonApplicationRunNumbering.cc
// Creation date: Nov 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonApplicationRunNumbering.cc,v 1.3 2006/06/29 16:08:47 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Include files
#include "RadmonApplicationRunNumbering.hh"
#include "G4Run.hh"
void RadmonApplicationRunNumbering :: OnBeginOfRun(const G4Run * run)
{
if (!enable)
return;
G4cout << "RadmonApplicationRunNumbering::OnBeginOfRun: Begin of run " << run->GetRunID() << '.' << G4endl;
}
@@ -0,0 +1,41 @@
# $Id: GNUmakefile,v 1.5 2005/11/25 01:53:30 capra Exp $
# --------------------------------------------------------------------
# GNUmakefile for exaple subpackage
# R. Capra, 09 Sep 2005
# --------------------------------------------------------------------
name := Radmon
ifndef G4INSTALL
G4INSTALL = ../../../..
endif
include $(G4INSTALL)/config/architecture.gmk
CPPFLAGS += -I$(G4BASE)/global/management/include \
-I$(G4BASE)/intercoms/include \
-I$(G4BASE)/interfaces/basic/include \
-I$(G4BASE)/interfaces/common/include \
-I$(G4BASE)/run/include \
-I$(G4BASE)/event/include \
-I$(G4BASE)/tracking/include \
-I$(G4BASE)/track/include \
-I$(G4BASE)/geometry/management/include \
-I$(G4BASE)/geometry/navigation/include \
-I$(G4BASE)/geometry/volumes/include \
-I$(G4BASE)/geometry/solids/CSG/include \
-I$(G4BASE)/geometry/solids/Boolean/include \
-I$(G4BASE)/global/HEPGeometry/include \
-I$(G4BASE)/global/HEPRandom/include \
-I$(G4BASE)/particles/management/include \
-I$(G4BASE)/materials/include \
-I$(G4BASE)/processes/management/include \
-I$(G4BASE)/digits_hits/hits/include \
-I$(G4BASE)/digits_hits/detector/include \
-I$(G4BASE)/digits_hits/digits/include \
-I$(G4BASE)/graphics_reps/include \
-I../materials/include \
-I../generalPurpose/include \
-I../sensitivity/include
include $(G4INSTALL)/config/common.gmk
@@ -0,0 +1,59 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonDetectorCarvedFlatVolumeConstructor.hh
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonDetectorCarvedFlatVolumeConstructor.hh,v 1.3 2006/06/29 16:08:49 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Description: Builds a box with carved borders
//
#ifndef RADMONDETECTORCARVEDFLATVOLUMECONSTRUCTOR_HH
#define RADMONDETECTORCARVEDFLATVOLUMECONSTRUCTOR_HH
// Include files
#include "RadmonTDetectorLayerConstructor.hh"
#include "RadmonTDetectorCarvedVolumesDecorator.hh"
#include "RadmonDetectorFlatVolumeComponent.hh"
class RadmonDetectorCarvedFlatVolumeConstructor : public RadmonTDetectorLayerConstructor<RadmonTDetectorCarvedVolumesDecorator<RadmonDetectorFlatVolumeComponent> >
{
public:
inline RadmonDetectorCarvedFlatVolumeConstructor();
inline virtual ~RadmonDetectorCarvedFlatVolumeConstructor();
private:
// Hidden constructors and operators
RadmonDetectorCarvedFlatVolumeConstructor(const RadmonDetectorCarvedFlatVolumeConstructor & copy);
RadmonDetectorCarvedFlatVolumeConstructor & operator=(const RadmonDetectorCarvedFlatVolumeConstructor & copy);
};
// Inline implementations
#include "RadmonDetectorCarvedFlatVolumeConstructor.icc"
#endif /* RADMONDETECTORCARVEDFLATVOLUMECONSTRUCTOR_HH */
@@ -0,0 +1,49 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonDetectorCarvedFlatVolumeConstructor.icc
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonDetectorCarvedFlatVolumeConstructor.icc,v 1.1.2.2 2006/06/29 16:08:51 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
#ifndef RADMONDETECTORCARVEDFLATVOLUMECONSTRUCTOR_HH
#error "RadmonDetectorCarvedFlatVolumeConstructor.icc cannot be included directly. Please use RadmonDetectorCarvedFlatVolumeConstructor.hh"
#else /* RADMONDETECTORCARVEDFLATVOLUMECONSTRUCTOR_HH */
inline RadmonDetectorCarvedFlatVolumeConstructor :: RadmonDetectorCarvedFlatVolumeConstructor()
:
RadmonTDetectorLayerConstructor<RadmonTDetectorCarvedVolumesDecorator<RadmonDetectorFlatVolumeComponent> >("CarvedFlatVolume")
{
}
inline RadmonDetectorCarvedFlatVolumeConstructor :: ~RadmonDetectorCarvedFlatVolumeConstructor()
{
}
#endif /* RADMONDETECTORCARVEDFLATVOLUMECONSTRUCTOR_HH */
@@ -0,0 +1,62 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonDetectorCarvedFlatVolumeWithGroundAndKeyMarksAndHoleConstructor.hh
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonDetectorCarvedFlatVolumeWithGroundAndKeyMarksAndHoleConstructor.hh,v 1.3 2006/06/29 16:08:53 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Description: Builds a carved box with a ground pad and marks and hole
//
#ifndef RADMONDETECTORCARVEDFLATVOLUMEWITHGROUNDANDKEYMARKSANDHOLECONSTRUCTOR_HH
#define RADMONDETECTORCARVEDFLATVOLUMEWITHGROUNDANDKEYMARKSANDHOLECONSTRUCTOR_HH
// Include files
#include "RadmonTDetectorLayerConstructor.hh"
#include "RadmonTDetectorCarvedVolumesDecorator.hh"
#include "RadmonTDetectorVolumesWithGroundDecorator.hh"
#include "RadmonTDetectorVolumesWithHoleDecorator.hh"
#include "RadmonTDetectorVolumesWithKeyMarksDecorator.hh"
#include "RadmonDetectorFlatVolumeComponent.hh"
class RadmonDetectorCarvedFlatVolumeWithGroundAndKeyMarksAndHoleConstructor : public RadmonTDetectorLayerConstructor<RadmonTDetectorCarvedVolumesDecorator<RadmonTDetectorVolumesWithHoleDecorator<RadmonTDetectorVolumesWithKeyMarksDecorator<RadmonTDetectorVolumesWithGroundDecorator<RadmonDetectorFlatVolumeComponent> > > > >
{
public:
inline RadmonDetectorCarvedFlatVolumeWithGroundAndKeyMarksAndHoleConstructor();
inline virtual ~RadmonDetectorCarvedFlatVolumeWithGroundAndKeyMarksAndHoleConstructor();
private:
// Hidden constructors and operators
RadmonDetectorCarvedFlatVolumeWithGroundAndKeyMarksAndHoleConstructor(const RadmonDetectorCarvedFlatVolumeWithGroundAndKeyMarksAndHoleConstructor & copy);
RadmonDetectorCarvedFlatVolumeWithGroundAndKeyMarksAndHoleConstructor & operator=(const RadmonDetectorCarvedFlatVolumeWithGroundAndKeyMarksAndHoleConstructor & copy);
};
// Inline implementations
#include "RadmonDetectorCarvedFlatVolumeWithGroundAndKeyMarksAndHoleConstructor.icc"
#endif /* RADMONDETECTORCARVEDFLATVOLUMEWITHGROUNDANDKEYMARKSANDHOLECONSTRUCTOR_HH */
@@ -0,0 +1,49 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonDetectorCarvedFlatVolumeWithGroundAndKeyMarksAndHoleConstructor.icc
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonDetectorCarvedFlatVolumeWithGroundAndKeyMarksAndHoleConstructor.icc,v 1.3 2006/06/29 16:08:55 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
#ifndef RADMONDETECTORCARVEDFLATVOLUMEWITHGROUNDANDKEYMARKSANDHOLECONSTRUCTOR_HH
#error "RadmonDetectorCarvedFlatVolumeWithGroundAndKeyMarksAndHoleConstructor.icc cannot be included directly. Please use RadmonDetectorCarvedFlatVolumeWithGroundAndKeyMarksAndHoleConstructor.hh"
#else /* RADMONDETECTORCARVEDFLATVOLUMEWITHGROUNDANDKEYMARKSANDHOLECONSTRUCTOR_HH */
inline RadmonDetectorCarvedFlatVolumeWithGroundAndKeyMarksAndHoleConstructor :: RadmonDetectorCarvedFlatVolumeWithGroundAndKeyMarksAndHoleConstructor()
:
RadmonTDetectorLayerConstructor<RadmonTDetectorCarvedVolumesDecorator<RadmonTDetectorVolumesWithHoleDecorator<RadmonTDetectorVolumesWithKeyMarksDecorator<RadmonTDetectorVolumesWithGroundDecorator<RadmonDetectorFlatVolumeComponent> > > > >("CarvedFlatVolumeWithGroundAndKeyMarksAndHole")
{
}
inline RadmonDetectorCarvedFlatVolumeWithGroundAndKeyMarksAndHoleConstructor :: ~RadmonDetectorCarvedFlatVolumeWithGroundAndKeyMarksAndHoleConstructor()
{
}
#endif /* RADMONDETECTORCARVEDFLATVOLUMEWITHGROUNDANDKEYMARKSANDHOLECONSTRUCTOR_HH */
@@ -0,0 +1,61 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonDetectorCarvedFlatVolumeWithGroundAndKeyMarksConstructor.hh
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonDetectorCarvedFlatVolumeWithGroundAndKeyMarksConstructor.hh,v 1.3 2006/06/29 16:08:57 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Description: Builds a carved box with a ground pad and marks
//
#ifndef RADMONDETECTORCARVEDFLATVOLUMEWITHGROUNDANDKEYMARKSCONSTRUCTOR_HH
#define RADMONDETECTORCARVEDFLATVOLUMEWITHGROUNDANDKEYMARKSCONSTRUCTOR_HH
// Include files
#include "RadmonTDetectorLayerConstructor.hh"
#include "RadmonTDetectorCarvedVolumesDecorator.hh"
#include "RadmonTDetectorVolumesWithGroundDecorator.hh"
#include "RadmonTDetectorVolumesWithKeyMarksDecorator.hh"
#include "RadmonDetectorFlatVolumeComponent.hh"
class RadmonDetectorCarvedFlatVolumeWithGroundAndKeyMarksConstructor : public RadmonTDetectorLayerConstructor<RadmonTDetectorCarvedVolumesDecorator<RadmonTDetectorVolumesWithKeyMarksDecorator<RadmonTDetectorVolumesWithGroundDecorator<RadmonDetectorFlatVolumeComponent> > > >
{
public:
inline RadmonDetectorCarvedFlatVolumeWithGroundAndKeyMarksConstructor();
inline virtual ~RadmonDetectorCarvedFlatVolumeWithGroundAndKeyMarksConstructor();
private:
// Hidden constructors and operators
RadmonDetectorCarvedFlatVolumeWithGroundAndKeyMarksConstructor(const RadmonDetectorCarvedFlatVolumeWithGroundAndKeyMarksConstructor & copy);
RadmonDetectorCarvedFlatVolumeWithGroundAndKeyMarksConstructor & operator=(const RadmonDetectorCarvedFlatVolumeWithGroundAndKeyMarksConstructor & copy);
};
// Inline implementations
#include "RadmonDetectorCarvedFlatVolumeWithGroundAndKeyMarksConstructor.icc"
#endif /* RADMONDETECTORCARVEDFLATVOLUMEWITHGROUNDANDKEYMARKSCONSTRUCTOR_HH */
@@ -0,0 +1,49 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonDetectorCarvedFlatVolumeWithGroundAndKeyMarksConstructor.icc
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonDetectorCarvedFlatVolumeWithGroundAndKeyMarksConstructor.icc,v 1.3 2006/06/29 16:08:59 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
#ifndef RADMONDETECTORCARVEDFLATVOLUMEWITHGROUNDANDKEYMARKSCONSTRUCTOR_HH
#error "RadmonDetectorCarvedFlatVolumeWithGroundAndKeyMarksConstructor.icc cannot be included directly. Please use RadmonDetectorCarvedFlatVolumeWithGroundAndKeyMarksConstructor.hh"
#else /* RADMONDETECTORCARVEDFLATVOLUMEWITHGROUNDANDKEYMARKSCONSTRUCTOR_HH */
inline RadmonDetectorCarvedFlatVolumeWithGroundAndKeyMarksConstructor :: RadmonDetectorCarvedFlatVolumeWithGroundAndKeyMarksConstructor()
:
RadmonTDetectorLayerConstructor<RadmonTDetectorCarvedVolumesDecorator<RadmonTDetectorVolumesWithKeyMarksDecorator<RadmonTDetectorVolumesWithGroundDecorator<RadmonDetectorFlatVolumeComponent> > > >("CarvedFlatVolumeWithGroundAndKeyMarks")
{
}
inline RadmonDetectorCarvedFlatVolumeWithGroundAndKeyMarksConstructor :: ~RadmonDetectorCarvedFlatVolumeWithGroundAndKeyMarksConstructor()
{
}
#endif /* RADMONDETECTORCARVEDFLATVOLUMEWITHGROUNDANDKEYMARKSCONSTRUCTOR_HH */
@@ -0,0 +1,60 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonDetectorCarvedFlatVolumeWithGroundConstructor.hh
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonDetectorCarvedFlatVolumeWithGroundConstructor.hh,v 1.3 2006/06/29 16:09:01 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Description: Builds a box with carved borders
//
#ifndef RADMONDETECTORCARVEDFLATVOLUMEWITHGROUNDCONSTRUCTOR_HH
#define RADMONDETECTORCARVEDFLATVOLUMEWITHGROUNDCONSTRUCTOR_HH
// Include files
#include "RadmonTDetectorLayerConstructor.hh"
#include "RadmonTDetectorCarvedVolumesDecorator.hh"
#include "RadmonTDetectorVolumesWithGroundDecorator.hh"
#include "RadmonDetectorFlatVolumeComponent.hh"
class RadmonDetectorCarvedFlatVolumeWithGroundConstructor : public RadmonTDetectorLayerConstructor<RadmonTDetectorCarvedVolumesDecorator<RadmonTDetectorVolumesWithGroundDecorator<RadmonDetectorFlatVolumeComponent> > >
{
public:
inline RadmonDetectorCarvedFlatVolumeWithGroundConstructor();
inline virtual ~RadmonDetectorCarvedFlatVolumeWithGroundConstructor();
private:
// Hidden constructors and operators
RadmonDetectorCarvedFlatVolumeWithGroundConstructor(const RadmonDetectorCarvedFlatVolumeWithGroundConstructor & copy);
RadmonDetectorCarvedFlatVolumeWithGroundConstructor & operator=(const RadmonDetectorCarvedFlatVolumeWithGroundConstructor & copy);
};
// Inline implementations
#include "RadmonDetectorCarvedFlatVolumeWithGroundConstructor.icc"
#endif /* RADMONDETECTORCARVEDFLATVOLUMEWITHGROUNDCONSTRUCTOR_HH */
@@ -0,0 +1,49 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonDetectorCarvedFlatVolumeWithGroundConstructor.icc
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonDetectorCarvedFlatVolumeWithGroundConstructor.icc,v 1.3 2006/06/29 16:09:03 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
#ifndef RADMONDETECTORCARVEDFLATVOLUMEWITHGROUNDCONSTRUCTOR_HH
#error "RadmonDetectorCarvedFlatVolumeWithGroundConstructor.icc cannot be included directly. Please use RadmonDetectorCarvedFlatVolumeWithGroundConstructor.hh"
#else /* RADMONDETECTORCARVEDFLATVOLUMEWITHGROUNDCONSTRUCTOR_HH */
inline RadmonDetectorCarvedFlatVolumeWithGroundConstructor :: RadmonDetectorCarvedFlatVolumeWithGroundConstructor()
:
RadmonTDetectorLayerConstructor<RadmonTDetectorCarvedVolumesDecorator<RadmonTDetectorVolumesWithGroundDecorator<RadmonDetectorFlatVolumeComponent> > >("CarvedFlatVolumeWithGround")
{
}
inline RadmonDetectorCarvedFlatVolumeWithGroundConstructor :: ~RadmonDetectorCarvedFlatVolumeWithGroundConstructor()
{
}
#endif /* RADMONDETECTORCARVEDFLATVOLUMEWITHGROUNDCONSTRUCTOR_HH */
@@ -0,0 +1,60 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonDetectorCarvedFlatVolumeWithHoleConstructor.hh
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonDetectorCarvedFlatVolumeWithHoleConstructor.hh,v 1.3 2006/06/29 16:09:05 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Description: Builds a box with carved borders
//
#ifndef RADMONDETECTORCARVEDFLATVOLUMEWITHHOLECONSTRUCTOR_HH
#define RADMONDETECTORCARVEDFLATVOLUMEWITHHOLECONSTRUCTOR_HH
// Include files
#include "RadmonTDetectorLayerConstructor.hh"
#include "RadmonTDetectorCarvedVolumesDecorator.hh"
#include "RadmonTDetectorVolumesWithHoleDecorator.hh"
#include "RadmonDetectorFlatVolumeComponent.hh"
class RadmonDetectorCarvedFlatVolumeWithHoleConstructor : public RadmonTDetectorLayerConstructor<RadmonTDetectorCarvedVolumesDecorator<RadmonTDetectorVolumesWithHoleDecorator<RadmonDetectorFlatVolumeComponent> > >
{
public:
inline RadmonDetectorCarvedFlatVolumeWithHoleConstructor();
inline virtual ~RadmonDetectorCarvedFlatVolumeWithHoleConstructor();
private:
// Hidden constructors and operators
RadmonDetectorCarvedFlatVolumeWithHoleConstructor(const RadmonDetectorCarvedFlatVolumeWithHoleConstructor & copy);
RadmonDetectorCarvedFlatVolumeWithHoleConstructor & operator=(const RadmonDetectorCarvedFlatVolumeWithHoleConstructor & copy);
};
// Inline implementations
#include "RadmonDetectorCarvedFlatVolumeWithHoleConstructor.icc"
#endif /* RADMONDETECTORCARVEDFLATVOLUMEWITHHOLECONSTRUCTOR_HH */
@@ -0,0 +1,49 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonDetectorCarvedFlatVolumeWithHoleConstructor.icc
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonDetectorCarvedFlatVolumeWithHoleConstructor.icc,v 1.3 2006/06/29 16:09:07 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
#ifndef RADMONDETECTORCARVEDFLATVOLUMEWITHHOLECONSTRUCTOR_HH
#error "RadmonDetectorCarvedFlatVolumeWithHoleConstructor.icc cannot be included directly. Please use RadmonDetectorCarvedFlatVolumeWithHoleConstructor.hh"
#else /* RADMONDETECTORCARVEDFLATVOLUMEWITHHOLECONSTRUCTOR_HH */
inline RadmonDetectorCarvedFlatVolumeWithHoleConstructor :: RadmonDetectorCarvedFlatVolumeWithHoleConstructor()
:
RadmonTDetectorLayerConstructor<RadmonTDetectorCarvedVolumesDecorator<RadmonTDetectorVolumesWithHoleDecorator<RadmonDetectorFlatVolumeComponent> > >("CarvedFlatVolumeWithHole")
{
}
inline RadmonDetectorCarvedFlatVolumeWithHoleConstructor :: ~RadmonDetectorCarvedFlatVolumeWithHoleConstructor()
{
}
#endif /* RADMONDETECTORCARVEDFLATVOLUMEWITHHOLECONSTRUCTOR_HH */
@@ -0,0 +1,60 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonDetectorCarvedFlatVolumeWithPinsConstructor.hh
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonDetectorCarvedFlatVolumeWithPinsConstructor.hh,v 1.3 2006/06/29 16:09:09 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Description: Builds a box with carved borders and pins
//
#ifndef RADMONDETECTORCARVEDFLATVOLUMEWITHPINSCONSTRUCTOR_HH
#define RADMONDETECTORCARVEDFLATVOLUMEWITHPINSCONSTRUCTOR_HH
// Include files
#include "RadmonTDetectorLayerConstructor.hh"
#include "RadmonTDetectorCarvedVolumesDecorator.hh"
#include "RadmonTDetectorVolumesWithPinsDecorator.hh"
#include "RadmonDetectorFlatVolumeComponent.hh"
class RadmonDetectorCarvedFlatVolumeWithPinsConstructor : public RadmonTDetectorLayerConstructor<RadmonTDetectorCarvedVolumesDecorator<RadmonTDetectorVolumesWithPinsDecorator<RadmonDetectorFlatVolumeComponent> > >
{
public:
inline RadmonDetectorCarvedFlatVolumeWithPinsConstructor();
inline virtual ~RadmonDetectorCarvedFlatVolumeWithPinsConstructor();
private:
// Hidden constructors and operators
RadmonDetectorCarvedFlatVolumeWithPinsConstructor(const RadmonDetectorCarvedFlatVolumeWithPinsConstructor & copy);
RadmonDetectorCarvedFlatVolumeWithPinsConstructor & operator=(const RadmonDetectorCarvedFlatVolumeWithPinsConstructor & copy);
};
// Inline implementations
#include "RadmonDetectorCarvedFlatVolumeWithPinsConstructor.icc"
#endif /* RADMONDETECTORCARVEDFLATVOLUMEWITHPINSCONSTRUCTOR_HH */
@@ -0,0 +1,49 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonDetectorCarvedFlatVolumeWithPinsConstructor.icc
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonDetectorCarvedFlatVolumeWithPinsConstructor.icc,v 1.3 2006/06/29 16:09:11 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
#ifndef RADMONDETECTORCARVEDFLATVOLUMEWITHPINSCONSTRUCTOR_HH
#error "RadmonDetectorCarvedFlatVolumeWithPinsConstructor.icc cannot be included directly. Please use RadmonDetectorCarvedFlatVolumeWithPinsConstructor.hh"
#else /* RADMONDETECTORCARVEDFLATVOLUMEWITHPINSCONSTRUCTOR_HH */
inline RadmonDetectorCarvedFlatVolumeWithPinsConstructor :: RadmonDetectorCarvedFlatVolumeWithPinsConstructor()
:
RadmonTDetectorLayerConstructor<RadmonTDetectorCarvedVolumesDecorator<RadmonTDetectorVolumesWithPinsDecorator<RadmonDetectorFlatVolumeComponent> > >("CarvedFlatVolumeWithPins")
{
}
inline RadmonDetectorCarvedFlatVolumeWithPinsConstructor :: ~RadmonDetectorCarvedFlatVolumeWithPinsConstructor()
{
}
#endif /* RADMONDETECTORCARVEDFLATVOLUMEWITHPINSCONSTRUCTOR_HH */
@@ -0,0 +1,61 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonDetectorCarvedFlatVolumeWithTracksAndHoleConstructor.hh
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonDetectorCarvedFlatVolumeWithTracksAndHoleConstructor.hh,v 1.3 2006/06/29 16:09:13 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Description: Builds a box with carved borders
//
#ifndef RADMONDETECTORCARVEDFLATVOLUMEWITHTRACKSANDHOLECONSTRUCTOR_HH
#define RADMONDETECTORCARVEDFLATVOLUMEWITHTRACKSANDHOLECONSTRUCTOR_HH
// Include files
#include "RadmonTDetectorLayerConstructor.hh"
#include "RadmonTDetectorVolumesWithTracksDecorator.hh"
#include "RadmonTDetectorVolumesWithHoleDecorator.hh"
#include "RadmonTDetectorCarvedVolumesDecorator.hh"
#include "RadmonDetectorFlatVolumeComponent.hh"
class RadmonDetectorCarvedFlatVolumeWithTracksAndHoleConstructor : public RadmonTDetectorLayerConstructor<RadmonTDetectorVolumesWithTracksDecorator<RadmonTDetectorCarvedVolumesDecorator<RadmonTDetectorVolumesWithHoleDecorator<RadmonDetectorFlatVolumeComponent> > > >
{
public:
inline RadmonDetectorCarvedFlatVolumeWithTracksAndHoleConstructor();
inline virtual ~RadmonDetectorCarvedFlatVolumeWithTracksAndHoleConstructor();
private:
// Hidden constructors and operators
RadmonDetectorCarvedFlatVolumeWithTracksAndHoleConstructor(const RadmonDetectorCarvedFlatVolumeWithTracksAndHoleConstructor & copy);
RadmonDetectorCarvedFlatVolumeWithTracksAndHoleConstructor & operator=(const RadmonDetectorCarvedFlatVolumeWithTracksAndHoleConstructor & copy);
};
// Inline implementations
#include "RadmonDetectorCarvedFlatVolumeWithTracksAndHoleConstructor.icc"
#endif /* RADMONDETECTORCARVEDFLATVOLUMEWITHTRACKSANDHOLECONSTRUCTOR_HH */
@@ -0,0 +1,49 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonDetectorCarvedFlatVolumeWithTracksAndHoleConstructor.icc
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonDetectorCarvedFlatVolumeWithTracksAndHoleConstructor.icc,v 1.3 2006/06/29 16:09:15 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
#ifndef RADMONDETECTORCARVEDFLATVOLUMEWITHTRACKSANDHOLECONSTRUCTOR_HH
#error "RadmonDetectorCarvedFlatVolumeWithTracksAndHoleConstructor.icc cannot be included directly. Please use RadmonDetectorCarvedFlatVolumeWithTracksAndHoleConstructor.hh"
#else /* RADMONDETECTORCARVEDFLATVOLUMEWITHTRACKSANDHOLECONSTRUCTOR_HH */
inline RadmonDetectorCarvedFlatVolumeWithTracksAndHoleConstructor :: RadmonDetectorCarvedFlatVolumeWithTracksAndHoleConstructor()
:
RadmonTDetectorLayerConstructor<RadmonTDetectorVolumesWithTracksDecorator<RadmonTDetectorCarvedVolumesDecorator<RadmonTDetectorVolumesWithHoleDecorator<RadmonDetectorFlatVolumeComponent> > > >("CarvedFlatVolumeWithTracksAndHole")
{
}
inline RadmonDetectorCarvedFlatVolumeWithTracksAndHoleConstructor :: ~RadmonDetectorCarvedFlatVolumeWithTracksAndHoleConstructor()
{
}
#endif /* RADMONDETECTORCARVEDFLATVOLUMEWITHTRACKSANDHOLECONSTRUCTOR_HH */
@@ -0,0 +1,60 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonDetectorCarvedFlatVolumeWithTracksConstructor.hh
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonDetectorCarvedFlatVolumeWithTracksConstructor.hh,v 1.3 2006/06/29 16:09:17 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Description: Builds a box with carved borders and tracks
//
#ifndef RADMONDETECTORCARVEDFLATVOLUMEWITHTRACKSCONSTRUCTOR_HH
#define RADMONDETECTORCARVEDFLATVOLUMEWITHTRACKSCONSTRUCTOR_HH
// Include files
#include "RadmonTDetectorLayerConstructor.hh"
#include "RadmonTDetectorCarvedVolumesDecorator.hh"
#include "RadmonTDetectorVolumesWithTracksDecorator.hh"
#include "RadmonDetectorFlatVolumeComponent.hh"
class RadmonDetectorCarvedFlatVolumeWithTracksConstructor : public RadmonTDetectorLayerConstructor<RadmonTDetectorVolumesWithTracksDecorator<RadmonTDetectorCarvedVolumesDecorator<RadmonDetectorFlatVolumeComponent> > >
{
public:
inline RadmonDetectorCarvedFlatVolumeWithTracksConstructor();
inline virtual ~RadmonDetectorCarvedFlatVolumeWithTracksConstructor();
private:
// Hidden constructors and operators
RadmonDetectorCarvedFlatVolumeWithTracksConstructor(const RadmonDetectorCarvedFlatVolumeWithTracksConstructor & copy);
RadmonDetectorCarvedFlatVolumeWithTracksConstructor & operator=(const RadmonDetectorCarvedFlatVolumeWithTracksConstructor & copy);
};
// Inline implementations
#include "RadmonDetectorCarvedFlatVolumeWithTracksConstructor.icc"
#endif /* RADMONDETECTORCARVEDFLATVOLUMEWITHTRACKSCONSTRUCTOR_HH */
@@ -0,0 +1,49 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonDetectorCarvedFlatVolumeWithTracksConstructor.icc
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonDetectorCarvedFlatVolumeWithTracksConstructor.icc,v 1.3 2006/06/29 16:09:19 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
#ifndef RADMONDETECTORCARVEDFLATVOLUMEWITHTRACKSCONSTRUCTOR_HH
#error "RadmonDetectorCarvedFlatVolumeWithTracksConstructor.icc cannot be included directly. Please use RadmonDetectorCarvedFlatVolumeWithTracksConstructor.hh"
#else /* RADMONDETECTORCARVEDFLATVOLUMEWITHTRACKSCONSTRUCTOR_HH */
inline RadmonDetectorCarvedFlatVolumeWithTracksConstructor :: RadmonDetectorCarvedFlatVolumeWithTracksConstructor()
:
RadmonTDetectorLayerConstructor<RadmonTDetectorVolumesWithTracksDecorator<RadmonTDetectorCarvedVolumesDecorator<RadmonDetectorFlatVolumeComponent> > >("CarvedFlatVolumeWithTracks")
{
}
inline RadmonDetectorCarvedFlatVolumeWithTracksConstructor :: ~RadmonDetectorCarvedFlatVolumeWithTracksConstructor()
{
}
#endif /* RADMONDETECTORCARVEDFLATVOLUMEWITHTRACKSCONSTRUCTOR_HH */
@@ -0,0 +1,94 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonDetectorConstruction.hh
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonDetectorConstruction.hh,v 1.3.2.2 2006/06/29 16:09:21 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Description: Implementation of the G4VUserDetectorConstruction
//
#ifndef RADMONDETECTORCONSTRUCTION_HH
#define RADMONDETECTORCONSTRUCTION_HH
// Include files
#include "globals.hh"
#include "G4VUserDetectorConstruction.hh"
#include "RadmonVLayoutObserver.hh"
#include <stack>
#include <utility>
// Forward declaration
class G4VPhysicalVolume;
class G4VSolid;
class G4LogicalVolume;
class RadmonVDetectorLayout;
class RadmonVDetectorEntityConstructor;
class RadmonVDetectorEntitiesConstructorsFactory;
class G4String;
class RadmonDetectorConstruction : public G4VUserDetectorConstruction, public RadmonVLayoutObserver
{
public:
RadmonDetectorConstruction(RadmonVDetectorLayout * layout, RadmonVDetectorEntitiesConstructorsFactory * factory);
virtual ~RadmonDetectorConstruction();
virtual G4VPhysicalVolume * Construct(void);
virtual void OnLayoutChange(void);
private:
// Private methods
void Destruct(void);
void BuildEnvironmentFromType(const G4String & type);
void BuildEnvironmentSphere(void);
void BuildMultilayer(G4int index);
// Hidden constructors and operators
RadmonDetectorConstruction();
RadmonDetectorConstruction(const RadmonDetectorConstruction & copy);
RadmonDetectorConstruction & operator=(const RadmonDetectorConstruction & copy);
// Private data types
typedef std::pair<RadmonVDetectorEntityConstructor *, G4VPhysicalVolume *> LayerItem;
typedef std::stack<LayerItem> LayersStack;
// Private attributes
RadmonVDetectorLayout * detectorLayout;
RadmonVDetectorEntitiesConstructorsFactory * constructorsFactory;
LayersStack layersStack;
RadmonVDetectorEntityConstructor * environmentConstructor;
G4VPhysicalVolume * environmentPhysicalVolume;
G4LogicalVolume * environmentLogicalVolume;
G4VSolid * environmentSolid;
};
#endif /* RADMONDETECTORCONSTRUCTION_HH */
@@ -0,0 +1,69 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonDetectorEnvironmentLayout.hh
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonDetectorEnvironmentLayout.hh,v 1.5 2006/06/29 16:09:23 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Description: Internal class to describe the environment layout
//
#ifndef RADMONDETECTORENVIRONMENTLAYOUT_HH
#define RADMONDETECTORENVIRONMENTLAYOUT_HH
// Include files
#include "RadmonLayoutEntityWithAttributes.hh"
class RadmonDetectorEnvironmentLayout : public RadmonLayoutEntityWithAttributes
{
public:
inline RadmonDetectorEnvironmentLayout();
inline ~RadmonDetectorEnvironmentLayout();
inline G4bool IsEnabled(void) const;
inline void Enable(void);
inline void Disable(void);
inline const G4String & GetType(void) const;
inline void SetType(const G4String & type);
void DumpLayout(std::ostream & out, const G4String & indent=G4String("")) const;
private:
RadmonDetectorEnvironmentLayout(const RadmonDetectorEnvironmentLayout & copy);
RadmonDetectorEnvironmentLayout & operator=(const RadmonDetectorEnvironmentLayout & copy);
G4bool enabled;
G4String environmentType;
};
// Inline implementations
#include "RadmonDetectorEnvironmentLayout.icc"
#endif /* RADMONDETECTORENVIRONMENTLAYOUT_HH */
@@ -0,0 +1,89 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonDetectorEnvironmentLayout.icc
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonDetectorEnvironmentLayout.icc,v 1.3 2006/06/29 16:09:25 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
#ifndef RADMONDETECTORENVIRONMENTLAYOUT_HH
#error "RadmonDetectorEnvironmentLayout.icc cannot be included directly. Please use RadmonDetectorEnvironmentLayout.hh"
#else /* RADMONDETECTORENVIRONMENTLAYOUT_HH */
inline RadmonDetectorEnvironmentLayout :: RadmonDetectorEnvironmentLayout()
:
enabled(false),
environmentType()
{
}
inline RadmonDetectorEnvironmentLayout :: ~RadmonDetectorEnvironmentLayout()
{
}
inline G4bool RadmonDetectorEnvironmentLayout :: IsEnabled(void) const
{
return enabled;
}
inline void RadmonDetectorEnvironmentLayout :: Enable(void)
{
enabled=true;
}
inline void RadmonDetectorEnvironmentLayout :: Disable(void)
{
enabled=false;
}
inline const G4String & RadmonDetectorEnvironmentLayout :: GetType(void) const
{
return environmentType;
}
inline void RadmonDetectorEnvironmentLayout :: SetType(const G4String & type)
{
environmentType=type;
}
#endif /* RADMONDETECTORENVIRONMENTLAYOUT_HH */
@@ -0,0 +1,70 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonDetectorFlatVolumeComponent.hh
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonDetectorFlatVolumeComponent.hh,v 1.4 2006/06/29 16:09:27 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Description: Component to create a box
//
#ifndef RADMONDETECTORFLATVOLUMECOMPONENT_HH
#define RADMONDETECTORFLATVOLUMECOMPONENT_HH
// Include files
#include "globals.hh"
// Forward declarations
class RadmonVDetectorLabelledEntityConstructor;
class RadmonDetectorLayerVolumesList;
class G4Box;
class G4VisAttributes;
class RadmonDetectorFlatVolumeComponent
{
public:
inline RadmonDetectorFlatVolumeComponent(const RadmonVDetectorLabelledEntityConstructor * constructor);
~RadmonDetectorFlatVolumeComponent();
RadmonDetectorLayerVolumesList * GenerateVolumesList(void);
private:
// Hidden constructors and operators
RadmonDetectorFlatVolumeComponent();
RadmonDetectorFlatVolumeComponent(const RadmonDetectorFlatVolumeComponent & copy);
RadmonDetectorFlatVolumeComponent & operator=(const RadmonDetectorFlatVolumeComponent & copy);
// Private attributes
const RadmonVDetectorLabelledEntityConstructor * owner;
G4Box * box;
G4VisAttributes * visAttributes;
};
// Inline implementations
#include "RadmonDetectorFlatVolumeComponent.icc"
#endif /* RADMONDETECTORFLATVOLUMECOMPONENT_HH */
@@ -0,0 +1,45 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonDetectorFlatVolumeComponent.icc
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonDetectorFlatVolumeComponent.icc,v 1.1.2.2 2006/06/29 16:09:29 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
#ifndef RADMONDETECTORFLATVOLUMECOMPONENT_HH
#error "RadmonDetectorFlatVolumeComponent.icc cannot be included directly. Please use RadmonDetectorFlatVolumeComponent.hh"
#else /* RADMONDETECTORFLATVOLUMECOMPONENT_HH */
inline RadmonDetectorFlatVolumeComponent :: RadmonDetectorFlatVolumeComponent(const RadmonVDetectorLabelledEntityConstructor * constructor)
:
owner(constructor),
box(0),
visAttributes(0)
{
}
#endif /* RADMONDETECTORFLATVOLUMECOMPONENT_HH */
@@ -0,0 +1,58 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonDetectorFlatVolumeConstructor.hh
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonDetectorFlatVolumeConstructor.hh,v 1.3 2006/06/29 16:09:31 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Description: Builds a box
//
#ifndef RADMONDETECTORFLATVOLUMECONSTRUCTOR_HH
#define RADMONDETECTORFLATVOLUMECONSTRUCTOR_HH
// Include files
#include "RadmonTDetectorLayerConstructor.hh"
#include "RadmonDetectorFlatVolumeComponent.hh"
class RadmonDetectorFlatVolumeConstructor : public RadmonTDetectorLayerConstructor<RadmonDetectorFlatVolumeComponent>
{
public:
inline RadmonDetectorFlatVolumeConstructor();
inline virtual ~RadmonDetectorFlatVolumeConstructor();
private:
// Hidden constructors and operators
RadmonDetectorFlatVolumeConstructor(const RadmonDetectorFlatVolumeConstructor & copy);
RadmonDetectorFlatVolumeConstructor & operator=(const RadmonDetectorFlatVolumeConstructor & copy);
};
// Inline implementations
#include "RadmonDetectorFlatVolumeConstructor.icc"
#endif /* RADMONDETECTORFLATVOLUMECONSTRUCTOR_HH */
@@ -0,0 +1,49 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonDetectorFlatVolumeConstructor.icc
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonDetectorFlatVolumeConstructor.icc,v 1.3 2006/06/29 16:09:33 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
#ifndef RADMONDETECTORFLATVOLUMECONSTRUCTOR_HH
#error "RadmonDetectorFlatVolumeConstructor.icc cannot be included directly. Please use RadmonDetectorFlatVolumeConstructor.hh"
#else /* RADMONDETECTORFLATVOLUMECONSTRUCTOR_HH */
inline RadmonDetectorFlatVolumeConstructor :: RadmonDetectorFlatVolumeConstructor()
:
RadmonTDetectorLayerConstructor<RadmonDetectorFlatVolumeComponent>("FlatVolume")
{
}
inline RadmonDetectorFlatVolumeConstructor :: ~RadmonDetectorFlatVolumeConstructor()
{
}
#endif /* RADMONDETECTORFLATVOLUMECONSTRUCTOR_HH */
@@ -0,0 +1,61 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonDetectorFlatVolumeWithGroundAndKeyMarksAndHoleConstructor.hh
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonDetectorFlatVolumeWithGroundAndKeyMarksAndHoleConstructor.hh,v 1.3 2006/06/29 16:09:35 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Description: Builds a box with a ground pad, marks and hole
//
#ifndef RADMONDETECTORFLATVOLUMEWITHGROUNDANDKEYMARKSANDHOLECONSTRUCTOR_HH
#define RADMONDETECTORFLATVOLUMEWITHGROUNDANDKEYMARKSANDHOLECONSTRUCTOR_HH
// Include files
#include "RadmonTDetectorLayerConstructor.hh"
#include "RadmonTDetectorVolumesWithGroundDecorator.hh"
#include "RadmonTDetectorVolumesWithKeyMarksDecorator.hh"
#include "RadmonTDetectorVolumesWithHoleDecorator.hh"
#include "RadmonDetectorFlatVolumeComponent.hh"
class RadmonDetectorFlatVolumeWithGroundAndKeyMarksAndHoleConstructor : public RadmonTDetectorLayerConstructor<RadmonTDetectorVolumesWithHoleDecorator<RadmonTDetectorVolumesWithKeyMarksDecorator<RadmonTDetectorVolumesWithGroundDecorator<RadmonDetectorFlatVolumeComponent> > > >
{
public:
inline RadmonDetectorFlatVolumeWithGroundAndKeyMarksAndHoleConstructor();
inline virtual ~RadmonDetectorFlatVolumeWithGroundAndKeyMarksAndHoleConstructor();
private:
// Hidden constructors and operators
RadmonDetectorFlatVolumeWithGroundAndKeyMarksAndHoleConstructor(const RadmonDetectorFlatVolumeWithGroundAndKeyMarksAndHoleConstructor & copy);
RadmonDetectorFlatVolumeWithGroundAndKeyMarksAndHoleConstructor & operator=(const RadmonDetectorFlatVolumeWithGroundAndKeyMarksAndHoleConstructor & copy);
};
// Inline implementations
#include "RadmonDetectorFlatVolumeWithGroundAndKeyMarksAndHoleConstructor.icc"
#endif /* RADMONDETECTORFLATVOLUMEWITHGROUNDANDKEYMARKSANDHOLECONSTRUCTOR_HH */
@@ -0,0 +1,49 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonDetectorFlatVolumeWithGroundAndKeyMarksAndHoleConstructor.icc
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonDetectorFlatVolumeWithGroundAndKeyMarksAndHoleConstructor.icc,v 1.3 2006/06/29 16:09:37 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
#ifndef RADMONDETECTORFLATVOLUMEWITHGROUNDANDKEYMARKSANDHOLECONSTRUCTOR_HH
#error "RadmonDetectorFlatVolumeWithGroundAndKeyMarksAndHoleConstructor.icc cannot be included directly. Please use RadmonDetectorFlatVolumeWithGroundAndKeyMarksAndHoleConstructor.hh"
#else /* RADMONDETECTORFLATVOLUMEWITHGROUNDANDKEYMARKSANDHOLECONSTRUCTOR_HH */
inline RadmonDetectorFlatVolumeWithGroundAndKeyMarksAndHoleConstructor :: RadmonDetectorFlatVolumeWithGroundAndKeyMarksAndHoleConstructor()
:
RadmonTDetectorLayerConstructor<RadmonTDetectorVolumesWithHoleDecorator<RadmonTDetectorVolumesWithKeyMarksDecorator<RadmonTDetectorVolumesWithGroundDecorator<RadmonDetectorFlatVolumeComponent> > > >("FlatVolumeWithGroundAndKeyMarksAndHole")
{
}
inline RadmonDetectorFlatVolumeWithGroundAndKeyMarksAndHoleConstructor :: ~RadmonDetectorFlatVolumeWithGroundAndKeyMarksAndHoleConstructor()
{
}
#endif /* RADMONDETECTORFLATVOLUMEWITHGROUNDANDKEYMARKSANDHOLECONSTRUCTOR_HH */
@@ -0,0 +1,60 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonDetectorFlatVolumeWithGroundAndKeyMarksConstructor.hh
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonDetectorFlatVolumeWithGroundAndKeyMarksConstructor.hh,v 1.3 2006/06/29 16:09:39 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Description: Builds a box with a ground pad and marks
//
#ifndef RADMONDETECTORFLATVOLUMEWITHGROUNDANDKEYMARKSCONSTRUCTOR_HH
#define RADMONDETECTORFLATVOLUMEWITHGROUNDANDKEYMARKSCONSTRUCTOR_HH
// Include files
#include "RadmonTDetectorLayerConstructor.hh"
#include "RadmonTDetectorVolumesWithGroundDecorator.hh"
#include "RadmonTDetectorVolumesWithKeyMarksDecorator.hh"
#include "RadmonDetectorFlatVolumeComponent.hh"
class RadmonDetectorFlatVolumeWithGroundAndKeyMarksConstructor : public RadmonTDetectorLayerConstructor<RadmonTDetectorVolumesWithKeyMarksDecorator<RadmonTDetectorVolumesWithGroundDecorator<RadmonDetectorFlatVolumeComponent> > >
{
public:
inline RadmonDetectorFlatVolumeWithGroundAndKeyMarksConstructor();
inline virtual ~RadmonDetectorFlatVolumeWithGroundAndKeyMarksConstructor();
private:
// Hidden constructors and operators
RadmonDetectorFlatVolumeWithGroundAndKeyMarksConstructor(const RadmonDetectorFlatVolumeWithGroundAndKeyMarksConstructor & copy);
RadmonDetectorFlatVolumeWithGroundAndKeyMarksConstructor & operator=(const RadmonDetectorFlatVolumeWithGroundAndKeyMarksConstructor & copy);
};
// Inline implementations
#include "RadmonDetectorFlatVolumeWithGroundAndKeyMarksConstructor.icc"
#endif /* RADMONDETECTORFLATVOLUMEWITHGROUNDANDKEYMARKSCONSTRUCTOR_HH */
@@ -0,0 +1,49 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonDetectorFlatVolumeWithGroundAndKeyMarksConstructor.icc
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonDetectorFlatVolumeWithGroundAndKeyMarksConstructor.icc,v 1.3 2006/06/29 16:09:41 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
#ifndef RADMONDETECTORFLATVOLUMEWITHGROUNDANDKEYMARKSCONSTRUCTOR_HH
#error "RadmonDetectorFlatVolumeWithGroundAndKeyMarksConstructor.icc cannot be included directly. Please use RadmonDetectorFlatVolumeWithGroundAndKeyMarksConstructor.hh"
#else /* RADMONDETECTORFLATVOLUMEWITHGROUNDANDKEYMARKSCONSTRUCTOR_HH */
inline RadmonDetectorFlatVolumeWithGroundAndKeyMarksConstructor :: RadmonDetectorFlatVolumeWithGroundAndKeyMarksConstructor()
:
RadmonTDetectorLayerConstructor<RadmonTDetectorVolumesWithKeyMarksDecorator<RadmonTDetectorVolumesWithGroundDecorator<RadmonDetectorFlatVolumeComponent> > >("FlatVolumeWithGroundAndKeyMarks")
{
}
inline RadmonDetectorFlatVolumeWithGroundAndKeyMarksConstructor :: ~RadmonDetectorFlatVolumeWithGroundAndKeyMarksConstructor()
{
}
#endif /* RADMONDETECTORFLATVOLUMEWITHGROUNDANDKEYMARKSCONSTRUCTOR_HH */
@@ -0,0 +1,59 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonDetectorFlatVolumeWithGroundConstructor.hh
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonDetectorFlatVolumeWithGroundConstructor.hh,v 1.3 2006/06/29 16:09:43 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Description: Builds a box with carved borders
//
#ifndef RADMONDETECTORFLATVOLUMEWITHGROUNDCONSTRUCTOR_HH
#define RADMONDETECTORFLATVOLUMEWITHGROUNDCONSTRUCTOR_HH
// Include files
#include "RadmonTDetectorLayerConstructor.hh"
#include "RadmonTDetectorVolumesWithGroundDecorator.hh"
#include "RadmonDetectorFlatVolumeComponent.hh"
class RadmonDetectorFlatVolumeWithGroundConstructor : public RadmonTDetectorLayerConstructor<RadmonTDetectorVolumesWithGroundDecorator<RadmonDetectorFlatVolumeComponent> >
{
public:
inline RadmonDetectorFlatVolumeWithGroundConstructor();
inline virtual ~RadmonDetectorFlatVolumeWithGroundConstructor();
private:
// Hidden constructors and operators
RadmonDetectorFlatVolumeWithGroundConstructor(const RadmonDetectorFlatVolumeWithGroundConstructor & copy);
RadmonDetectorFlatVolumeWithGroundConstructor & operator=(const RadmonDetectorFlatVolumeWithGroundConstructor & copy);
};
// Inline implementations
#include "RadmonDetectorFlatVolumeWithGroundConstructor.icc"
#endif /* RADMONDETECTORFLATVOLUMEWITHGROUNDCONSTRUCTOR_HH */
@@ -0,0 +1,49 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonDetectorFlatVolumeWithGroundConstructor.icc
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonDetectorFlatVolumeWithGroundConstructor.icc,v 1.3 2006/06/29 16:09:45 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
#ifndef RADMONDETECTORFLATVOLUMEWITHGROUNDCONSTRUCTOR_HH
#error "RadmonDetectorFlatVolumeWithGroundConstructor.icc cannot be included directly. Please use RadmonDetectorFlatVolumeWithGroundConstructor.hh"
#else /* RADMONDETECTORFLATVOLUMEWITHGROUNDCONSTRUCTOR_HH */
inline RadmonDetectorFlatVolumeWithGroundConstructor :: RadmonDetectorFlatVolumeWithGroundConstructor()
:
RadmonTDetectorLayerConstructor<RadmonTDetectorVolumesWithGroundDecorator<RadmonDetectorFlatVolumeComponent> >("FlatVolumeWithGround")
{
}
inline RadmonDetectorFlatVolumeWithGroundConstructor :: ~RadmonDetectorFlatVolumeWithGroundConstructor()
{
}
#endif /* RADMONDETECTORFLATVOLUMEWITHGROUNDCONSTRUCTOR_HH */
@@ -0,0 +1,59 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonDetectorFlatVolumeWithHoleConstructor.hh
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonDetectorFlatVolumeWithHoleConstructor.hh,v 1.3 2006/06/29 16:09:47 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Description: Builds a box with a hole
//
#ifndef RADMONDETECTORFLATVOLUMEWITHHOLECONSTRUCTOR_HH
#define RADMONDETECTORFLATVOLUMEWITHHOLECONSTRUCTOR_HH
// Include files
#include "RadmonTDetectorLayerConstructor.hh"
#include "RadmonTDetectorVolumesWithHoleDecorator.hh"
#include "RadmonDetectorFlatVolumeComponent.hh"
class RadmonDetectorFlatVolumeWithHoleConstructor : public RadmonTDetectorLayerConstructor<RadmonTDetectorVolumesWithHoleDecorator<RadmonDetectorFlatVolumeComponent> >
{
public:
inline RadmonDetectorFlatVolumeWithHoleConstructor();
inline virtual ~RadmonDetectorFlatVolumeWithHoleConstructor();
private:
// Hidden constructors and operators
RadmonDetectorFlatVolumeWithHoleConstructor(const RadmonDetectorFlatVolumeWithHoleConstructor & copy);
RadmonDetectorFlatVolumeWithHoleConstructor & operator=(const RadmonDetectorFlatVolumeWithHoleConstructor & copy);
};
// Inline implementations
#include "RadmonDetectorFlatVolumeWithHoleConstructor.icc"
#endif /* RADMONDETECTORFLATVOLUMEWITHHOLECONSTRUCTOR_HH */
@@ -0,0 +1,49 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonDetectorFlatVolumeWithHoleConstructor.icc
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonDetectorFlatVolumeWithHoleConstructor.icc,v 1.3 2006/06/29 16:09:49 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
#ifndef RADMONDETECTORFLATVOLUMEWITHHOLECONSTRUCTOR_HH
#error "RadmonDetectorFlatVolumeWithHoleConstructor.icc cannot be included directly. Please use RadmonDetectorFlatVolumeWithHoleConstructor.hh"
#else /* RADMONDETECTORFLATVOLUMEWITHHOLECONSTRUCTOR_HH */
inline RadmonDetectorFlatVolumeWithHoleConstructor :: RadmonDetectorFlatVolumeWithHoleConstructor()
:
RadmonTDetectorLayerConstructor<RadmonTDetectorVolumesWithHoleDecorator<RadmonDetectorFlatVolumeComponent> >("FlatVolumeWithHole")
{
}
inline RadmonDetectorFlatVolumeWithHoleConstructor :: ~RadmonDetectorFlatVolumeWithHoleConstructor()
{
}
#endif /* RADMONDETECTORFLATVOLUMEWITHHOLECONSTRUCTOR_HH */
@@ -0,0 +1,59 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonDetectorFlatVolumeWithPadsConstructor.hh
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonDetectorFlatVolumeWithPadsConstructor.hh,v 1.3 2006/06/29 16:09:51 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Description: Builds a box with pins
//
#ifndef RADMONDETECTORFLATVOLUMEWITHPADSCONSTRUCTOR_HH
#define RADMONDETECTORFLATVOLUMEWITHPADSCONSTRUCTOR_HH
// Include files
#include "RadmonTDetectorLayerConstructor.hh"
#include "RadmonTDetectorVolumesWithPadsDecorator.hh"
#include "RadmonDetectorFlatVolumeComponent.hh"
class RadmonDetectorFlatVolumeWithPadsConstructor : public RadmonTDetectorLayerConstructor<RadmonTDetectorVolumesWithPadsDecorator<RadmonDetectorFlatVolumeComponent> >
{
public:
inline RadmonDetectorFlatVolumeWithPadsConstructor();
inline virtual ~RadmonDetectorFlatVolumeWithPadsConstructor();
private:
// Hidden constructors and operators
RadmonDetectorFlatVolumeWithPadsConstructor(const RadmonDetectorFlatVolumeWithPadsConstructor & copy);
RadmonDetectorFlatVolumeWithPadsConstructor & operator=(const RadmonDetectorFlatVolumeWithPadsConstructor & copy);
};
// Inline implementations
#include "RadmonDetectorFlatVolumeWithPadsConstructor.icc"
#endif /* RADMONDETECTORFLATVOLUMEWITHPADSCONSTRUCTOR_HH */
@@ -0,0 +1,49 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonDetectorFlatVolumeWithPadsConstructor.icc
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonDetectorFlatVolumeWithPadsConstructor.icc,v 1.3 2006/06/29 16:09:53 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
#ifndef RADMONDETECTORFLATVOLUMEWITHPADSCONSTRUCTOR_HH
#error "RadmonDetectorFlatVolumeWithPadsConstructor.icc cannot be included directly. Please use RadmonDetectorFlatVolumeWithPadsConstructor.hh"
#else /* RADMONDETECTORFLATVOLUMEWITHPADSCONSTRUCTOR_HH */
inline RadmonDetectorFlatVolumeWithPadsConstructor :: RadmonDetectorFlatVolumeWithPadsConstructor()
:
RadmonTDetectorLayerConstructor<RadmonTDetectorVolumesWithPadsDecorator<RadmonDetectorFlatVolumeComponent> >("FlatVolumeWithPads")
{
}
inline RadmonDetectorFlatVolumeWithPadsConstructor :: ~RadmonDetectorFlatVolumeWithPadsConstructor()
{
}
#endif /* RADMONDETECTORFLATVOLUMEWITHPADSCONSTRUCTOR_HH */
@@ -0,0 +1,59 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonDetectorFlatVolumeWithPinsConstructor.hh
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonDetectorFlatVolumeWithPinsConstructor.hh,v 1.3 2006/06/29 16:09:55 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
// Description: Builds a box with pins
//
#ifndef RADMONDETECTORFLATVOLUMEWITHPINSCONSTRUCTOR_HH
#define RADMONDETECTORFLATVOLUMEWITHPINSCONSTRUCTOR_HH
// Include files
#include "RadmonTDetectorLayerConstructor.hh"
#include "RadmonTDetectorVolumesWithPinsDecorator.hh"
#include "RadmonDetectorFlatVolumeComponent.hh"
class RadmonDetectorFlatVolumeWithPinsConstructor : public RadmonTDetectorLayerConstructor<RadmonTDetectorVolumesWithPinsDecorator<RadmonDetectorFlatVolumeComponent> >
{
public:
inline RadmonDetectorFlatVolumeWithPinsConstructor();
inline virtual ~RadmonDetectorFlatVolumeWithPinsConstructor();
private:
// Hidden constructors and operators
RadmonDetectorFlatVolumeWithPinsConstructor(const RadmonDetectorFlatVolumeWithPinsConstructor & copy);
RadmonDetectorFlatVolumeWithPinsConstructor & operator=(const RadmonDetectorFlatVolumeWithPinsConstructor & copy);
};
// Inline implementations
#include "RadmonDetectorFlatVolumeWithPinsConstructor.icc"
#endif /* RADMONDETECTORFLATVOLUMEWITHPINSCONSTRUCTOR_HH */
@@ -0,0 +1,49 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// File name: RadmonDetectorFlatVolumeWithPinsConstructor.icc
// Creation date: Sep 2005
// Main author: Riccardo Capra <capra@ge.infn.it>
//
// Id: $Id: RadmonDetectorFlatVolumeWithPinsConstructor.icc,v 1.3 2006/06/29 16:09:57 gunter Exp $
// Tag: $Name: geant4-08-01 $
//
#ifndef RADMONDETECTORFLATVOLUMEWITHPINSCONSTRUCTOR_HH
#error "RadmonDetectorFlatVolumeWithPinsConstructor.icc cannot be included directly. Please use RadmonDetectorFlatVolumeWithPinsConstructor.hh"
#else /* RADMONDETECTORFLATVOLUMEWITHPINSCONSTRUCTOR_HH */
inline RadmonDetectorFlatVolumeWithPinsConstructor :: RadmonDetectorFlatVolumeWithPinsConstructor()
:
RadmonTDetectorLayerConstructor<RadmonTDetectorVolumesWithPinsDecorator<RadmonDetectorFlatVolumeComponent> >("FlatVolumeWithPins")
{
}
inline RadmonDetectorFlatVolumeWithPinsConstructor :: ~RadmonDetectorFlatVolumeWithPinsConstructor()
{
}
#endif /* RADMONDETECTORFLATVOLUMEWITHPINSCONSTRUCTOR_HH */

Some files were not shown because too many files have changed in this diff Show More