OPAL (Object Oriented Parallel Accelerator Library)  2.2.0
OPAL
Public Member Functions | Private Types | Private Member Functions | Private Attributes | List of all members
ElementFactory Class Reference

Concrete factory class for CLASSIC elements. More...

#include <ElementFactory.h>

Inheritance diagram for ElementFactory:
Inheritance graph
[legend]
Collaboration diagram for ElementFactory:
Collaboration graph
[legend]

Public Member Functions

 ElementFactory ()
 Default constructor. More...
 
virtual ~ElementFactory ()
 
virtual bool define (ElementBase *newElement)
 Define a new element. More...
 
virtual void erase (const std::string &name)
 Erase element by name. More...
 
virtual ElementBasefind (const std::string &name) const
 Find element by name. More...
 
virtual ElementBasemakeElement (const std::string &type, const std::string &name, const AttributeSet &set)
 Make new element. More...
 
virtual bool storeElement (ElementBase *newElement)
 Define a new element. More...
 
- Public Member Functions inherited from Factory
 Factory ()
 
virtual ~Factory ()
 

Private Types

typedef std::map< std::string,
ElementBase *, std::less
< std::string > > 
MapType
 

Private Member Functions

 ElementFactory (const ElementFactory &)
 
void operator= (const ElementFactory &)
 

Private Attributes

MapType inventory
 

Detailed Description

Concrete factory class for CLASSIC elements.

Definition at line 39 of file ElementFactory.h.

Member Typedef Documentation

typedef std::map<std::string, ElementBase *, std::less<std::string> > ElementFactory::MapType
private

Definition at line 85 of file ElementFactory.h.

Constructor & Destructor Documentation

ElementFactory::ElementFactory ( )

Default constructor.

Definition at line 29 of file ElementFactory.cpp.

ElementFactory::~ElementFactory ( )
virtual

Definition at line 34 of file ElementFactory.cpp.

ElementFactory::ElementFactory ( const ElementFactory )
private

Member Function Documentation

bool ElementFactory::define ( ElementBase newElement)
virtual

Define a new element.

Implements Factory.

Definition at line 38 of file ElementFactory.cpp.

References ElementBase::getName(), inventory, name, and value_type().

Here is the call graph for this function:

void ElementFactory::erase ( const std::string &  name)
virtual

Erase element by name.

Implements Factory.

Definition at line 54 of file ElementFactory.cpp.

References inventory.

ElementBase * ElementFactory::find ( const std::string &  name) const
virtual

Find element by name.

Implements Factory.

Definition at line 59 of file ElementFactory.cpp.

References inventory.

Referenced by makeElement().

ElementBase * ElementFactory::makeElement ( const std::string &  type,
const std::string &  name,
const AttributeSet set 
)
virtual

Make new element.

Implements Factory.

Definition at line 70 of file ElementFactory.cpp.

References ElementBase::clone(), find(), ElementBase::setName(), storeElement(), and ElementBase::update().

Here is the call graph for this function:

void ElementFactory::operator= ( const ElementFactory )
private
bool ElementFactory::storeElement ( ElementBase newElement)
virtual

Define a new element.

Implements Factory.

Definition at line 92 of file ElementFactory.cpp.

References ElementBase::getName(), inventory, name, and value_type().

Referenced by makeElement().

Here is the call graph for this function:

Member Data Documentation

MapType ElementFactory::inventory
private

Definition at line 86 of file ElementFactory.h.

Referenced by define(), erase(), find(), and storeElement().


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