BDSIM
BDSIM is a Geant4 extension toolkit for simulation of particle transport in accelerator beamlines.
Loading...
Searching...
No Matches
BDSFieldInfoExtra.hh
1/*
2Beam Delivery Simulation (BDSIM) Copyright (C) BDSIM Collaboration, 2001 - 2026.
3
4This file is part of BDSIM.
5
6BDSIM is free software: you can redistribute it and/or modify
7it under the terms of the GNU General Public License as published
8by the Free Software Foundation version 3 of the License.
9
10BDSIM is distributed in the hope that it will be useful, but
11WITHOUT ANY WARRANTY; without even the implied warranty of
12MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13GNU General Public License for more details.
14
15You should have received a copy of the GNU General Public License
16along with BDSIM. If not, see <http://www.gnu.org/licenses/>.
17*/
18#ifndef BDSFIELDINFOEXTRA_H
19#define BDSFIELDINFOEXTRA_H
20
21#include "BDSFieldType.hh"
22#include "BDSMuonCoolerStructs.hh"
23
24#include <vector>
25
41{
42public:
44 virtual ~BDSFieldInfoExtra(){;}
45
47 virtual BDSFieldInfoExtra* Clone() const = 0;
48};
49
57{
58public:
61 BDSFieldType electricFieldTypeIn,
62 BDSFieldType dipoleFieldTypeIn,
63 const std::vector<BDS::MuonCoolerCoilInfo>& coilInfosIn,
64 const std::vector<BDS::MuonCoolerDipoleInfo>& dipoleInfosIn,
65 const std::vector<BDS::MuonCoolerCavityInfo>& cavityInfosIn):
66 magneticFieldType(magneticFieldTypeIn),
67 electricFieldType(electricFieldTypeIn),
68 dipoleFieldType(dipoleFieldTypeIn),
69 coilInfos(coilInfosIn),
70 dipoleInfos(dipoleInfosIn),
71 cavityInfos(cavityInfosIn)
72 {;}
74
78 std::vector<BDS::MuonCoolerCoilInfo> coilInfos;
79 std::vector<BDS::MuonCoolerDipoleInfo> dipoleInfos;
80 std::vector<BDS::MuonCoolerCavityInfo> cavityInfos;
81
82 virtual BDSFieldInfoExtra* Clone() const {return new BDSFieldInfoExtraMuonCooler(*this);}
83};
84
85#endif
necessary extra information for a muon cooler field.
BDSFieldType dipoleFieldType
Type of the dipole sub-field.
BDSFieldType electricFieldType
Type of the electric sub-field.
BDSFieldInfoExtraMuonCooler(BDSFieldType magneticFieldTypeIn, BDSFieldType electricFieldTypeIn, BDSFieldType dipoleFieldTypeIn, const std::vector< BDS::MuonCoolerCoilInfo > &coilInfosIn, const std::vector< BDS::MuonCoolerDipoleInfo > &dipoleInfosIn, const std::vector< BDS::MuonCoolerCavityInfo > &cavityInfosIn)
virtual BDSFieldInfoExtra * Clone() const
Derived class must implement for copying.
BDSFieldType magneticFieldType
Type of the magnetic sub-field.
Base class for any extra (complex) information for a particular field.
virtual BDSFieldInfoExtra * Clone() const =0
Derived class must implement for copying.