fesa::EventConfigurationElement Class Reference

Used to store all DEventConfiguration-specific Information which comes from the Instantiation-File. More...

#include <EventConfigurationElement.h>

List of all members.

Public Member Functions

 EventConfigurationElement (boost::shared_ptr< LogicalEventElement > parent)
virtual ~EventConfigurationElement ()
virtual void initialize (const std::string &xpath, ElementXML *eventConfigurationElement, ParserElementFactory &parserElementFactory)
 triggers the parsing of the xml-file-structures and initializes the class with all needed information
virtual void addDeviceRef (AbstractDevice *device)
virtual std::vector
< boost::shared_ptr
< EventElement > > 
getEventElementCol () const
virtual std::string getName () const
virtual AbstractDeviceClassgetClassRef () const
virtual const std::string & getLogicalEventName () const
virtual bool isNotUsed () const

Protected Member Functions

 EventConfigurationElement ()
 To allow easy mocking of this class.

Private Member Functions

std::string loadAttribute (const std::string &xpath, ElementXML *element, const std::string &attributeName)
 returns the value of an xml-attribute
void loadEventSourceElement (const std::string &xpath, ElementXML *eventConfigurationElement, ParserElementFactory &parserElementFactory)
 loads the xml-event-source-element of this event-configuration-element
void loadEventElements (const std::string &xpath, ElementXML *logicalEventElement, const std::string &eventSource, ParserElementFactory &parserElementFactory)
 loads all xml-Event-Elements of the specified event-source

Private Attributes

std::vector< boost::shared_ptr
< EventElement > > 
eventElementCol_
std::vector< AbstractDevice * > deviceCol_
boost::shared_ptr
< LogicalEventElement
parentLogicalEventElement_
 the parent-element in this linked-tree
std::string eventConfigurationName_
bool isInitialized_
 true, when initialization of this object was finished successfully

Detailed Description

Used to store all DEventConfiguration-specific Information which comes from the Instantiation-File.

Definition at line 24 of file EventConfigurationElement.h.


Constructor & Destructor Documentation

fesa::EventConfigurationElement::EventConfigurationElement ( boost::shared_ptr< LogicalEventElement parent  ) 
Parameters:
parent the parent-element in the linked-tree

Definition at line 16 of file EventConfigurationElement.cpp.

fesa::EventConfigurationElement::~EventConfigurationElement (  )  [virtual]

Definition at line 27 of file EventConfigurationElement.cpp.

fesa::EventConfigurationElement::EventConfigurationElement (  )  [protected]

To allow easy mocking of this class.

Definition at line 22 of file EventConfigurationElement.cpp.


Member Function Documentation

void fesa::EventConfigurationElement::addDeviceRef ( AbstractDevice device  )  [virtual]
Parameters:
used in order to add references of the connected devices to this object (according to the mapping in the xml-file)

Definition at line 39 of file EventConfigurationElement.cpp.

References deviceCol_, eventElementCol_, FesaErrorParserElementNotInitialized, and isInitialized_.

AbstractDeviceClass * fesa::EventConfigurationElement::getClassRef (  )  const [virtual]

Definition at line 89 of file EventConfigurationElement.cpp.

References parentLogicalEventElement_.

std::vector< boost::shared_ptr< EventElement > > fesa::EventConfigurationElement::getEventElementCol (  )  const [virtual]
const std::string & fesa::EventConfigurationElement::getLogicalEventName (  )  const [virtual]

Definition at line 94 of file EventConfigurationElement.cpp.

References parentLogicalEventElement_.

std::string fesa::EventConfigurationElement::getName (  )  const [virtual]
void fesa::EventConfigurationElement::initialize ( const std::string &  xpath,
ElementXML eventConfigurationElement,
ParserElementFactory parserElementFactory 
) [virtual]

triggers the parsing of the xml-file-structures and initializes the class with all needed information

Definition at line 32 of file EventConfigurationElement.cpp.

References fesa::EVENT_CONFIGURATION_ATTRIBUTE_TAG, eventConfigurationName_, isInitialized_, loadAttribute(), and loadEventSourceElement().

bool fesa::EventConfigurationElement::isNotUsed (  )  const [virtual]
Parameters:
True,if this event-configuration is not used by any device

Definition at line 99 of file EventConfigurationElement.cpp.

References deviceCol_, FesaErrorParserElementNotInitialized, and isInitialized_.

std::string fesa::EventConfigurationElement::loadAttribute ( const std::string &  xpath,
ElementXML element,
const std::string &  attributeName 
) [private]

returns the value of an xml-attribute

Definition at line 74 of file EventConfigurationElement.cpp.

References fesa::ElementXML::attributeList_, and FesaErrorXMLAttributeNotFound.

Referenced by initialize().

void fesa::EventConfigurationElement::loadEventElements ( const std::string &  xpath,
ElementXML logicalEventElement,
const std::string &  eventSource,
ParserElementFactory parserElementFactory 
) [private]

loads all xml-Event-Elements of the specified event-source

Definition at line 62 of file EventConfigurationElement.cpp.

References fesa::ElementXML::childList_, fesa::ParserElementFactory::createEventElement(), and eventElementCol_.

Referenced by loadEventSourceElement().

void fesa::EventConfigurationElement::loadEventSourceElement ( const std::string &  xpath,
ElementXML eventConfigurationElement,
ParserElementFactory parserElementFactory 
) [private]

loads the xml-event-source-element of this event-configuration-element

Definition at line 52 of file EventConfigurationElement.cpp.

References fesa::ElementXML::childList_, and loadEventElements().

Referenced by initialize().


Member Data Documentation

Definition at line 83 of file EventConfigurationElement.h.

Referenced by addDeviceRef(), and isNotUsed().

Definition at line 90 of file EventConfigurationElement.h.

Referenced by getName(), and initialize().

std::vector<boost::shared_ptr<EventElement> > fesa::EventConfigurationElement::eventElementCol_ [private]

Definition at line 81 of file EventConfigurationElement.h.

Referenced by addDeviceRef(), getEventElementCol(), and loadEventElements().

true, when initialization of this object was finished successfully

Definition at line 95 of file EventConfigurationElement.h.

Referenced by addDeviceRef(), getEventElementCol(), getName(), initialize(), and isNotUsed().

the parent-element in this linked-tree

Definition at line 88 of file EventConfigurationElement.h.

Referenced by getClassRef(), and getLogicalEventName().


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

Generated on 18 Jan 2013 for Fesa by  doxygen 1.6.1