CMS 3D CMS Logo

List of all members | Public Member Functions | Private Attributes
edm::ProcessContext Class Reference

#include <ProcessContext.h>

Public Member Functions

bool isSubProcess () const
 
ParameterSetID const & parameterSetID () const
 
ProcessContext const & parentProcessContext () const
 
ProcessConfiguration const * processConfiguration () const
 
 ProcessContext ()
 
std::string const & processName () const
 
void setParentProcessContext (ProcessContext const *parentProcessContext)
 
void setProcessConfiguration (ProcessConfiguration const *processConfiguration)
 

Private Attributes

ProcessContext const * parentProcessContext_
 
ProcessConfiguration const * processConfiguration_
 

Detailed Description

Description: Holds pointer to ProcessConfiguration and if this is a SubProcess also a pointer to the parent ProcessContext. This is intended primarily to be passed to Services as an argument to their callback functions.

Usage:

Definition at line 27 of file ProcessContext.h.

Constructor & Destructor Documentation

◆ ProcessContext()

edm::ProcessContext::ProcessContext ( )

Definition at line 8 of file ProcessContext.cc.

8 : processConfiguration_(nullptr), parentProcessContext_(nullptr) {}
ProcessConfiguration const * processConfiguration_
ProcessContext const * parentProcessContext_

Member Function Documentation

◆ isSubProcess()

bool edm::ProcessContext::isSubProcess ( ) const
inline

◆ parameterSetID()

ParameterSetID const& edm::ProcessContext::parameterSetID ( ) const
inline

◆ parentProcessContext()

ProcessContext const & edm::ProcessContext::parentProcessContext ( ) const

Definition at line 10 of file ProcessContext.cc.

References Exception, isSubProcess(), edm::errors::LogicError, and parentProcessContext_.

Referenced by edm::operator<<(), and setParentProcessContext().

10  {
11  if (!isSubProcess()) {
13  << "ProcessContext::parentProcessContext This function should only be called for SubProcesses.\n"
14  << "If necessary, you can check this by calling isSubProcess first.\n";
15  }
16  return *parentProcessContext_;
17  }
bool isSubProcess() const
ProcessContext const * parentProcessContext_

◆ processConfiguration()

ProcessConfiguration const* edm::ProcessContext::processConfiguration ( ) const
inline

Definition at line 33 of file ProcessContext.h.

References processConfiguration_.

Referenced by edm::operator<<(), and setProcessConfiguration().

33 { return processConfiguration_; }
ProcessConfiguration const * processConfiguration_

◆ processName()

std::string const& edm::ProcessContext::processName ( ) const
inline

Definition at line 31 of file ProcessContext.h.

References processConfiguration_, and edm::ProcessConfiguration::processName().

Referenced by edm::service::Tracer::preBeginJob().

ProcessConfiguration const * processConfiguration_
std::string const & processName() const

◆ setParentProcessContext()

void edm::ProcessContext::setParentProcessContext ( ProcessContext const *  parentProcessContext)

Definition at line 23 of file ProcessContext.cc.

References parentProcessContext(), and parentProcessContext_.

Referenced by edm::SubProcess::SubProcess().

23  {
25  }
ProcessContext const & parentProcessContext() const
ProcessContext const * parentProcessContext_

◆ setProcessConfiguration()

void edm::ProcessContext::setProcessConfiguration ( ProcessConfiguration const *  processConfiguration)

Definition at line 19 of file ProcessContext.cc.

References processConfiguration(), and processConfiguration_.

Referenced by edm::EventProcessor::init(), edm::SubProcess::SubProcess(), and edm::test::TestProcessor::TestProcessor().

19  {
21  }
ProcessConfiguration const * processConfiguration() const
ProcessConfiguration const * processConfiguration_

Member Data Documentation

◆ parentProcessContext_

ProcessContext const* edm::ProcessContext::parentProcessContext_
private

Definition at line 45 of file ProcessContext.h.

Referenced by isSubProcess(), parentProcessContext(), and setParentProcessContext().

◆ processConfiguration_

ProcessConfiguration const* edm::ProcessContext::processConfiguration_
private