1#ifndef included_AMP_Matrix_MatrixFactory
2#define included_AMP_Matrix_MatrixFactory
4#include "AMP/utils/FactoryStrategy.hpp"
19 return std::make_unique<MATRIX>( fid, manager );
31 return singletonInstance;
38 template<
class MATRIX>
41 FactoryStrategy<Matrix, int64_t, AMP::IO::RestartManager *>::registerFactory(
42 name, createMatrixFromRestart<MATRIX> );
Class to manage reading/writing restart data.
virtual std::string name() const =0
static MatrixFactory & getFactory()
get a singleton instance of the factory
static std::shared_ptr< Matrix > create(int64_t fid, AMP::IO::RestartManager *manager)
Create the matrix from the restart file.
static void registerMatrix(const std::string &name)
Register a matrix with the factory.
std::unique_ptr< MATRIX > createMatrixFromRestart(int64_t fid, AMP::IO::RestartManager *manager)