39 std::string(
"The \"VARIABLE_RF_CAVITY\" element defines an RF cavity ")+
40 std::string(
"with time dependent frequency, phase and amplitude.");
45 "The name of the phase time dependence model, which should give the phase in [rad].");
47 "The name of the amplitude time dependence model, which should give the field in [MV/m]");
49 "The name of the frequency time dependence model, which should give the field in [MHz].");
51 "Full width of the cavity [m].");
53 "Full height of the cavity [m].");
89 throw OpalException(
"OpalVariableRFCavity::fillRegisteredAttributes",
90 "Failed to cast ElementBase to a VariableRFCavity");
94 std::shared_ptr<AbstractTimeDependence> phase_model = cavity->
getPhaseModel();
virtual void setFrequencyName(std::string frequency)
virtual std::shared_ptr< AbstractTimeDependence > getFrequencyModel() const
static AttCell * registerStringAttribute(const std::string &name)
Register a ``string'' element attribute.
Interface for basic beam line object.
virtual void fillRegisteredAttributes(const ElementBase &, ValueFlag)
Fill in all registered attributes.
ValueFlag
Switch for value desired on ATTLIST command.
virtual std::shared_ptr< AbstractTimeDependence > getAmplitudeModel() const
The base class for all OPAL exceptions.
virtual ElementBase * removeWrappers()
Return the design element.
virtual void setLength(double length)
std::vector< Attribute > itsAttr
The object attributes (see Attribute.hh).
virtual ~OpalVariableRFCavity()
static std::map< std::string, OwnPtr< AttCell > > attributeRegistry
The registry for named attributes.
const std::string & getOpalName() const
Return object name.
virtual void setWidth(double fullWidth)
virtual void fillRegisteredAttributes(const ElementBase &, ValueFlag)
virtual double getHeight() const
OpalVariableRFCavity * clone()
virtual void setAmplitudeName(std::string amplitude)
Base class for all beam line elements.
virtual double getLength() const
void setElement(ElementBase *)
Assign new CLASSIC element.
virtual std::shared_ptr< AbstractTimeDependence > getPhaseModel() const
void registerOwnership() const
virtual void update()
Update the embedded CLASSIC element.
static std::string getName(std::shared_ptr< AbstractTimeDependence > time_dep)
virtual void setPhaseName(std::string phase)
ElementBase * getElement() const
Return the embedded CLASSIC element.
virtual double getWidth() const
virtual ElementBase * makeAlignWrapper()
Allow misalignment.
static const std::string doc_string
virtual void setHeight(double fullHeight)
double getReal(const Attribute &attr)
Return real value.
Attribute makeString(const std::string &name, const std::string &help)
Make string attribute.
Attribute makeReal(const std::string &name, const std::string &help)
Make real attribute.
static AttCell * registerRealAttribute(const std::string &name)
Register a ``real'' element attribute.
std::string getString(const Attribute &attr)
Get string value.