00001 // Copyright CERN 2012 - Developed in collaboration with GSI 00002 #include <fesa-core/Utilities/ParserElements/OnDemandEventElement.h> 00003 #include <fesa-core/Utilities/ParserElements/EventConfigurationElement.h> 00004 #include <fesa-core/Utilities/XMLParser.h> 00005 00006 namespace fesa 00007 { 00008 00009 OnDemandEventElement::OnDemandEventElement(boost::shared_ptr<EventConfigurationElement> parent): 00010 EventElement(parent,OnDemandSource) 00011 { 00012 00013 } 00014 00015 OnDemandEventElement::~OnDemandEventElement() 00016 { 00017 00018 } 00019 00020 void OnDemandEventElement::initialize(const std::string& xpath,ElementXML* eventElement) 00021 { 00022 std::vector<AttributeXML*>::iterator iter; 00023 for(iter=eventElement->attributeList_.begin();iter!=eventElement->attributeList_.end();++iter) 00024 { 00025 if((*iter)->name_ == "name") 00026 { 00027 eventSourceName_ = (*iter)->value_; 00028 concreteEventName_ = (*iter)->value_; 00029 } 00030 } 00031 00032 isInitialized_ = true; 00033 } 00034 00035 const std::string& OnDemandEventElement::getSourceTypeSpecificData(const std::string& dataTag) 00036 { 00037 //No dataTags for OD-Events 00038 throw FesaException(__FILE__, __LINE__, FesaErrorUnkonwDataToken.c_str(),dataTag.c_str(),getLogicalName().c_str()); 00039 } 00040 00041 00042 }