FairRoot
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
FairMultiLinkedData Class Reference

#include <FairMultiLinkedData.h>

Inheritance diagram for FairMultiLinkedData:
FairDoubleHit FairMCEntry

Public Member Functions

 FairMultiLinkedData ()
 Default constructor. More...
 
 FairMultiLinkedData (const std::set< FairLink > &links, Bool_t persistanceCheck=kTRUE)
 Constructor. More...
 
 FairMultiLinkedData (TString dataType, const std::vector< Int_t > &links, Int_t fileId=-1, Int_t evtId=-1, Bool_t persistanceCheck=kTRUE, Bool_t bypass=kFALSE, Float_t mult=1.0)
 Constructor. More...
 
 FairMultiLinkedData (Int_t dataType, const std::vector< Int_t > &links, Int_t fileId=-1, Int_t evtId=-1, Bool_t persistanceCheck=kTRUE, Bool_t bypass=kFALSE, Float_t mult=1.0)
 Constructor. More...
 
virtual ~FairMultiLinkedData ()
 
virtual std::set< FairLinkGetLinks () const
 returns stored links as FairLinks More...
 
virtual FairLink GetEntryNr () const
 gives back the entryNr More...
 
virtual Int_t GetNLinks () const
 returns the number of stored links More...
 
virtual FairLink GetLink (Int_t pos) const
 returns the FairLink at the given position More...
 
virtual FairMultiLinkedData GetLinksWithType (Int_t type) const
 Gives you a list of links which contain the given type. More...
 
virtual std::vector< FairLinkGetSortedMCTracks ()
 Gives you a list of all FairLinks pointing to a "MCTrack" sorted by their weight. More...
 
TObject * GetData (FairLink &myLink)
 Get the TObject the Link is pointing to. More...
 
virtual Int_t GetDefaultType ()
 
Bool_t GetPersistanceCheck ()
 Returns the value of PersistanceCheck. More...
 
Int_t GetVerbose ()
 Returns the verbosity level. More...
 
virtual void SetDefaultType (Int_t type)
 
virtual void SetPersistanceCheck (Bool_t check)
 Controls if a persistance check of a link is done or not. More...
 
virtual void SetVerbose (Int_t level)
 Sets the verbosity level. More...
 
virtual void SetInsertHistory (Bool_t val)
 Toggles if history of a link is inserted or not. More...
 
Bool_t GetInsertHistory () const
 
virtual void SetEntryNr (FairLink entry)
 
virtual void SetLinks (FairMultiLinkedData links, Float_t mult=1.0)
 Sets the links as vector of FairLink. More...
 
virtual void SetLink (FairLink link, Bool_t bypass=kFALSE, Float_t mult=1.0)
 Sets the Links with a single FairLink. More...
 
virtual void AddLinks (FairMultiLinkedData links, Float_t mult=1.0)
 Adds a List of FairLinks (FairMultiLinkedData) to fLinks. More...
 
virtual void AddLink (FairLink link, Bool_t bypass=kFALSE, Float_t mult=1.0)
 
virtual void InsertLink (FairLink link)
 Inserts a link into the list of links without persistance checking. More...
 
virtual void InsertHistory (FairLink link)
 Adds the FairLinks of the inserted link to the set of links of this object. More...
 
virtual void AddAllWeights (Double_t weight)
 Adds weight to all Links. More...
 
virtual void SetAllWeights (Double_t weight)
 Sets a common weight for Links. More...
 
virtual void MultiplyAllWeights (Double_t weight)
 Multiplies all Links with weight. More...
 
virtual Bool_t IsLinkInList (FairLink link)
 Test if a given link is in fLinks. More...
 
virtual Bool_t IsLinkInList (Int_t type, Int_t index)
 Same as IsLinkInList(FairLink) just with type and index given separately. More...
 
virtual Int_t LinkPosInList (FairLink link)
 returns position of link in fLinks. If it is not in the list -1 is returned More...
 
virtual Int_t LinkPosInList (Int_t type, Int_t index)
 Same as LinkPosInList(FairLink) More...
 
virtual void DeleteLink (FairLink link)
 Deletes a link ouf of fLinks. More...
 
virtual void DeleteLink (Int_t type, Int_t index)
 Deletes a link ouf of fLinks. More...
 
virtual void Reset ()
 
virtual void ResetLinks ()
 Clears fLinks. More...
 
std::ostream & PrintLinkInfo (std::ostream &out=std::cout) const
 Output. More...
 

Protected Member Functions

virtual void SimpleAddLinks (Int_t fileId, Int_t evtId, Int_t dataType, const std::vector< Int_t > &links, Bool_t, Float_t)
 
 ClassDef (FairMultiLinkedData, 4)
 

Protected Attributes

std::set< FairLinkfLinks
 
FairLink fEntryNr
 
Bool_t fPersistanceCheck
 
Bool_t fInsertHistory
 
Int_t fVerbose
 
Int_t fDefaultType
 

Friends

std::ostream & operator<< (std::ostream &out, const FairMultiLinkedData &data)
 Output. More...
 

Detailed Description

Constructor & Destructor Documentation

FairMultiLinkedData::FairMultiLinkedData ( )

Default constructor.

Definition at line 27 of file FairMultiLinkedData.cxx.

FairMultiLinkedData::FairMultiLinkedData ( const std::set< FairLink > &  links,
Bool_t  persistanceCheck = kTRUE 
)

Constructor.

Definition at line 37 of file FairMultiLinkedData.cxx.

FairMultiLinkedData::FairMultiLinkedData ( TString  dataType,
const std::vector< Int_t > &  links,
Int_t  fileId = -1,
Int_t  evtId = -1,
Bool_t  persistanceCheck = kTRUE,
Bool_t  bypass = kFALSE,
Float_t  mult = 1.0 
)

Constructor.

Definition at line 47 of file FairMultiLinkedData.cxx.

FairMultiLinkedData::FairMultiLinkedData ( Int_t  dataType,
const std::vector< Int_t > &  links,
Int_t  fileId = -1,
Int_t  evtId = -1,
Bool_t  persistanceCheck = kTRUE,
Bool_t  bypass = kFALSE,
Float_t  mult = 1.0 
)

Constructor.

Definition at line 66 of file FairMultiLinkedData.cxx.

virtual FairMultiLinkedData::~FairMultiLinkedData ( )
inlinevirtual

Definition at line 48 of file FairMultiLinkedData.h.

Member Function Documentation

void FairMultiLinkedData::AddAllWeights ( Double_t  weight)
virtual

Adds weight to all Links.

Definition at line 338 of file FairMultiLinkedData.cxx.

void FairMultiLinkedData::AddLink ( FairLink  link,
Bool_t  bypass = kFALSE,
Float_t  mult = 1.0 
)
virtual

Adds a FairLink link at the end of fLinks. If multi is kTRUE a link is allowed more than once otherwise it is stored only once

Definition at line 119 of file FairMultiLinkedData.cxx.

void FairMultiLinkedData::AddLinks ( FairMultiLinkedData  links,
Float_t  mult = 1.0 
)
virtual

Adds a List of FairLinks (FairMultiLinkedData) to fLinks.

Definition at line 110 of file FairMultiLinkedData.cxx.

FairMultiLinkedData::ClassDef ( FairMultiLinkedData  ,
 
)
protected
virtual void FairMultiLinkedData::DeleteLink ( FairLink  link)
inlinevirtual

Deletes a link ouf of fLinks.

Definition at line 108 of file FairMultiLinkedData.h.

void FairMultiLinkedData::DeleteLink ( Int_t  type,
Int_t  index 
)
virtual

Deletes a link ouf of fLinks.

Definition at line 273 of file FairMultiLinkedData.cxx.

TObject * FairMultiLinkedData::GetData ( FairLink myLink)

Get the TObject the Link is pointing to.

Definition at line 306 of file FairMultiLinkedData.cxx.

virtual Int_t FairMultiLinkedData::GetDefaultType ( )
inlinevirtual

Definition at line 59 of file FairMultiLinkedData.h.

virtual FairLink FairMultiLinkedData::GetEntryNr ( ) const
inlinevirtual

gives back the entryNr

Definition at line 51 of file FairMultiLinkedData.h.

Bool_t FairMultiLinkedData::GetInsertHistory ( ) const
inline

Definition at line 72 of file FairMultiLinkedData.h.

FairLink FairMultiLinkedData::GetLink ( Int_t  pos) const
virtual

returns the FairLink at the given position

Definition at line 84 of file FairMultiLinkedData.cxx.

virtual std::set<FairLink> FairMultiLinkedData::GetLinks ( ) const
inlinevirtual

returns stored links as FairLinks

Definition at line 50 of file FairMultiLinkedData.h.

FairMultiLinkedData FairMultiLinkedData::GetLinksWithType ( Int_t  type) const
virtual

Gives you a list of links which contain the given type.

Definition at line 282 of file FairMultiLinkedData.cxx.

virtual Int_t FairMultiLinkedData::GetNLinks ( ) const
inlinevirtual

returns the number of stored links

Definition at line 52 of file FairMultiLinkedData.h.

Bool_t FairMultiLinkedData::GetPersistanceCheck ( )
inline

Returns the value of PersistanceCheck.

Definition at line 60 of file FairMultiLinkedData.h.

std::vector< FairLink > FairMultiLinkedData::GetSortedMCTracks ( )
virtual

Gives you a list of all FairLinks pointing to a "MCTrack" sorted by their weight.

Definition at line 295 of file FairMultiLinkedData.cxx.

Int_t FairMultiLinkedData::GetVerbose ( )
inline

Returns the verbosity level.

Definition at line 61 of file FairMultiLinkedData.h.

void FairMultiLinkedData::InsertHistory ( FairLink  link)
virtual

Adds the FairLinks of the inserted link to the set of links of this object.

Definition at line 203 of file FairMultiLinkedData.cxx.

void FairMultiLinkedData::InsertLink ( FairLink  link)
virtual

Inserts a link into the list of links without persistance checking.

Definition at line 185 of file FairMultiLinkedData.cxx.

virtual Bool_t FairMultiLinkedData::IsLinkInList ( FairLink  link)
inlinevirtual

Test if a given link is in fLinks.

Definition at line 95 of file FairMultiLinkedData.h.

Bool_t FairMultiLinkedData::IsLinkInList ( Int_t  type,
Int_t  index 
)
virtual

Same as IsLinkInList(FairLink) just with type and index given separately.

Definition at line 256 of file FairMultiLinkedData.cxx.

virtual Int_t FairMultiLinkedData::LinkPosInList ( FairLink  link)
inlinevirtual

returns position of link in fLinks. If it is not in the list -1 is returned

Definition at line 102 of file FairMultiLinkedData.h.

Int_t FairMultiLinkedData::LinkPosInList ( Int_t  type,
Int_t  index 
)
virtual

Same as LinkPosInList(FairLink)

Definition at line 264 of file FairMultiLinkedData.cxx.

void FairMultiLinkedData::MultiplyAllWeights ( Double_t  weight)
virtual

Multiplies all Links with weight.

Definition at line 348 of file FairMultiLinkedData.cxx.

std::ostream& FairMultiLinkedData::PrintLinkInfo ( std::ostream &  out = std::cout) const
inline

Output.

Definition at line 117 of file FairMultiLinkedData.h.

virtual void FairMultiLinkedData::Reset ( )
inlinevirtual

Definition at line 114 of file FairMultiLinkedData.h.

virtual void FairMultiLinkedData::ResetLinks ( )
inlinevirtual

Clears fLinks.

Definition at line 115 of file FairMultiLinkedData.h.

void FairMultiLinkedData::SetAllWeights ( Double_t  weight)
virtual

Sets a common weight for Links.

Definition at line 328 of file FairMultiLinkedData.cxx.

virtual void FairMultiLinkedData::SetDefaultType ( Int_t  type)
inlinevirtual

Definition at line 62 of file FairMultiLinkedData.h.

virtual void FairMultiLinkedData::SetEntryNr ( FairLink  entry)
inlinevirtual

Definition at line 74 of file FairMultiLinkedData.h.

virtual void FairMultiLinkedData::SetInsertHistory ( Bool_t  val)
inlinevirtual

Toggles if history of a link is inserted or not.

Definition at line 68 of file FairMultiLinkedData.h.

void FairMultiLinkedData::SetLink ( FairLink  link,
Bool_t  bypass = kFALSE,
Float_t  mult = 1.0 
)
virtual

Sets the Links with a single FairLink.

Definition at line 102 of file FairMultiLinkedData.cxx.

void FairMultiLinkedData::SetLinks ( FairMultiLinkedData  links,
Float_t  mult = 1.0 
)
virtual

Sets the links as vector of FairLink.

Parameters
typeas Int_t gives one type of source data for all indices
linksas vector<Int_t> gives the vector of indices at which position in the TClonesArray the source data is stored
typeas vector<Int_t> gives the type of source data (TClonesArray)
linksas vector<Int_t> gives the vector of indices at which position in the TClonesArray the source data is stored

Definition at line 96 of file FairMultiLinkedData.cxx.

virtual void FairMultiLinkedData::SetPersistanceCheck ( Bool_t  check)
inlinevirtual

Controls if a persistance check of a link is done or not.

Definition at line 63 of file FairMultiLinkedData.h.

virtual void FairMultiLinkedData::SetVerbose ( Int_t  level)
inlinevirtual

Sets the verbosity level.

Definition at line 67 of file FairMultiLinkedData.h.

virtual void FairMultiLinkedData::SimpleAddLinks ( Int_t  fileId,
Int_t  evtId,
Int_t  dataType,
const std::vector< Int_t > &  links,
Bool_t  ,
Float_t   
)
inlineprotectedvirtual

Definition at line 141 of file FairMultiLinkedData.h.

Friends And Related Function Documentation

std::ostream& operator<< ( std::ostream &  out,
const FairMultiLinkedData data 
)
friend

Output.

Definition at line 128 of file FairMultiLinkedData.h.

Member Data Documentation

Int_t FairMultiLinkedData::fDefaultType
protected

Definition at line 152 of file FairMultiLinkedData.h.

FairLink FairMultiLinkedData::fEntryNr
protected

Definition at line 136 of file FairMultiLinkedData.h.

Bool_t FairMultiLinkedData::fInsertHistory
protected

Definition at line 138 of file FairMultiLinkedData.h.

std::set<FairLink> FairMultiLinkedData::fLinks
protected

Definition at line 135 of file FairMultiLinkedData.h.

Bool_t FairMultiLinkedData::fPersistanceCheck
protected

Definition at line 137 of file FairMultiLinkedData.h.

Int_t FairMultiLinkedData::fVerbose
protected

Definition at line 139 of file FairMultiLinkedData.h.


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