PSCF v1.5.0
Pscf::Rp::TrajectoryReaderFactory< D, T > Class Template Reference

Factory for subclasses of TrajectoryReader. More...

#include <TrajectoryReaderFactory.h>

Inheritance diagram for Pscf::Rp::TrajectoryReaderFactory< D, T >:
Util::Factory< TrajectoryReader< D, T > >

Public Member Functions

TrajectoryReader< D, T > * factory (const std::string &className) const
 Create and instance of a specified subclass of TrajectoryReader.
Public Member Functions inherited from Util::Factory< TrajectoryReader< D, T > >
 Factory ()
 Constructor.
virtual ~Factory ()
 Destructor.
void addSubfactory (Factory< TrajectoryReader< D, T > > &subfactory)
 Add a new subfactory to the list.
TrajectoryReader< D, T > * readObject (std::istream &in, ParamComposite &parent, std::string &className, bool &isEnd, bool isRequired=true)
 Read a class name, instantiate an object, and read its parameters.
TrajectoryReader< D, T > * readObjectOptional (std::istream &in, ParamComposite &parent, std::string &className, bool &isEnd)
 Read an optional class name, instantiate an object, and read its parameters.
TrajectoryReader< D, T > * loadObject (Serializable::IArchive &ar, ParamComposite &parent, std::string &className)
 Load a class name, instantiate an object, and load the object.

Additional Inherited Members

Protected Member Functions inherited from Util::Factory< TrajectoryReader< D, T > >
TrajectoryReader< D, T > * trySubfactories (const std::string &className) const
 Search through subfactories for match.

Detailed Description

template<int D, class T>
class Pscf::Rp::TrajectoryReaderFactory< D, T >

Factory for subclasses of TrajectoryReader.

Definition at line 35 of file TrajectoryReaderFactory.h.

Member Function Documentation

◆ factory()

template<int D, class T>
TrajectoryReader< D, T > * Pscf::Rp::TrajectoryReaderFactory< D, T >::factory ( const std::string & className) const
virtual

Create and instance of a specified subclass of TrajectoryReader.

Parameters
classNamename of the TrajectoryReader subclass
Returns
TrajectoryReader pointer to new instance of className

Implements Util::Factory< TrajectoryReader< D, T > >.

Definition at line 32 of file TrajectoryReaderFactory.tpp.

References factory(), and Util::Factory< TrajectoryReader< D, T > >::trySubfactories().

Referenced by factory().


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