| Classes | Job Modules | Data Objects | Services | Algorithms | Tools | Packages | Directories | Tracs |

In This Package:

DetElemContainsRuleFactory< Q > Struct Template Reference

Custom rules to do things with interesting geometry tests. More...

#include <HistorianCustomRules.h>

Inheritance diagram for DetElemContainsRuleFactory< Q >:

[legend]
Collaboration diagram for DetElemContainsRuleFactory< Q >:
[legend]
List of all members.

Public Member Functions

 DetElemContainsRuleFactory (Q *caller)
RuleParser::RulecreateRule (const RuleParser::ParameterDescription &paramter, int operation, const std::string &value, bool param_on_left)
virtual Rule * createRule (const ParameterDescription &parameter, int operation, int value, bool param_on_left)
virtual Rule * createRule (const ParameterDescription &paramter, int operation, double value, bool param_on_left)

Public Attributes

Q * mCaller

Detailed Description

template<class Q>
struct DetElemContainsRuleFactory< Q >

Custom rules to do things with interesting geometry tests.

Definition at line 15 of file HistorianCustomRules.h.


Constructor & Destructor Documentation

template<class Q>
DetElemContainsRuleFactory< Q >::DetElemContainsRuleFactory ( Q *  caller  )  [inline]

Definition at line 17 of file HistorianCustomRules.h.

00017 : mCaller(caller) {};


Member Function Documentation

template<class Q>
RuleParser::Rule * DetElemContainsRuleFactory< Q >::createRule ( const RuleParser::ParameterDescription paramter,
int  operation,
const std::string &  value,
bool  param_on_left 
) [virtual]

Reimplemented from RuleParser::RuleFactory.

Definition at line 75 of file HistorianCustomRules.h.

00081 {
00086   
00087   // Go find the data object we want to compare to.
00088   DataObject* d;
00089   mCaller->detSvc()->retrieveObject(value,d);
00090   const IDetectorElement* valueDetElem 
00091     = dynamic_cast<const IDetectorElement*>(d);
00092   
00093   if(!valueDetElem){
00094     mCaller->err() << "DetElemContainsRuleFactory: Can't build DetElemContainsRule because given value (" 
00095       << value << ") doesn't correspond to a known IDetectorElement object." << endreq;
00096     assert(0);
00097   }
00098   
00099   std::string name = parameter.name() + " " + parameter.operators()[operation] + " " + valueDetElem->name();
00100   return new DetElemContainsRule<Q>(name,valueDetElem);
00101 }


Member Data Documentation

template<class Q>
Q* DetElemContainsRuleFactory< Q >::mCaller

Definition at line 24 of file HistorianCustomRules.h.


The documentation for this struct was generated from the following file:
| Classes | Job Modules | Data Objects | Services | Algorithms | Tools | Packages | Directories | Tracs |

Generated on Mon Apr 11 20:54:54 2011 for Historian by doxygen 1.4.7