Public Types | Public Member Functions | Static Public Member Functions | Static Private Attributes | List of all members
MarmotLibrary::MarmotMaterialFactory Class Reference

#include <Marmot.h>

Public Types

using materialFactoryFunction = MarmotMaterial *(*)(const double *materialProperties, int nMaterialProperties, int materialNumber)
 

Public Member Functions

 MarmotMaterialFactory ()=delete
 

Static Public Member Functions

static int getMaterialCodeFromName (const std::string &materialName)
 
static MarmotMaterialcreateMaterial (int materialCode, const double *materialProperties, int nMaterialProperties, int materialNumber)
 
static bool registerMaterial (int materialCode, const std::string &materialName, materialFactoryFunction factoryFunction)
 

Static Private Attributes

static std::unordered_map< std::string, int > materialNameToCodeAssociation
 
static std::unordered_map< int, materialFactoryFunctionmaterialFactoryFunctionByCode
 

Member Typedef Documentation

◆ materialFactoryFunction

using MarmotLibrary::MarmotMaterialFactory::materialFactoryFunction = MarmotMaterial* (*)( const double* materialProperties, int nMaterialProperties, int materialNumber )

Constructor & Destructor Documentation

◆ MarmotMaterialFactory()

MarmotLibrary::MarmotMaterialFactory::MarmotMaterialFactory ( )
delete

Member Function Documentation

◆ getMaterialCodeFromName()

static int MarmotLibrary::MarmotMaterialFactory::getMaterialCodeFromName ( const std::string &  materialName)
static

◆ createMaterial()

static MarmotMaterial* MarmotLibrary::MarmotMaterialFactory::createMaterial ( int  materialCode,
const double *  materialProperties,
int  nMaterialProperties,
int  materialNumber 
)
static

◆ registerMaterial()

static bool MarmotLibrary::MarmotMaterialFactory::registerMaterial ( int  materialCode,
const std::string &  materialName,
materialFactoryFunction  factoryFunction 
)
static

Member Data Documentation

◆ materialNameToCodeAssociation

std::unordered_map< std::string, int > MarmotLibrary::MarmotMaterialFactory::materialNameToCodeAssociation
staticprivate

◆ materialFactoryFunctionByCode

std::unordered_map< int, materialFactoryFunction > MarmotLibrary::MarmotMaterialFactory::materialFactoryFunctionByCode
staticprivate

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