BDSIM
BDSIM is a Geant4 extension toolkit for simulation of particle transport in accelerator beamlines.
BDSRegion.hh
1/*
2Beam Delivery Simulation (BDSIM) Copyright (C) Royal Holloway,
3University of London 2001 - 2022.
4
5This file is part of BDSIM.
6
7BDSIM is free software: you can redistribute it and/or modify
8it under the terms of the GNU General Public License as published
9by the Free Software Foundation version 3 of the License.
10
11BDSIM is distributed in the hope that it will be useful, but
12WITHOUT ANY WARRANTY; without even the implied warranty of
13MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14GNU General Public License for more details.
15
16You should have received a copy of the GNU General Public License
17along with BDSIM. If not, see <http://www.gnu.org/licenses/>.
18*/
19#ifndef BDSREGION_H
20#define BDSREGION_H
21
22#include "globals.hh"
23
24#include <ostream>
25
26class G4ProductionCuts;
27class G4Region;
28
29namespace GMAD
30{
31 class Region;
32}
33
41{
42public:
43 explicit BDSRegion(G4String nameIn);
44 BDSRegion(G4String nameIn,
45 const BDSRegion* defaultValue,
46 G4double defaultRangeCutIn,
47 G4double rangeCutElectronsIn,
48 G4double rangeCutPositronsIn,
49 G4double rangeCutProtonsIn,
50 G4double rangeCutPhotonsIn);
51 BDSRegion(const GMAD::Region& parserRegion,
52 const BDSRegion* defaultRegion);
53
54 ~BDSRegion();
55
57 G4String name;
63 G4ProductionCuts* g4cuts;
64 G4Region* g4region;
66
68 friend std::ostream& operator<< (std::ostream &out, BDSRegion const &r);
69
70private:
72 void ProduceG4Region();
73};
74
75#endif
Range cuts for a region. Help with defaults.
Definition: BDSRegion.hh:41
friend std::ostream & operator<<(std::ostream &out, BDSRegion const &r)
output stream
Definition: BDSRegion.cc:97
G4Region * g4region
Public members for simplicity.
Definition: BDSRegion.hh:64
G4double rangeCutElectrons
Public members for simplicity.
Definition: BDSRegion.hh:59
G4double defaultRangeCut
Public members for simplicity.
Definition: BDSRegion.hh:58
G4ProductionCuts * g4cuts
Public members for simplicity.
Definition: BDSRegion.hh:63
G4String name
Public members for simplicity.
Definition: BDSRegion.hh:57
G4double rangeCutPhotons
Public members for simplicity.
Definition: BDSRegion.hh:62
G4double rangeCutProtons
Public members for simplicity.
Definition: BDSRegion.hh:61
G4double rangeCutPositrons
Public members for simplicity.
Definition: BDSRegion.hh:60
void ProduceG4Region()
Function to create cuts and region.
Definition: BDSRegion.cc:108
Region class for parser.
Definition: region.h:36
Parser namespace for GMAD language. Combination of Geant4 and MAD.