OPAL (Object Oriented Parallel Accelerator Library) 2024.2
OPAL
PlaceRep Class Reference

Representation of a place within a beam line or sequence. More...

#include <PlaceRep.h>

Collaboration diagram for PlaceRep:

Public Member Functions

 PlaceRep ()
 Default constructor.
 PlaceRep (const std::string &)
 Construct default place.
 PlaceRep (const PlaceRep &)
 ~PlaceRep ()
const PlaceRepoperator= (const PlaceRep &)
void append (const std::string &, int occur)
 Add a name/occurrence pair.
void initialize ()
 Initialise data for search.
void enter (const FlaggedElmPtr &) const
 Enter an element or line.
void leave (const FlaggedElmPtr &) const
 Leave an element or line.
bool isActive () const
 Return status.
bool isSelected () const
 Return select flag.
void print (std::ostream &os) const
 Print in input format.

Private Types

typedef std::vector< std::pair< std::string, int > > Data

Private Attributes

Data data
bool is_selected
bool status
Data::size_type seen

Detailed Description

Representation of a place within a beam line or sequence.

Definition at line 41 of file PlaceRep.h.

Member Typedef Documentation

◆ Data

typedef std::vector<std::pair<std::string, int> > PlaceRep::Data
private

Definition at line 87 of file PlaceRep.h.

Constructor & Destructor Documentation

◆ PlaceRep() [1/3]

PlaceRep::PlaceRep ( )

Default constructor.

Definition at line 29 of file PlaceRep.cpp.

References data, initialize(), and is_selected.

Referenced by operator=(), and PlaceRep().

Here is the call graph for this function:

◆ PlaceRep() [2/3]

PlaceRep::PlaceRep ( const std::string & def)
explicit

Construct default place.

Definition at line 41 of file PlaceRep.cpp.

References append(), data, initialize(), and is_selected.

Here is the call graph for this function:

◆ PlaceRep() [3/3]

PlaceRep::PlaceRep ( const PlaceRep & rhs)

Definition at line 35 of file PlaceRep.cpp.

References data, initialize(), is_selected, and PlaceRep().

Here is the call graph for this function:

◆ ~PlaceRep()

PlaceRep::~PlaceRep ( )

Definition at line 48 of file PlaceRep.cpp.

Member Function Documentation

◆ append()

void PlaceRep::append ( const std::string & name,
int occur )

Add a name/occurrence pair.

Definition at line 59 of file PlaceRep.cpp.

References data, and name.

Referenced by Expressions::parsePlace(), and PlaceRep().

◆ enter()

void PlaceRep::enter ( const FlaggedElmPtr & fep) const

Enter an element or line.

Definition at line 70 of file PlaceRep.cpp.

References data, FlaggedElmPtr::getCounter(), ElmPtr::getElement(), ElementBase::getName(), name, seen, and status.

Here is the call graph for this function:

◆ initialize()

void PlaceRep::initialize ( )

Initialise data for search.

Definition at line 64 of file PlaceRep.cpp.

References seen, and status.

Referenced by operator=(), PlaceRep(), PlaceRep(), and PlaceRep().

◆ isActive()

bool PlaceRep::isActive ( ) const

Return status.

Definition at line 98 of file PlaceRep.cpp.

References status.

◆ isSelected()

bool PlaceRep::isSelected ( ) const

Return select flag.

Definition at line 103 of file PlaceRep.cpp.

References is_selected.

◆ leave()

void PlaceRep::leave ( const FlaggedElmPtr & fep) const

Leave an element or line.

Definition at line 84 of file PlaceRep.cpp.

References data, FlaggedElmPtr::getCounter(), ElmPtr::getElement(), ElementBase::getName(), name, seen, and status.

Here is the call graph for this function:

◆ operator=()

const PlaceRep & PlaceRep::operator= ( const PlaceRep & rhs)

Definition at line 52 of file PlaceRep.cpp.

References data, initialize(), and PlaceRep().

Here is the call graph for this function:

◆ print()

void PlaceRep::print ( std::ostream & os) const

Print in input format.

Definition at line 108 of file PlaceRep.cpp.

References data.

Referenced by operator<<().

Member Data Documentation

◆ data

Data PlaceRep::data
private

Definition at line 88 of file PlaceRep.h.

Referenced by append(), enter(), leave(), operator=(), PlaceRep(), PlaceRep(), PlaceRep(), and print().

◆ is_selected

bool PlaceRep::is_selected
private

Definition at line 91 of file PlaceRep.h.

Referenced by isSelected(), PlaceRep(), PlaceRep(), and PlaceRep().

◆ seen

Data::size_type PlaceRep::seen
mutableprivate

Definition at line 97 of file PlaceRep.h.

Referenced by enter(), initialize(), and leave().

◆ status

bool PlaceRep::status
mutableprivate

Definition at line 94 of file PlaceRep.h.

Referenced by enter(), initialize(), isActive(), and leave().


The documentation for this class was generated from the following files: