19#include "BDSAcceleratorComponent.hh"
20#include "BDSBeamPipeInfo.hh"
21#include "BDSBeamPipeType.hh"
22#include "BDSCavity.hh"
23#include "BDSCavityElement.hh"
24#include "BDSCavityFactory.hh"
25#include "BDSCavityInfo.hh"
26#include "BDSExtent.hh"
27#include "BDSFieldBuilder.hh"
28#include "BDSFieldInfo.hh"
31#include "G4LogicalVolume.hh"
35 G4double chordLengthIn,
36 G4Material* vacuumMaterialIn,
40 "cavity_"+cavityInfoIn->cavityType.ToString()),
41 vacuumFieldInfo(vacuumFieldInfoIn),
42 cavityInfo(cavityInfoIn),
43 vacuumMaterial(vacuumMaterialIn)
46 cavityInfo->irisRadius, 0, 0, 0,
48 cavityInfo->thickness,
49 cavityInfo->material);
52BDSCavityElement::~BDSCavityElement()
Abstract class that represents a component of an accelerator.
void SetAcceleratorVacuumLogicalVolume(G4LogicalVolume *accVacLVIn)
const G4String name
Const protected member variable that may not be changed by derived classes.
virtual std::set< G4LogicalVolume * > GetAcceleratorVacuumLogicalVolumes() const
Access the 'vacuum' volume(s) in this component if any. Default is empty set.
virtual void BuildUserLimits()
virtual void AttachUserLimits() const
Doesn't change member variables, but may change their contents.
G4double chordLength
Protected member variable that can be modified by derived classes.
Holder class for all information required to describe a beam pipe model.
G4Material * vacuumMaterial
Cache of material to be used for vacuum - does not own it.
virtual void BuildContainerLogicalVolume() override
BDSCavityElement()=delete
Private constructor to force the use of the provided one.
const BDSCavityInfo * cavityInfo
Convenience shortcut to cavity information inside field information object.
const BDSFieldInfo * vacuumFieldInfo
Recipe for field.
virtual void Build() override
The full construction sequence that calls all methods in order.
virtual void BuildField()
Creates field objects - doesn't nothing by default and derived classes can override.
static BDSCavityFactory * Instance()
Singleton accessor.
BDSCavity * CreateCavity(const G4String &name, G4double totalChordLength, const BDSCavityInfo *info, G4Material *vacuumMaterial)
Main function to create a piece of cavity geometry.
Holder for all Geometrical information required to create an RF cavity.
A holder class for an RF cavity piece of geometry.
G4LogicalVolume * GetVacuumLogicalVolume() const
Access the vacuum volume to set fields and limits.
void RegisterFieldForConstruction(const BDSFieldInfo *info, G4LogicalVolume *logicalVolume, const G4bool propagateToDaughters=false, const BDSMagnetStrength *magnetStrengthForScaling=nullptr, const G4String &scalingKey="none")
static BDSFieldBuilder * Instance()
Singleton pattern accessor.
All info required to build complete field of any type.
G4LogicalVolume * GetContainerLogicalVolume() const
Accessor - see member for more info.
void InheritExtents(BDSGeometryComponent const *const anotherComponent)
Update the extents of this object with those of another object.
void RegisterDaughter(BDSGeometryComponent *anotherComponent)
G4VSolid * GetContainerSolid() const
Accessor - see member for more info.