OPAL (Object Oriented Parallel Accelerator Library) 2022.1
OPAL
UndulatorRep.h
Go to the documentation of this file.
1//
2// Class UndulatorRep
3// Defines a concrete undulator/wiggler representation.
4//
5// Copyright (c) 2020, Arnau AlbĂ , Paul Scherrer Institut, Villigen PSI, Switzerland
6// All rights reserved.
7//
8// Implemented as part of the MSc thesis
9// "Start-to-End Modelling of the AWA Micro-Bunched Electron Cooling POP-Experiment"
10//
11// This file is part of OPAL.
12//
13// OPAL is free software: you can redistribute it and/or modify
14// it under the terms of the GNU General Public License as published by
15// the Free Software Foundation, either version 3 of the License, or
16// (at your option) any later version.
17//
18// You should have received a copy of the GNU General Public License
19// along with OPAL. If not, see <https://www.gnu.org/licenses/>.
20//
21#ifndef CLASSIC_UndulatorRep_HH
22#define CLASSIC_UndulatorRep_HH
23
25
27#include "Fields/NullField.h"
28
29class UndulatorRep : public Undulator {
30public:
32 explicit UndulatorRep(const std::string& name);
33
36 virtual ~UndulatorRep();
37
39 // Return an identical deep copy of the element.
40 virtual ElementBase* clone() const;
41
43 // This method constructs a Channel permitting read/write access to
44 // the attribute [b]aKey[/b] and returns it.
45 // If the attribute does not exist, it returns nullptr.
46 virtual Channel* getChannel(const std::string& aKey, bool = false);
47
49 // Version for non-constant object.
50 virtual NullField& getField();
51
53 // Version for constant object.
54 virtual const NullField& getField() const;
55
57 // Version for non-constant object.
59
61 // Version for constant object.
62 virtual const StraightGeometry& getGeometry() const;
63
64private:
65 // Not implemented.
66 void operator=(const UndulatorRep&);
67
70
73};
74
75#endif // CLASSIC_UndulatorRep_HH
const std::string name
virtual Channel * getChannel(const std::string &aKey, bool=false)
Construct a read/write channel.
virtual ~UndulatorRep()
virtual ElementBase * clone() const
Return clone.
virtual NullField & getField()
Get field.
StraightGeometry geometry
The geometry.
Definition: UndulatorRep.h:72
virtual StraightGeometry & getGeometry()
Get geometry.
void operator=(const UndulatorRep &)
NullField field
The zero magnetic field.
Definition: UndulatorRep.h:69
A geometry representing a straight line.
Abstract interface for read/write access to variable.
Definition: Channel.h:32
A zero electromagnetic field.
Definition: NullField.h:30