BOSS 8.0.0
BESIII Offline Software System
Loading...
Searching...
No Matches
InjSigIntervalSvc Class Reference

#include <InjSigIntervalSvc.h>

Inheritance diagram for InjSigIntervalSvc:

Public Member Functions

 InjSigIntervalSvc (const std::string &name, ISvcLocator *svcloc)
 ~InjSigIntervalSvc ()
virtual StatusCode initialize ()
virtual StatusCode finalize ()
void handle (const Incident &)
int getTInterval () const

Detailed Description

Definition at line 15 of file InjSigIntervalSvc.h.

Constructor & Destructor Documentation

◆ InjSigIntervalSvc()

InjSigIntervalSvc::InjSigIntervalSvc ( const std::string & name,
ISvcLocator * svcloc )

Definition at line 25 of file InjSigIntervalSvc.cxx.

26 : base_class( name, svcloc ) {}

Referenced by InjSigIntervalSvc().

◆ ~InjSigIntervalSvc()

InjSigIntervalSvc::~InjSigIntervalSvc ( )

Definition at line 28 of file InjSigIntervalSvc.cxx.

28{}

Member Function Documentation

◆ finalize()

StatusCode InjSigIntervalSvc::finalize ( )
virtual

Definition at line 59 of file InjSigIntervalSvc.cxx.

59 {
60 MsgStream log( msgSvc(), name() );
61 log << MSG::INFO << "InjSigIntervalSvc::finalize()" << endmsg;
62
63 return StatusCode::SUCCESS;
64}
IMessageSvc * msgSvc()

◆ getTInterval()

int InjSigIntervalSvc::getTInterval ( ) const
inline

Definition at line 29 of file InjSigIntervalSvc.h.

29{ return m_tInterval; }

◆ handle()

void InjSigIntervalSvc::handle ( const Incident & inc)

Definition at line 66 of file InjSigIntervalSvc.cxx.

66 {
67 MsgStream log( msgSvc(), name() );
68 log << MSG::DEBUG << "handle: " << inc.type() << endmsg;
69
70 if ( inc.type() == "NewRun" )
71 {
72 log << MSG::DEBUG << "NewRun" << endmsg;
73
74 if ( !initCalibConst() )
75 { log << MSG::ERROR << "can not initilize InjSigInterval Constants" << endmsg; }
76 }
77}

◆ initialize()

StatusCode InjSigIntervalSvc::initialize ( )
virtual

Definition at line 39 of file InjSigIntervalSvc.cxx.

39 {
40 MsgStream log( msgSvc(), name() );
41 log << MSG::INFO << "InjSigIntervalSvc::initialize()" << endmsg;
42
43 StatusCode sc = Service::initialize();
44 if ( sc.isFailure() ) return sc;
45
46 IIncidentSvc* incsvc;
47 sc = service( "IncidentSvc", incsvc );
48 int priority = 100;
49 if ( sc.isSuccess() ) { incsvc->addListener( this, "NewRun", priority ); }
50
51 sc = service( "CalibDataSvc", m_pCalDataSvc, true );
52 if ( sc == StatusCode::SUCCESS )
53 { log << MSG::INFO << "Retrieve IDataProviderSvc" << endmsg; }
54 else { log << MSG::FATAL << "can not get IDataProviderSvc" << endmsg; }
55
56 return StatusCode::SUCCESS;
57}

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