Import Geant4 4.0.0 source tree
This commit is contained in:
@@ -1,18 +0,0 @@
|
||||
# $Id: GNUmakefile,v 1.1.1.1 2000/06/21 12:36:24 barrand Exp $
|
||||
# -------------------------------------------------------------
|
||||
# GNUmakefile for visualization library. John Allison, 5/7/95.
|
||||
|
||||
name := G4analysis_management
|
||||
|
||||
ifndef G4INSTALL
|
||||
G4INSTALL = ../../..
|
||||
endif
|
||||
|
||||
include $(G4INSTALL)/config/architecture.gmk
|
||||
include $(G4INSTALL)/config/analysis.gmk
|
||||
G4TMPDIR = $(G4TMP)/$(G4SYSTEM)/$(name)
|
||||
|
||||
CPPFLAGS += -I$(G4BASE)/global/management/include
|
||||
|
||||
include $(G4INSTALL)/config/common.gmk
|
||||
|
||||
@@ -1,69 +0,0 @@
|
||||
//
|
||||
// ********************************************************************
|
||||
// * DISCLAIMER *
|
||||
// * *
|
||||
// * The following disclaimer summarizes all the specific disclaimers *
|
||||
// * of contributors to this software. The specific disclaimers,which *
|
||||
// * govern, are listed with their locations in: *
|
||||
// * http://cern.ch/geant4/license *
|
||||
// * *
|
||||
// * 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. *
|
||||
// * *
|
||||
// * This code implementation is the intellectual property of the *
|
||||
// * GEANT4 collaboration. *
|
||||
// * By copying, distributing or modifying the Program (or any work *
|
||||
// * based on the Program) you indicate your acceptance of this *
|
||||
// * statement, and all its terms. *
|
||||
// ********************************************************************
|
||||
//
|
||||
//
|
||||
// $Id: G4AnalysisManager.hh,v 1.8.4.1 2001/06/28 19:07:47 gunter Exp $
|
||||
// GEANT4 tag $Name: $
|
||||
//
|
||||
//
|
||||
// Guy Barrand 20th Mai 2000
|
||||
//
|
||||
// Class description
|
||||
//
|
||||
// Base class for the analysis manager proxy mechanism.
|
||||
//
|
||||
|
||||
#ifndef G4ANALYSIS_HH
|
||||
#define G4ANALYSIS_HH
|
||||
|
||||
#if defined(G4ANALYSIS_BUILD) || defined(G4ANALYSIS_USE)
|
||||
|
||||
#include "globals.hh"
|
||||
#include "g4std/vector"
|
||||
#include "G4VAnalysisManager.hh"
|
||||
|
||||
class G4AnalysisManager : public G4VAnalysisManager {
|
||||
public: // I methods :
|
||||
G4bool RegisterAnalysisSystem(G4VAnalysisSystem*);
|
||||
IHistogramFactory* GetHistogramFactory(const G4String&);
|
||||
//
|
||||
virtual void Store(IHistogram* = 0,const G4String& = "");
|
||||
virtual void Plot(IHistogram*);
|
||||
public:
|
||||
G4AnalysisManager();
|
||||
virtual ~G4AnalysisManager();
|
||||
private:
|
||||
G4VAnalysisSystem* FindSystem(const G4String&);
|
||||
G4std::vector<G4VAnalysisSystem*> fSystems;
|
||||
G4VAnalysisSystem* fCurrentSystem;
|
||||
//
|
||||
#ifdef G4ANALYSIS_NON_AIDA
|
||||
public:
|
||||
ICloudFactory* GetCloudFactory(const G4String&);
|
||||
virtual void Plot(ICloud*);
|
||||
ITuple* CreateTuple(const G4String&,const G4String&,const G4String&);
|
||||
#endif
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
#endif
|
||||
@@ -1,73 +0,0 @@
|
||||
//
|
||||
// ********************************************************************
|
||||
// * DISCLAIMER *
|
||||
// * *
|
||||
// * The following disclaimer summarizes all the specific disclaimers *
|
||||
// * of contributors to this software. The specific disclaimers,which *
|
||||
// * govern, are listed with their locations in: *
|
||||
// * http://cern.ch/geant4/license *
|
||||
// * *
|
||||
// * 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. *
|
||||
// * *
|
||||
// * This code implementation is the intellectual property of the *
|
||||
// * GEANT4 collaboration. *
|
||||
// * By copying, distributing or modifying the Program (or any work *
|
||||
// * based on the Program) you indicate your acceptance of this *
|
||||
// * statement, and all its terms. *
|
||||
// ********************************************************************
|
||||
//
|
||||
//
|
||||
// $Id: G4VAnalysisManager.hh,v 1.5.4.1 2001/06/28 19:07:47 gunter Exp $
|
||||
// GEANT4 tag $Name: $
|
||||
//
|
||||
// Guy Barrand 20th Mai 2000
|
||||
//
|
||||
// Class description
|
||||
//
|
||||
// Abstract base class for the analysis manager proxy mechanism.
|
||||
//
|
||||
|
||||
#ifndef G4VANALYSIS_HH
|
||||
#define G4VANALYSIS_HH
|
||||
|
||||
#if defined(G4ANALYSIS_BUILD) || defined(G4ANALYSIS_USE)
|
||||
|
||||
#include "globals.hh"
|
||||
|
||||
class IHistogram;
|
||||
class IHistogramFactory;
|
||||
|
||||
#ifdef G4ANALYSIS_NON_AIDA
|
||||
class ICloudFactory;
|
||||
class ICloud;
|
||||
class ITuple;
|
||||
#endif
|
||||
|
||||
class G4VAnalysisSystem;
|
||||
|
||||
class G4VAnalysisManager {
|
||||
public:
|
||||
virtual ~G4VAnalysisManager() {}
|
||||
virtual G4bool RegisterAnalysisSystem(G4VAnalysisSystem*) = 0;
|
||||
//
|
||||
// Get the factories :
|
||||
virtual IHistogramFactory* GetHistogramFactory(const G4String&) = 0;
|
||||
//
|
||||
// Access to facilites methods :
|
||||
virtual void Store(IHistogram* = 0,const G4String& = "") = 0;
|
||||
virtual void Plot(IHistogram*) = 0;
|
||||
//
|
||||
#ifdef G4ANALYSIS_NON_AIDA
|
||||
virtual ICloudFactory* GetCloudFactory(const G4String&) = 0;
|
||||
virtual ITuple* CreateTuple(const G4String&,const G4String&,const G4String&) = 0;
|
||||
virtual void Plot(ICloud*) = 0;
|
||||
#endif
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
#endif
|
||||
@@ -1,63 +0,0 @@
|
||||
//
|
||||
// ********************************************************************
|
||||
// * DISCLAIMER *
|
||||
// * *
|
||||
// * The following disclaimer summarizes all the specific disclaimers *
|
||||
// * of contributors to this software. The specific disclaimers,which *
|
||||
// * govern, are listed with their locations in: *
|
||||
// * http://cern.ch/geant4/license *
|
||||
// * *
|
||||
// * 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. *
|
||||
// * *
|
||||
// * This code implementation is the intellectual property of the *
|
||||
// * GEANT4 collaboration. *
|
||||
// * By copying, distributing or modifying the Program (or any work *
|
||||
// * based on the Program) you indicate your acceptance of this *
|
||||
// * statement, and all its terms. *
|
||||
// ********************************************************************
|
||||
//
|
||||
//
|
||||
// $Id: G4VAnalysisSystem.hh,v 1.8.4.1 2001/06/28 19:07:47 gunter Exp $
|
||||
// GEANT4 tag $Name: $
|
||||
//
|
||||
//
|
||||
|
||||
#ifndef G4VANALYSISSYSTEM_HH
|
||||
#define G4VANALYSISSYSTEM_HH
|
||||
|
||||
#ifdef G4ANALYSIS_BUILD
|
||||
|
||||
#include "g4rw/cstring.h"
|
||||
|
||||
class IHistogram;
|
||||
class IHistogramFactory;
|
||||
|
||||
#ifdef G4ANALYSIS_NON_AIDA
|
||||
class ICloudFactory;
|
||||
class ICloud;
|
||||
class ITuple;
|
||||
#endif
|
||||
|
||||
class G4VAnalysisSystem {
|
||||
public:
|
||||
virtual ~G4VAnalysisSystem() {}
|
||||
virtual const G4String& GetName() const = 0;
|
||||
virtual IHistogramFactory* GetHistogramFactory() = 0;
|
||||
//
|
||||
virtual void Store(IHistogram* = 0,const G4String& = "") = 0;
|
||||
virtual void Plot(IHistogram*) = 0;
|
||||
//
|
||||
#ifdef G4ANALYSIS_NON_AIDA
|
||||
virtual ICloudFactory* GetCloudFactory() = 0;
|
||||
virtual void Plot(ICloud*) = 0;
|
||||
virtual ITuple* CreateTuple(const G4String&,const G4String&) = 0;
|
||||
#endif
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
#endif
|
||||
@@ -1,121 +0,0 @@
|
||||
//
|
||||
// ********************************************************************
|
||||
// * DISCLAIMER *
|
||||
// * *
|
||||
// * The following disclaimer summarizes all the specific disclaimers *
|
||||
// * of contributors to this software. The specific disclaimers,which *
|
||||
// * govern, are listed with their locations in: *
|
||||
// * http://cern.ch/geant4/license *
|
||||
// * *
|
||||
// * 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. *
|
||||
// * *
|
||||
// * This code implementation is the intellectual property of the *
|
||||
// * GEANT4 collaboration. *
|
||||
// * By copying, distributing or modifying the Program (or any work *
|
||||
// * based on the Program) you indicate your acceptance of this *
|
||||
// * statement, and all its terms. *
|
||||
// ********************************************************************
|
||||
//
|
||||
//
|
||||
// $Id: G4AnalysisManager.cc,v 1.10.4.1 2001/06/28 19:07:48 gunter Exp $
|
||||
// GEANT4 tag $Name: $
|
||||
//
|
||||
// Guy Barrand 20th Mai 2000
|
||||
//
|
||||
// Class description
|
||||
//
|
||||
// This class is a plug-in for various analysis systems
|
||||
// that follow the AIDA/Histogramming conventions.
|
||||
//
|
||||
#ifdef G4ANALYSIS_BUILD
|
||||
|
||||
#include "globals.hh"
|
||||
#include "G4ios.hh"
|
||||
|
||||
#include "G4VAnalysisSystem.hh"
|
||||
#include "G4AnalysisManager.hh"
|
||||
|
||||
G4AnalysisManager::G4AnalysisManager(){}
|
||||
G4AnalysisManager::~G4AnalysisManager(){
|
||||
int number = fSystems.size();
|
||||
for(int count=0;count<number;count++) {
|
||||
delete fSystems[count];
|
||||
}
|
||||
}
|
||||
G4bool G4AnalysisManager::RegisterAnalysisSystem(
|
||||
G4VAnalysisSystem* aSystem
|
||||
){
|
||||
fSystems.push_back(aSystem);
|
||||
return true;
|
||||
}
|
||||
G4VAnalysisSystem* G4AnalysisManager::FindSystem(const G4String& aName) {
|
||||
int number = fSystems.size();
|
||||
for(int count=0;count<number;count++) {
|
||||
if(aName==fSystems[count]->GetName()) return fSystems[count];
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
IHistogramFactory* G4AnalysisManager::GetHistogramFactory(
|
||||
const G4String& aSystem
|
||||
){
|
||||
G4VAnalysisSystem* analysisSystem = FindSystem(aSystem);
|
||||
if(!analysisSystem) {
|
||||
G4cerr << "G4AnalysisManager : " << G4std::endl;
|
||||
G4cerr << " " << aSystem << " unknown analysis system." << G4std::endl;
|
||||
return 0;
|
||||
}
|
||||
// Set it as current system.
|
||||
fCurrentSystem = analysisSystem;
|
||||
return analysisSystem->GetHistogramFactory();
|
||||
}
|
||||
void G4AnalysisManager::Store(IHistogram* aHistogram,const G4String& aSID){
|
||||
if(!fCurrentSystem) return;
|
||||
fCurrentSystem->Store(aHistogram,aSID);
|
||||
}
|
||||
void G4AnalysisManager::Plot(IHistogram* aHistogram){
|
||||
if(!fCurrentSystem) return;
|
||||
fCurrentSystem->Plot(aHistogram);
|
||||
}
|
||||
|
||||
// Non AIDA things :
|
||||
#ifdef G4ANALYSIS_NON_AIDA
|
||||
ITuple* G4AnalysisManager::CreateTuple(
|
||||
const G4String& aSystem
|
||||
,const G4String& aStorage
|
||||
,const G4String& aSID
|
||||
){
|
||||
G4VAnalysisSystem* analysisSystem = FindSystem(aSystem);
|
||||
if(!analysisSystem) {
|
||||
G4cerr << "G4AnalysisManager : " << G4std::endl;
|
||||
G4cerr << " " << aSystem << " unknown analysis system." << G4std::endl;
|
||||
return 0;
|
||||
}
|
||||
// Set it as current system.
|
||||
fCurrentSystem = analysisSystem;
|
||||
return analysisSystem->CreateTuple(aStorage,aSID);
|
||||
}
|
||||
ICloudFactory* G4AnalysisManager::GetCloudFactory(
|
||||
const G4String& aSystem
|
||||
){
|
||||
G4VAnalysisSystem* analysisSystem = FindSystem(aSystem);
|
||||
if(!analysisSystem) {
|
||||
G4cerr << "G4AnalysisManager : " << G4std::endl;
|
||||
G4cerr << " " << aSystem << " unknown analysis system." << G4std::endl;
|
||||
return 0;
|
||||
}
|
||||
// Set it as current system.
|
||||
fCurrentSystem = analysisSystem;
|
||||
return analysisSystem->GetCloudFactory();
|
||||
}
|
||||
void G4AnalysisManager::Plot(ICloud* aCloud){
|
||||
if(!fCurrentSystem) return;
|
||||
fCurrentSystem->Plot(aCloud);
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif
|
||||
Reference in New Issue
Block a user