Class Reference for E1039 Core & Analysis Software
PHG4Parameters Class Reference

#include </dev/shm/kenichi/update-github-e1039-doc/e1039-core/simulation/g4detectors/PHG4Parameters.h>

+ Inheritance diagram for PHG4Parameters:
+ Collaboration diagram for PHG4Parameters:

Public Types

typedef std::map< const std::string, double > dMap
 
typedef dMap::const_iterator dIter
 
typedef std::map< const std::string, int > iMap
 
typedef iMap::const_iterator iIter
 
typedef std::map< const std::string, std::string > strMap
 
typedef std::map< const std::string, std::string >::const_iterator strIter
 

Public Member Functions

 PHG4Parameters (const std::string &name)
 
 PHG4Parameters (const PHG4Parameters &params, const std::string &name)
 
virtual ~PHG4Parameters ()
 
void Print () const
 
size_t get_hash () const
 hash of binary information for checking purpose More...
 
void set_int_param (const std::string &name, const int ival)
 
int get_int_param (const std::string &name) const
 
bool exist_int_param (const std::string &name) const
 
std::pair< std::map< const std::string, int >::const_iterator, std::map< const std::string, int >::const_iterator > get_all_int_params ()
 
void set_double_param (const std::string &name, const double dval)
 
double get_double_param (const std::string &name) const
 
bool exist_double_param (const std::string &name) const
 
std::pair< std::map< const std::string, double >::const_iterator, std::map< const std::string, double >::const_iterator > get_all_double_params ()
 
void set_string_param (const std::string &name, const std::string &str)
 
std::string get_string_param (const std::string &name) const
 
bool exist_string_param (const std::string &name) const
 
std::pair< std::map< const std::string, std::string >::const_iterator, std::map< const std::string, std::string >::const_iterator > get_all_string_params ()
 
void set_name (const std::string &name)
 
std::string Name () const
 
void FillFrom (const PdbParameterMap *saveparams)
 
void FillFrom (const PdbParameterMapContainer *saveparamcontainer, const int layer)
 
void FillFrom (const PHG4Parameters *saveparams)
 
void SaveToNodeTree (PHCompositeNode *topNode, const std::string &nodename)
 
void SaveToNodeTree (PHCompositeNode *topNode, const std::string &nodename, const int layer)
 
int WriteToDB ()
 
int ReadFromDB ()
 
int ReadFromDB (const std::string &name, const int layer)
 
void CopyToPdbParameterMap (PdbParameterMap *myparm)
 
void printint () const
 
void printdouble () const
 
void printstring () const
 
- Public Member Functions inherited from PHObject
 PHObject ()
 ctor More...
 
virtual ~PHObject ()
 dtor More...
 
virtual PHObjectclone () const
 Virtual copy constructor. More...
 
virtual void identify (std::ostream &os=std::cout) const
 
virtual void Reset ()
 Clear Event. More...
 
virtual int isValid () const
 isValid returns non zero if object contains vailid data More...
 
virtual int isValid (const float) const
 
virtual int isValid (const double) const
 
virtual int isValid (const int) const
 
virtual int isValid (const unsigned int) const
 
virtual int isImplemented (const float f) const
 
virtual int isImplemented (const double f) const
 
virtual int isImplemented (const int i) const
 
virtual int isImplemented (const unsigned int i) const
 
void SplitLevel (const int i)
 
int SplitLevel () const
 
void BufferSize (const int i)
 
int BufferSize () const
 

Protected Member Functions

unsigned int ConvertStringToUint (const std::string &str) const
 

Protected Attributes

PdbParameterMappdbparam
 
std::string detname
 
dMap doubleparams
 
iMap intparams
 
strMap stringparams
 

Detailed Description

This class is deprecated, please use PHG4Parameter instead. See https://github.com/sPHENIX-Collaboration/coresoftware/pull/405

Definition at line 18 of file PHG4Parameters.h.

Member Typedef Documentation

◆ dIter

typedef dMap::const_iterator PHG4Parameters::dIter

Definition at line 23 of file PHG4Parameters.h.

◆ dMap

typedef std::map<const std::string, double> PHG4Parameters::dMap

Definition at line 22 of file PHG4Parameters.h.

◆ iIter

typedef iMap::const_iterator PHG4Parameters::iIter

Definition at line 25 of file PHG4Parameters.h.

◆ iMap

typedef std::map<const std::string, int> PHG4Parameters::iMap

Definition at line 24 of file PHG4Parameters.h.

◆ strIter

typedef std::map<const std::string, std::string>::const_iterator PHG4Parameters::strIter

Definition at line 27 of file PHG4Parameters.h.

◆ strMap

typedef std::map<const std::string, std::string> PHG4Parameters::strMap

Definition at line 26 of file PHG4Parameters.h.

Constructor & Destructor Documentation

◆ PHG4Parameters() [1/2]

PHG4Parameters::PHG4Parameters ( const std::string &  name)
inlineexplicit

Definition at line 29 of file PHG4Parameters.h.

◆ PHG4Parameters() [2/2]

PHG4Parameters::PHG4Parameters ( const PHG4Parameters params,
const std::string &  name 
)

Definition at line 47 of file PHG4Parameters.cc.

◆ ~PHG4Parameters()

virtual PHG4Parameters::~PHG4Parameters ( )
inlinevirtual

Definition at line 32 of file PHG4Parameters.h.

Member Function Documentation

◆ ConvertStringToUint()

unsigned int PHG4Parameters::ConvertStringToUint ( const std::string &  str) const
protected

Definition at line 623 of file PHG4Parameters.cc.

◆ CopyToPdbParameterMap()

void PHG4Parameters::CopyToPdbParameterMap ( PdbParameterMap myparm)

Definition at line 603 of file PHG4Parameters.cc.

References PdbParameterMap::set_double_param(), PdbParameterMap::set_int_param(), and PdbParameterMap::set_string_param().

+ Here is the call graph for this function:

◆ exist_double_param()

bool PHG4Parameters::exist_double_param ( const std::string &  name) const

Definition at line 114 of file PHG4Parameters.cc.

Referenced by PHG4ParameterContainerInterface::set_default_double_param(), and PHG4ParameterContainerInterface::set_double_param().

+ Here is the caller graph for this function:

◆ exist_int_param()

bool PHG4Parameters::exist_int_param ( const std::string &  name) const

Definition at line 73 of file PHG4Parameters.cc.

Referenced by PHG4ParameterContainerInterface::set_default_int_param(), and PHG4ParameterContainerInterface::set_int_param().

+ Here is the caller graph for this function:

◆ exist_string_param()

bool PHG4Parameters::exist_string_param ( const std::string &  name) const

Definition at line 203 of file PHG4Parameters.cc.

Referenced by PHG4ParameterContainerInterface::set_default_string_param(), and PHG4ParameterContainerInterface::set_string_param().

+ Here is the caller graph for this function:

◆ FillFrom() [1/3]

void PHG4Parameters::FillFrom ( const PdbParameterMap saveparams)

Definition at line 225 of file PHG4Parameters.cc.

References PdbParameterMap::get_cparam_iters(), PdbParameterMap::get_dparam_iters(), and PdbParameterMap::get_iparam_iters().

Referenced by PHG4ParametersContainer::CreateAndFillFrom(), and PHG4ParametersContainer::FillFrom().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ FillFrom() [2/3]

void PHG4Parameters::FillFrom ( const PdbParameterMapContainer saveparamcontainer,
const int  layer 
)

Definition at line 258 of file PHG4Parameters.cc.

References PdbParameterMap::get_cparam_iters(), PdbParameterMap::get_dparam_iters(), PdbParameterMap::get_iparam_iters(), and PdbParameterMapContainer::GetParameters().

+ Here is the call graph for this function:

◆ FillFrom() [3/3]

void PHG4Parameters::FillFrom ( const PHG4Parameters saveparams)

Definition at line 296 of file PHG4Parameters.cc.

References doubleparams, intparams, and stringparams.

◆ get_all_double_params()

std::pair< std::map<const std::string, double>::const_iterator, std::map<const std::string, double>::const_iterator> PHG4Parameters::get_all_double_params ( )
inline

Definition at line 47 of file PHG4Parameters.h.

References doubleparams.

Referenced by PHG4ParameterContainerInterface::UpdateParametersWithMacro().

+ Here is the caller graph for this function:

◆ get_all_int_params()

std::pair<std::map<const std::string, int>::const_iterator, std::map<const std::string, int>::const_iterator> PHG4Parameters::get_all_int_params ( )
inline

Definition at line 42 of file PHG4Parameters.h.

References intparams.

◆ get_all_string_params()

std::pair< std::map<const std::string, std::string>::const_iterator, std::map<const std::string, std::string>::const_iterator> PHG4Parameters::get_all_string_params ( )
inline

Definition at line 52 of file PHG4Parameters.h.

References stringparams.

◆ get_double_param()

double PHG4Parameters::get_double_param ( const std::string &  name) const

Definition at line 101 of file PHG4Parameters.cc.

References PHWHERE.

Referenced by PHG4DetectorGroupSubsystem::get_double_param(), PHG4ParameterContainerInterface::get_double_param(), PHG4ParameterInterface::get_double_param(), and PHG4ParameterContainerInterface::set_default_double_param().

+ Here is the caller graph for this function:

◆ get_hash()

size_t PHG4Parameters::get_hash ( ) const

hash of binary information for checking purpose

Definition at line 135 of file PHG4Parameters.cc.

◆ get_int_param()

int PHG4Parameters::get_int_param ( const std::string &  name) const

Definition at line 60 of file PHG4Parameters.cc.

References PHWHERE.

Referenced by PHG4DetectorGroupSubsystem::get_int_param(), PHG4ParameterContainerInterface::get_int_param(), PHG4ParameterInterface::get_int_param(), and PHG4ParameterContainerInterface::set_default_int_param().

+ Here is the caller graph for this function:

◆ get_string_param()

string PHG4Parameters::get_string_param ( const std::string &  name) const

Definition at line 190 of file PHG4Parameters.cc.

References PHWHERE.

Referenced by PHG4DetectorGroupSubsystem::get_string_param(), PHG4ParameterContainerInterface::get_string_param(), PHG4ParameterInterface::get_string_param(), and PHG4ParameterContainerInterface::set_default_string_param().

+ Here is the caller graph for this function:

◆ Name()

std::string PHG4Parameters::Name ( ) const
inline

Definition at line 55 of file PHG4Parameters.h.

References detname.

◆ Print()

void PHG4Parameters::Print ( ) const

Definition at line 125 of file PHG4Parameters.cc.

◆ printdouble()

void PHG4Parameters::printdouble ( ) const

Definition at line 172 of file PHG4Parameters.cc.

Referenced by PHG4ParameterContainerInterface::set_double_param().

+ Here is the caller graph for this function:

◆ printint()

void PHG4Parameters::printint ( ) const

Definition at line 83 of file PHG4Parameters.cc.

Referenced by PHG4ParameterContainerInterface::set_int_param().

+ Here is the caller graph for this function:

◆ printstring()

void PHG4Parameters::printstring ( ) const

Definition at line 213 of file PHG4Parameters.cc.

Referenced by PHG4ParameterContainerInterface::set_string_param().

+ Here is the caller graph for this function:

◆ ReadFromDB() [1/2]

int PHG4Parameters::ReadFromDB ( )

Definition at line 436 of file PHG4Parameters.cc.

References PdbApplication::abort(), PdbBankManager::fetchBank(), PdbBankManager::getApplication(), PdbCalBank::getEntry(), PdbBankManager::instance(), PHWHERE, and PdbApplication::startRead().

+ Here is the call graph for this function:

◆ ReadFromDB() [2/2]

int PHG4Parameters::ReadFromDB ( const std::string &  name,
const int  layer 
)

Definition at line 401 of file PHG4Parameters.cc.

References PdbApplication::abort(), PdbBankManager::fetchBank(), PdbBankManager::getApplication(), PdbCalBank::getEntry(), PdbBankManager::instance(), PHWHERE, and PdbApplication::startRead().

+ Here is the call graph for this function:

◆ SaveToNodeTree() [1/2]

void PHG4Parameters::SaveToNodeTree ( PHCompositeNode topNode,
const std::string &  nodename 
)

Definition at line 316 of file PHG4Parameters.cc.

References PHCompositeNode::addNode(), and PdbParameterMap::Reset().

Referenced by PHG4ParameterInterface::SaveToNodeTree().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ SaveToNodeTree() [2/2]

void PHG4Parameters::SaveToNodeTree ( PHCompositeNode topNode,
const std::string &  nodename,
const int  layer 
)

Definition at line 337 of file PHG4Parameters.cc.

References PHCompositeNode::addNode(), PdbParameterMapContainer::AddPdbParameterMap(), PdbParameterMapContainer::GetParametersToModify(), and PdbParameterMap::Reset().

+ Here is the call graph for this function:

◆ set_double_param()

void PHG4Parameters::set_double_param ( const std::string &  name,
const double  dval 
)

◆ set_int_param()

void PHG4Parameters::set_int_param ( const std::string &  name,
const int  ival 
)

◆ set_name()

void PHG4Parameters::set_name ( const std::string &  name)
inline

Definition at line 54 of file PHG4Parameters.h.

References detname.

Referenced by PHG4ParameterInterface::set_paramname().

+ Here is the caller graph for this function:

◆ set_string_param()

void PHG4Parameters::set_string_param ( const std::string &  name,
const std::string &  str 
)

◆ WriteToDB()

int PHG4Parameters::WriteToDB ( )

Definition at line 363 of file PHG4Parameters.cc.

References PdbApplication::abort(), PdbApplication::commit(), PdbBankManager::createBank(), PdbBankManager::getApplication(), PdbCalBank::getEntry(), PdbBankManager::instance(), PHWHERE, PdbCalBank::setLength(), and PdbApplication::startUpdate().

+ Here is the call graph for this function:

Member Data Documentation

◆ detname

std::string PHG4Parameters::detname
protected

Definition at line 79 of file PHG4Parameters.h.

Referenced by Name(), and set_name().

◆ doubleparams

dMap PHG4Parameters::doubleparams
protected

Definition at line 80 of file PHG4Parameters.h.

Referenced by FillFrom(), and get_all_double_params().

◆ intparams

iMap PHG4Parameters::intparams
protected

Definition at line 81 of file PHG4Parameters.h.

Referenced by FillFrom(), and get_all_int_params().

◆ pdbparam

PdbParameterMap* PHG4Parameters::pdbparam
protected

Definition at line 78 of file PHG4Parameters.h.

◆ stringparams

strMap PHG4Parameters::stringparams
protected

Definition at line 82 of file PHG4Parameters.h.

Referenced by FillFrom(), and get_all_string_params().


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