Bdb packages | Design docs | Source docs | Guidelines | Recent releases

Search | Site Map .

Main Page   Modules   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members  

/Framework/src/AppActionController.cc

Go to the documentation of this file.
00001 //--------------------------------------------------------------------------
00002 // File and Version Information:
00003 //      $Id: AppActionController.cc,v 1.5 2001/07/19 15:47:38 bartoldu Exp $
00004 //
00005 // Description:
00006 //      Class AppActionController
00007 //
00008 // Environment:
00009 //      Software developed for the BaBar Detector at the SLAC B-Factory.
00010 //
00011 // Author List:
00012 //      Marc Turcotte           Original Author  April 1998
00013 //
00014 // Copyright Information:
00015 //      Copyright (C) '98       University of Texas at Dallas
00016 //
00017 //------------------------------------------------------------------------
00018 #include "Experiment/Experiment.hh"
00019 
00020 //
00021 // This Class's Header
00022 //
00023 
00024 #include "Framework/AppActionController.hh"
00025 #include "Framework/AppAction.hh"
00026 //? #include "Framework/APPFramework.hh"
00027 
00028 //
00029 // Collaborating Class Headers
00030 //
00031 
00032 //
00033 // C Headers
00034 //
00035 
00036 #include <assert.h>
00037 
00038 //
00039 // Constructor(s)
00040 //
00041 
00042 AppActionController::AppActionController(AppAction* anAction){
00043   _theAction = anAction;
00044   _doAction  = true;
00045 }
00046 
00047 //
00048 // Destructor
00049 //
00050 
00051 AppActionController::~AppActionController(){
00052 }
00053 
00054 //
00055 // Class Interface
00056 //
00057 
00058 void AppActionController::setDoAction(bool theValue){
00059   _doAction = theValue; }
00060 
00061 bool AppActionController::doAction(){
00062   return _doAction; }
00063   
00064 AppAction* AppActionController::action(){
00065   return _theAction; }
00066 
00067 //  
00068 // Replicate/wrap the AppAction interface
00069 //
00070 
00071 void AppActionController::beforeBeginJob(APPExecutable* anExec, AbsEvent* anEvent) {
00072   if (_doAction) {
00073     _theAction->beforeBeginJob(anExec,anEvent);
00074   }
00075 }
00076 
00077 
00078 void AppActionController::afterBeginJob(APPExecutable* anExec, AbsEvent* anEvent) {
00079   if (_doAction) {
00080     _theAction->afterBeginJob(anExec,anEvent); 
00081   }
00082 }
00083 
00084 
00085 void AppActionController::beforeBeginRun(APPExecutable* anExec, AbsEvent* anEvent) {
00086   if (_doAction) {
00087     _theAction->beforeBeginRun(anExec,anEvent);
00088   }
00089 }
00090 
00091 
00092 void AppActionController::afterBeginRun(APPExecutable* anExec, AbsEvent* anEvent) {
00093   if (_doAction) {
00094     _theAction->afterBeginRun(anExec,anEvent);
00095   }  
00096 }
00097 
00098 
00099 void AppActionController::beforeEvent(APPExecutable* anExec, AbsEvent* anEvent) {
00100   if (_doAction) {
00101     _theAction->beforeEvent(anExec,anEvent);
00102   }
00103 }
00104 
00105 
00106 void AppActionController::afterEvent(APPExecutable* anExec, AbsEvent* anEvent){
00107   if(_doAction) {
00108     _theAction->afterEvent(anExec,anEvent);
00109   }
00110 }
00111  
00112 
00113 void AppActionController::beforeOther(APPExecutable* anExec, AbsEvent* anEvent) {
00114   if (_doAction) {
00115     _theAction->beforeOther(anExec,anEvent);
00116   }
00117 }
00118 
00119 
00120 void AppActionController::afterOther(APPExecutable* anExec, AbsEvent* anEvent){
00121   if(_doAction) {
00122     _theAction->afterOther(anExec,anEvent);
00123   }
00124 }
00125  
00126 
00127 void AppActionController::beforeEndRun(APPExecutable* anExec, AbsEvent* anEvent) {
00128   if (_doAction) {
00129     _theAction->beforeEndRun(anExec,anEvent);
00130   }
00131 }
00132 
00133 
00134 void AppActionController::afterEndRun(APPExecutable* anExec, AbsEvent* anEvent) {
00135   if (_doAction) {
00136     _theAction->afterEndRun(anExec,anEvent);
00137   }
00138 }
00139 
00140 
00141 void AppActionController::beforeEndJob(APPExecutable* anExec, AbsEvent* anEvent) {
00142   if (_doAction) {
00143     _theAction->beforeEndJob(anExec,anEvent);
00144   }
00145 }
00146 
00147 
00148 void AppActionController::afterEndJob(APPExecutable* anExec, AbsEvent* anEvent) {
00149   if (_doAction) {
00150     _theAction->afterEndJob(anExec,anEvent);
00151   }
00152 }

 


BaBar Public Site | SLAC | News | Links | Who's Who | Contact Us

Page Owner: Jacek Becla
Last Update: October 04, 2002