LOGO

RestFrames  v1.0.1
RestFrames HEP Event Analysis Software Library
Public Member Functions | Static Public Member Functions | Protected Attributes | List of all members
RestFrames::State Class Referenceabstract

Detailed Description

Abstract base class for all State objects.

State is a very meaningful class and it is important to learn how it works in order to understand RestFrames, however users should not need to call its methods or use it directly.
States can be seen as four vector associated with a frame or group of frames evaluated in a specific reference frame. Each Jigsaw has their own state.

Definition at line 47 of file State.hh.

Inheritance diagram for RestFrames::State:
Inheritance graph
[legend]

Public Member Functions

 State (const std::string &sname, const std::string &stitle)
 Standard constructor. More...
 
 State ()
 Empty constructor.
 
virtual void Clear ()
 Clears State of all connections to other objects.
 
StateType GetType () const
 Returns State (StateType) type. More...
 
bool IsVisibleState () const
 Is this a VisibleState? (true/false) More...
 
bool IsInvisibleState () const
 Is this an InvisibleState? (true/false) More...
 
bool IsCombinatoricState () const
 Is this a CombinatoricState? (true/false) More...
 
virtual void AddFrame (const RestFrame &frame)=0
 Pure virtual function defined in derivatives of State class.
 
virtual void AddFrames (const ConstRestFrameList &frames)
 Adds a list of frames (RestFrame) to this state. More...
 
ConstRestFrameList const & GetListFrames () const
 Returns list of frames (RestFrame) contained in this state. More...
 
int GetNFrames () const
 Returns number of frames (RestFrame) contained in this state. More...
 
virtual bool IsFrame (const RestFrame &frame) const
 Checks if frame of state corresponds to frame More...
 
virtual bool IsFrames (const ConstRestFrameList &frames) const
 Checks if frames lists of state corresponds frames More...
 
virtual void SetParentJigsaw (Jigsaw &jigsaw=Jigsaw::Empty())
 Sets the parent jigsaw (Jigsaw) to jigsaw More...
 
virtual void SetChildJigsaw (Jigsaw &jigsaw=Jigsaw::Empty())
 Sets the child jigsaw (Jigsaw) to jigsaw More...
 
virtual JigsawGetParentJigsaw () const
 Returns the parent of this jigsaw (Jigsaw) More...
 
virtual JigsawGetChildJigsaw () const
 Returns the child of this jigsaw (Jigsaw) More...
 
virtual void Boost (const TVector3 &B)
 Boosts to different frame (RestFrame) More...
 
virtual void SetFourVector (const TLorentzVector &V)
 Sets four-vector of this frame. More...
 
virtual TLorentzVector GetFourVector () const
 Returns four vector of this frame. More...
 
virtual RFCharge GetCharge () const
 Returns charge of this frames. More...
 
- Public Member Functions inherited from RestFrames::RFBase
 RFBase (const std::string &sname, const std::string &stitle, int key)
 Standard constructor. More...
 
 RFBase ()
 Empty constructor.
 
bool IsEmpty () const
 Checks whether this is default (empty) instance of class.
 
bool operator! () const
 Tests whether key is the same as this.
 
void Print (LogType type) const
 Print information associated with object.
 
virtual std::string PrintString (LogType type) const
 String of information associated with object.
 
RFKey GetKey () const
 gets object identification key
 
std::string GetName () const
 Returns object name.
 
std::string GetTitle () const
 Returns object title.
 
bool IsSame (const RFKey &key) const
 Tests whether key is the same as this.
 
bool IsSame (const RFBase &obj) const
 Tests whether obj is the same as this.
 
bool operator== (const RFKey &key) const
 Tests whether key is the same as this.
 
bool operator== (const RFBase &obj) const
 Tests whether obj is the same as this.
 
bool operator!= (const RFKey &key) const
 Tests whether key is the same as this.
 
bool operator!= (const RFBase &obj) const
 Tests whether obj is the same as this.
 

Static Public Member Functions

static StateEmpty ()
 Returns empty state. More...
 
static StateList const & EmptyList ()
 Returns empty StateList. More...
 
- Static Public Member Functions inherited from RestFrames::RFBase
static RFBaseEmpty ()
 Returns empty RFBase. More...
 

Protected Attributes

StateType m_Type
 
RFCharge m_Charge
 
ConstRestFrameList m_Frames
 
- Protected Attributes inherited from RestFrames::RFBase
RFLog m_Log
 
RFBasem_This
 

Additional Inherited Members

- Protected Member Functions inherited from RestFrames::RFBase
bool SetBody (bool body) const
 
bool SetMind (bool mind) const
 
bool SetSpirit (bool spirit) const
 
virtual bool IsSoundBody () const
 
virtual bool IsSoundMind () const
 
virtual bool IsSoundSpirit () const
 
void UnSoundBody (const std::string &function) const
 
void UnSoundMind (const std::string &function) const
 
void UnSoundSpirit (const std::string &function) const
 
void AddDependent (RFBase *dep)
 pointer to RFBase object owned by this one
 
- Static Protected Attributes inherited from RestFrames::RFBase
static const TVector3 m_Empty3Vector
 
static const TLorentzVector m_Empty4Vector
 

Constructor & Destructor Documentation

◆ State()

RestFrames::State::State ( const std::string &  sname,
const std::string &  stitle 
)

Standard constructor.

Parameters
snameClass instance name used for log statements
stitleClass instance title used in figures

Definition at line 42 of file State.cc.

Member Function Documentation

◆ AddFrames()

void RestFrames::State::AddFrames ( const ConstRestFrameList frames)
virtual

Adds a list of frames (RestFrame) to this state.

Parameters
framesList of frames to be added

Method for adding a list of RestFrames to this state. Calls AddFrame() method from derivatives independently for each frame in the frames list.

Definition at line 96 of file State.cc.

◆ Boost()

void RestFrames::State::Boost ( const TVector3 &  B)
virtual

Boosts to different frame (RestFrame)

Parameters
BBoost factor (units: speed of light)

Method for boosting to a different reference frame

Reimplemented in RestFrames::CombinatoricState.

Definition at line 152 of file State.cc.

◆ Empty()

State & RestFrames::State::Empty ( )
static

Returns empty state.

Returns
Empty state

Definition at line 68 of file State.cc.

◆ EmptyList()

StateList const & RestFrames::State::EmptyList ( )
static

Returns empty StateList.

Returns
Empty StateList

Definition at line 72 of file State.cc.

◆ GetCharge()

RFCharge RestFrames::State::GetCharge ( ) const
virtual

Returns charge of this frames.

Returns
Charge of this frame

Reimplemented in RestFrames::CombinatoricState.

Definition at line 169 of file State.cc.

◆ GetChildJigsaw()

Jigsaw & RestFrames::State::GetChildJigsaw ( ) const
virtual

Returns the child of this jigsaw (Jigsaw)

Returns
Child jigsaw of this jigsaw. If the child jigsaw is not set, an empty jigsaw is returned.

Definition at line 145 of file State.cc.

◆ GetFourVector()

TLorentzVector RestFrames::State::GetFourVector ( ) const
virtual

Returns four vector of this frame.

Returns
Four vector of this frame

Reimplemented in RestFrames::CombinatoricState.

Definition at line 165 of file State.cc.

◆ GetListFrames()

ConstRestFrameList const & RestFrames::State::GetListFrames ( ) const

Returns list of frames (RestFrame) contained in this state.

Returns
List of frames contained in this state

Definition at line 102 of file State.cc.

◆ GetNFrames()

int RestFrames::State::GetNFrames ( ) const

Returns number of frames (RestFrame) contained in this state.

Returns
Number of frames contained in this state

Definition at line 106 of file State.cc.

◆ GetParentJigsaw()

Jigsaw & RestFrames::State::GetParentJigsaw ( ) const
virtual

Returns the parent of this jigsaw (Jigsaw)

Returns
Parent jigsaw of this jigsaw. If the parent jigsaw is not set, an empty jigsaw is returned.

Definition at line 138 of file State.cc.

◆ GetType()

StateType RestFrames::State::GetType ( ) const

Returns State (StateType) type.

Returns
State type

Definition at line 77 of file State.cc.

◆ IsCombinatoricState()

bool RestFrames::State::IsCombinatoricState ( ) const

Is this a CombinatoricState? (true/false)

Is this a CombinatoricState? (yes/no)

Definition at line 92 of file State.cc.

◆ IsFrame()

bool RestFrames::State::IsFrame ( const RestFrame frame) const
virtual

Checks if frame of state corresponds to frame

Parameters
frameFrame to check
Returns
True if there is only one frame and matches frame else False

Reimplemented in RestFrames::VisibleState.

Definition at line 110 of file State.cc.

◆ IsFrames()

bool RestFrames::State::IsFrames ( const ConstRestFrameList frames) const
virtual

Checks if frames lists of state corresponds frames

Parameters
framesFrames to check
Returns
True if lists are the same else False

Reimplemented in RestFrames::VisibleState.

Definition at line 116 of file State.cc.

◆ IsInvisibleState()

bool RestFrames::State::IsInvisibleState ( ) const

Is this an InvisibleState? (true/false)

Is this an InvisibleState? (yes/no)

Definition at line 87 of file State.cc.

◆ IsVisibleState()

bool RestFrames::State::IsVisibleState ( ) const

Is this a VisibleState? (true/false)

Is this a VisibleState? (yes/no)

Definition at line 82 of file State.cc.

◆ SetChildJigsaw()

void RestFrames::State::SetChildJigsaw ( Jigsaw jigsaw = Jigsaw::Empty())
virtual

Sets the child jigsaw (Jigsaw) to jigsaw

Parameters
jisawJigsaw to be set as child

Method for connecting a parent jigsaw to its child jigsaw.

See also
What does it mean to set a jigsaw as a child?

Reimplemented in RestFrames::CombinatoricState, and RestFrames::InvisibleState.

Definition at line 129 of file State.cc.

◆ SetFourVector()

void RestFrames::State::SetFourVector ( const TLorentzVector &  V)
virtual

Sets four-vector of this frame.

Parameters
Vinput four-vector

Definition at line 161 of file State.cc.

◆ SetParentJigsaw()

void RestFrames::State::SetParentJigsaw ( Jigsaw jigsaw = Jigsaw::Empty())
virtual

Sets the parent jigsaw (Jigsaw) to jigsaw

Parameters
jisawJigsaw to be set as parent

Method for connecting a child jigsaw to its parent jigsaw.

See also
What does it mean to set a jigsaw as a parent?

Reimplemented in RestFrames::CombinatoricState, and RestFrames::InvisibleState.

Definition at line 120 of file State.cc.

#include "RestFrames/State.hh"

Collaboration diagram for RestFrames::State:
Collaboration graph
[legend]

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