ATLAS Offline Software
Public Member Functions | Protected Member Functions | Protected Attributes | Private Attributes | List of all members
G4UA::CosmicPerigeeActionTool Class Reference

Tool which manages the CosmicPerigeeAction action. More...

#include <CosmicPerigeeActionTool.h>

Inheritance diagram for G4UA::CosmicPerigeeActionTool:
Collaboration diagram for G4UA::CosmicPerigeeActionTool:

Public Member Functions

 CosmicPerigeeActionTool (const std::string &type, const std::string &name, const IInterface *parent)
 Standard constructor. More...
 
virtual StatusCode fillUserAction (G4AtlasUserActions &actionLists) override final
 Fill the user action lists. More...
 

Protected Member Functions

virtual std::unique_ptr< CosmicPerigeeActionmakeAndFillAction (G4AtlasUserActions &) override final
 Create action for this thread. More...
 

Protected Attributes

ThreadSpecificUserAction< CosmicPerigeeActionm_actions
 Thread-specific storage of the user action. More...
 

Private Attributes

CosmicPerigeeAction::Config m_config
 Configuration parameters. More...
 

Detailed Description

Tool which manages the CosmicPerigeeAction action.

Create the CosmicPerigeeAction for each worker thread

Author
Andrea Di Simone

Definition at line 27 of file CosmicPerigeeActionTool.h.

Constructor & Destructor Documentation

◆ CosmicPerigeeActionTool()

G4UA::CosmicPerigeeActionTool::CosmicPerigeeActionTool ( const std::string &  type,
const std::string &  name,
const IInterface *  parent 
)

Standard constructor.

Definition at line 13 of file CosmicPerigeeActionTool.cxx.

16  : UserActionToolBase<CosmicPerigeeAction>(type, name, parent)
17  {
18  declareProperty("pMinPrimary", m_config.pMinPrimary);
19  }

Member Function Documentation

◆ fillUserAction()

virtual StatusCode G4UA::UserActionToolBase< CosmicPerigeeAction >::fillUserAction ( G4AtlasUserActions actionLists)
inlinefinaloverridevirtualinherited

Fill the user action lists.

Definition at line 45 of file UserActionToolBase.h.

46  {
47  auto myAction = makeAndFillAction(actionLists);
48  if(myAction == nullptr) {
49  ATH_MSG_ERROR( "Failed to construct user action in " << name() );
50  return StatusCode::FAILURE;
51  }
52  m_actions.set( std::move(myAction) );
53  return StatusCode::SUCCESS;
54  }

◆ makeAndFillAction()

std::unique_ptr< CosmicPerigeeAction > G4UA::CosmicPerigeeActionTool::makeAndFillAction ( G4AtlasUserActions actionList)
finaloverrideprotectedvirtual

Create action for this thread.

Implements G4UA::UserActionToolBase< CosmicPerigeeAction >.

Definition at line 25 of file CosmicPerigeeActionTool.cxx.

26  {
27  ATH_MSG_DEBUG("Creating CosmicPerigeeAction");
28  auto action = std::make_unique<CosmicPerigeeAction>(m_config);
29  actionList.eventActions.push_back( action.get() );
30  actionList.trackingActions.push_back( action.get() );
31  actionList.steppingActions.push_back( action.get() );
32  return action;
33  }

Member Data Documentation

◆ m_actions

Thread-specific storage of the user action.

Definition at line 63 of file UserActionToolBase.h.

◆ m_config

CosmicPerigeeAction::Config G4UA::CosmicPerigeeActionTool::m_config
private

Configuration parameters.

Definition at line 45 of file CosmicPerigeeActionTool.h.


The documentation for this class was generated from the following files:
G4UA::ThreadSpecificUserAction::set
void set(std::unique_ptr< ActionType > action)
Assign the object of the current thread.
Definition: ThreadSpecificUserAction.h:61
ATH_MSG_ERROR
#define ATH_MSG_ERROR(x)
Definition: AthMsgStreamMacros.h:33
ATH_MSG_DEBUG
#define ATH_MSG_DEBUG(x)
Definition: AthMsgStreamMacros.h:29
G4UA::UserActionToolBase< CosmicPerigeeAction >::m_actions
ThreadSpecificUserAction< CosmicPerigeeAction > m_actions
Thread-specific storage of the user action.
Definition: UserActionToolBase.h:63
test_pyathena.parent
parent
Definition: test_pyathena.py:15
G4UA::CosmicPerigeeAction::Config::pMinPrimary
float pMinPrimary
Definition: CosmicPerigeeAction.h:30
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:221
G4UA::UserActionToolBase< CosmicPerigeeAction >::makeAndFillAction
virtual std::unique_ptr< CosmicPerigeeAction > makeAndFillAction(G4AtlasUserActions &actionLists)=0
Make the action and push onto the lists.
python.CaloScaleNoiseConfig.action
action
Definition: CaloScaleNoiseConfig.py:77
python.CaloScaleNoiseConfig.type
type
Definition: CaloScaleNoiseConfig.py:78
G4UA::CosmicPerigeeActionTool::m_config
CosmicPerigeeAction::Config m_config
Configuration parameters.
Definition: CosmicPerigeeActionTool.h:45