Simpatico  v1.10
List of all members | Public Member Functions | Protected Member Functions
McMd::SpecialFactory Class Reference

Detailed Description

Factory for specialized subclasses of SpecialPotential.

Definition at line 26 of file SpecialFactory.h.

#include <SpecialFactory.h>

Public Member Functions

 SpecialFactory ()
 Constructor. More...
 
virtual ~SpecialFactory ()
 Destructor. More...
 
void addSubfactory (SpecialFactory &subfactory)
 Add a new subfactory to the list. More...
 
virtual SpecialPotentialmdFactory (const std::string &subclass, System &system) const
 Return a pointer to a new SpecialPotential, if possible. More...
 

Protected Member Functions

SpecialPotentialtryMdSubfactories (const std::string &className, System &system) const
 Search subfactories for match to SpecialPotential subclass name. More...
 

Constructor & Destructor Documentation

McMd::SpecialFactory::SpecialFactory ( )

Constructor.

Default constructor.

Definition at line 27 of file SpecialFactory.cpp.

virtual McMd::SpecialFactory::~SpecialFactory ( )
inlinevirtual

Destructor.

Definition at line 39 of file SpecialFactory.h.

References addSubfactory(), mdFactory(), and tryMdSubfactories().

Member Function Documentation

void McMd::SpecialFactory::addSubfactory ( SpecialFactory subfactory)

Add a new subfactory to the list.

If this Factory has a param communicator, this method also sets the child subfactory communicator to that of the parent.

Parameters
subfactoryNew subfactory to be added

Definition at line 33 of file SpecialFactory.cpp.

Referenced by ~SpecialFactory().

SpecialPotential * McMd::SpecialFactory::mdFactory ( const std::string &  subclass,
System system 
) const
virtual

Return a pointer to a new SpecialPotential, if possible.

Parameters
subclassname of desired subclass of SpecialPotential
systemassociated System

Definition at line 40 of file SpecialFactory.cpp.

Referenced by ~SpecialFactory().

SpecialPotential * McMd::SpecialFactory::tryMdSubfactories ( const std::string &  className,
System system 
) const
protected

Search subfactories for match to SpecialPotential subclass name.

Parameters
classNamename of subclass
systemassociated System
Returns
base class pointer to new SpecialPotential, or a null pointer.

Definition at line 60 of file SpecialFactory.cpp.

Referenced by ~SpecialFactory().


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