Back to home page

EIC code displayed by LXR

 
 

    


Warning, file /include/Geant4/G4GIDI.hh was not indexed or was modified since last indexation (in which case cross-reference links may be missing, inaccurate or erroneous).

0001 //
0002 // ********************************************************************
0003 // * License and Disclaimer                                           *
0004 // *                                                                  *
0005 // * The  Geant4 software  is  copyright of the Copyright Holders  of *
0006 // * the Geant4 Collaboration.  It is provided  under  the terms  and *
0007 // * conditions of the Geant4 Software License,  included in the file *
0008 // * LICENSE and available at  http://cern.ch/geant4/license .  These *
0009 // * include a list of copyright holders.                             *
0010 // *                                                                  *
0011 // * Neither the authors of this software system, nor their employing *
0012 // * institutes,nor the agencies providing financial support for this *
0013 // * work  make  any representation or  warranty, express or implied, *
0014 // * regarding  this  software system or assume any liability for its *
0015 // * use.  Please see the license in the file  LICENSE  and URL above *
0016 // * for the full disclaimer and the limitation of liability.         *
0017 // *                                                                  *
0018 // * This  code  implementation is the result of  the  scientific and *
0019 // * technical work of the GEANT4 collaboration.                      *
0020 // * By using,  copying,  modifying or  distributing the software (or *
0021 // * any work based  on the software)  you  agree  to acknowledge its *
0022 // * use  in  resulting  scientific  publications,  and indicate your *
0023 // * acceptance of all terms of the Geant4 Software license.          *
0024 // ********************************************************************
0025 //
0026 
0027 #ifndef G4GIDI_h_included
0028 #define G4GIDI_h_included 1
0029 
0030 #include <string>
0031 #include <list>
0032 #include <vector>
0033 //using namespace std;
0034 
0035 #include "G4Types.hh"
0036 #include "G4GIDI_Misc.hh"
0037 #include "G4GIDI_map.hh"
0038 #include "G4GIDI_target.hh"
0039 #include "G4GIDI_mass.hh"
0040 
0041 class G4GIDI {
0042 
0043     private:
0044         G4int projectileID;
0045         std::string projectile;
0046         std::list<G4GIDI_map *> dataDirectories;
0047         std::vector<G4GIDI_target *> targets;
0048 
0049         G4int init( G4int ip );
0050 
0051     public:
0052         G4GIDI( G4int ip, std::string &dataDirectory );
0053         G4GIDI( G4int ip, std::list<std::string> &dataDirectory );
0054         ~G4GIDI( );
0055 
0056         G4int numberOfDataDirectories( void );
0057         G4int addDataDirectory( std::string &dataDirectory );
0058         G4int removeDataDirectory( std::string &dataDirectory );
0059         std::string getDataDirectoryAtIndex( G4int index );
0060         std::vector<std::string> *getDataDirectories( void );
0061 
0062         G4bool isThisDataAvailable( std::string &lib_name, G4int iZ, G4int iA, G4int iM = 0 );
0063         G4bool isThisDataAvailable( std::string &lib_name, std::string &targetName );
0064 
0065         char *dataFilename( std::string &lib_name, G4int iZ, G4int iA, G4int iM = 0 );
0066         char *dataFilename( std::string &lib_name, std::string &targetName );
0067 
0068         std::vector<std::string> *getNamesOfAvailableLibraries( G4int iZ, G4int iA, G4int iM = 0 );
0069         std::vector<std::string> *getNamesOfAvailableLibraries( std::string &targetName );
0070 
0071         std::vector<std::string> *getNamesOfAvailableTargets( void );
0072 
0073         G4GIDI_target *readTarget( std::string &lib_name, G4int iZ, G4int iA, G4int iM = 0, G4bool bind = true );
0074         G4GIDI_target *readTarget( std::string &lib_name, std::string &targetName, G4bool bind = true );
0075 
0076         G4GIDI_target *getAlreadyReadTarget( G4int iZ, G4int iA, G4int iM = 0 );
0077         G4GIDI_target *getAlreadyReadTarget( std::string &targetName );
0078 
0079         G4int freeTarget( G4int iZ, G4int iA, G4int iM = 0 );
0080         G4int freeTarget( std::string &targetSymbol );
0081         G4int freeTarget( G4GIDI_target *target );
0082 
0083         std::vector<std::string> *getListOfReadTargetsNames( void );
0084 };
0085 
0086 #endif      // End of G4GIDI_h_included