JANA2
C++ framework for multi-threaded data processing
|
Public Member Functions | |
void | acquire_services (JServiceLocator *sl) |
void | AddCalibrationGenerator (JCalibrationGenerator *generator) |
void | RemoveCalibrationGenerator (JCalibrationGenerator *generator) |
vector< JCalibrationGenerator * > | GetCalibrationGenerators () |
void | GetJCalibrations (vector< JCalibration * > &calibs) |
JCalibration * | GetJCalibration (unsigned int run_number) |
template<class T > | |
bool | GetCalib (unsigned int run_number, unsigned int event_number, string namepath, map< string, T > &vals) |
template<class T > | |
bool | GetCalib (unsigned int run_number, unsigned int event_number, string namepath, vector< T > &vals) |
JLargeCalibration * | GetLargeCalibration (unsigned int run_number=0) |
Public Member Functions inherited from JService | |
virtual | ~JService ()=default |
acquire_services is a callback which allows the user to configure a JService which relies on other JServices. More... | |
void | DoInit (JServiceLocator *) |
virtual void | Init () |
Public Member Functions inherited from jana::components::JComponent | |
void | SetLevel (JEventLevel level) |
void | SetCallbackStyle (CallbackStyle style) |
void | SetPrefix (std::string prefix) |
void | SetTypeName (std::string type_name) |
For convenience, we provide a NAME_OF_THIS macro so that the user doesn't have to store the type name as a string, because that could get out of sync if automatic refactoring tools are used. | |
JApplication * | GetApplication () const |
JLogger & | GetLogger () |
std::string | GetPrefix () const |
JEventLevel | GetLevel () const |
std::string | GetLoggerName () const |
std::string | GetPluginName () const |
void | SetLoggerName (std::string logger_name) |
void | SetPluginName (std::string plugin_name) |
std::string | GetTypeName () const |
virtual void | Summarize (JComponentSummary &) const |
CallbackStyle | GetCallbackStyle () const |
Status | GetStatus () const |
void | SetApplication (JApplication *app) |
void | SetLogger (JLogger logger) |
template<typename F > | |
void | CallWithJExceptionWrapper (std::string func_name, F func) |
void | RegisterParameter (ParameterBase *parameter) |
void | RegisterService (ServiceBase *service) |
void | ConfigureAllParameters (std::map< std::string, std::string > fields) |
Additional Inherited Members | |
Public Types inherited from jana::components::JComponent | |
enum class | Status { Uninitialized , Initialized , Opened , Closed , Finalized } |
enum class | CallbackStyle { LegacyMode , ExpertMode , DeclarativeMode } |
Protected Attributes inherited from jana::components::JComponent | |
std::vector< ParameterBase * > | m_parameters |
std::vector< ServiceBase * > | m_services |
JEventLevel | m_level = JEventLevel::PhysicsEvent |
CallbackStyle | m_callback_style = CallbackStyle::LegacyMode |
std::string | m_prefix |
std::string | m_plugin_name |
std::string | m_logger_name |
std::string | m_type_name |
Status | m_status = Status::Uninitialized |
std::mutex | m_mutex |
JApplication * | m_app = nullptr |
JLogger | m_logger |
|
inline |
Get the JCalibration object from JApplication for the run number of the current event and call its Get() method to get the constants.
References JCalibration::Get(), and GetJCalibration().
|
inline |
Get the JCalibration object from JApplication for the run number of the current event and call its Get() method to get the constants.
References JCalibration::Get(), and GetJCalibration().
|
inline |
Return a pointer to the JCalibration object that is valid for the given run number.
This first searches through the list of existing JCalibration objects (created by JCalibrationManager) to see if it already has the right one. If so, a pointer to it is returned. If not, a new JCalibration object is created and added to the internal list. Note that since we need to make sure the list is not modified by one thread while being searched by another, a mutex is locked while searching the list. It is NOT efficient to get or even use the JCalibration object every event. Factories should access it in their brun() callback and keep a local copy of the required constants for use in the evnt() callback.
References JCalibrationGenerator::CheckOpenable(), JCalibrationGenerator::Description(), and JCalibrationGenerator::MakeJCalibration().
Referenced by GetCalib(), and GetLargeCalibration().
|
inline |
Return a pointer to the JLargeCalibration object for the specified run_number. If no run_number is given or a value of 0 is given, then the first element from the list of resource managers is returned. If no managers currently exist, one will be created using one of the following in order of precedence:
The JCalibration is used to hold the URLs of resources so when a namepath is specified, the location of the resource on the web can be obtained and the file downloaded if necessary. See documentation in the JResourceManager class for more details.
References GetJCalibration().