tfel
Loading...
Searching...
No Matches
CodeGeneratorUtilities.hxx File Reference
#include <map>
#include <tuple>
#include <vector>
#include <string>
#include <string_view>
#include "MFront/MFrontConfig.hxx"
#include "TFEL/Glossary/Forward/Glossary.hxx"
#include "MFront/MaterialKnowledgeType.hxx"
#include "MFront/CodeGeneratorUtilities.ixx"

Namespaces

namespace  mfront
 This namespace contains material used to build the MFront code generator.

Functions

template<typename ValueType>
void mfront::exportSymbol (std::ostream &, const std::string_view, const std::string_view, const ValueType &)
 export a symbol using the MFRONT_EXPORT_SYMBOL macro
MFRONT_VISIBILITY_EXPORT void mfront::exportStringSymbol (std::ostream &, const std::string_view, const std::string_view)
 export string symbol using the MFRONT_EXPORT_SYMBOL macro
MFRONT_VISIBILITY_EXPORT void mfront::exportUnsignedShortSymbol (std::ostream &, const std::string_view, const unsigned short)
 export string symbol using the MFRONT_EXPORT_SYMBOL macro
MFRONT_VISIBILITY_EXPORT void mfront::writeVariablesNamesSymbol (std::ostream &, const std::string_view, const mfront::MaterialPropertyDescription &)
 write the name of the variable
MFRONT_VISIBILITY_EXPORT void mfront::writeBoundsSymbol (std::ostream &, const std::string_view, const std::string_view, const std::string_view, const mfront::VariableBoundsDescription &)
 write the bounds
MFRONT_VISIBILITY_EXPORT void mfront::writeBoundsSymbols (std::ostream &, const std::string_view, const VariableDescriptionContainer &)
 write the bounds associated with the given variables
MFRONT_VISIBILITY_EXPORT void mfront::writePhysicalBoundsSymbols (std::ostream &, const std::string_view, const VariableDescriptionContainer &)
 write the physical bounds associated with the given variables
MFRONT_VISIBILITY_EXPORT void mfront::writeVariablesBoundsSymbols (std::ostream &, const std::string_view, const mfront::MaterialPropertyDescription &)
 write the name of the variable
MFRONT_VISIBILITY_EXPORT void mfront::writeFileDescriptionSymbols (std::ostream &, const std::string_view, const FileDescription &)
 write symbols associated with the file description.
MFRONT_VISIBILITY_EXPORT void mfront::writeValidatorSymbol (std::ostream &, const std::string_view, const MaterialKnowledgeDescription &)
 write a symbol associated with the validator.
MFRONT_VISIBILITY_EXPORT void mfront::writeCompatibilityModeSymbol (std::ostream &, const std::string_view, const MaterialKnowledgeDescription &)
 write a symbol associated with the compatibility mode.
MFRONT_VISIBILITY_EXPORT void mfront::writeBuildIdentifierSymbol (std::ostream &, const std::string_view, const MaterialKnowledgeDescription &)
 write a symbol associated with the build identifier.
MFRONT_VISIBILITY_EXPORT void mfront::writeEntryPointSymbol (std::ostream &, const std::string_view)
 write a specific symbol stating that a given name entry point (C-like function for example) has been created using MFront.
MFRONT_VISIBILITY_EXPORT void mfront::writeTFELVersionSymbol (std::ostream &, const std::string_view)
 write a specific symbol giving the version of MFront used to generate the given entry point.
MFRONT_VISIBILITY_EXPORT void mfront::writeUnitSystemSymbol (std::ostream &, const std::string_view, const MaterialKnowledgeDescription &)
 write a specific symbol giving the version of MFront used to generate the given entry point.
MFRONT_VISIBILITY_EXPORT void mfront::writeEntryPointSymbol (std::ostream &, const std::string_view, const std::string_view)
 write a specific symbol stating that a given name entry point (C-like function for example) has been created using MFront.
MFRONT_VISIBILITY_EXPORT void mfront::writeInterfaceSymbol (std::ostream &, const std::string_view, const std::string_view)
 write a specific symbol for the interface of an entry point.
MFRONT_VISIBILITY_EXPORT void mfront::writeLawSymbol (std::ostream &, const std::string_view, const std::string_view)
 write a symbol stating that a given entry point is associated to a material law.
MFRONT_VISIBILITY_EXPORT void mfront::writeMaterialSymbol (std::ostream &, const std::string_view, const std::string_view)
 write a symbol stating that a given entry point is associated to a material.
MFRONT_VISIBILITY_EXPORT void mfront::writeMaterialKnowledgeTypeSymbol (std::ostream &, const std::string_view, const MaterialKnowledgeType &)
 write the symbol giving the material knowledge type.
MFRONT_VISIBILITY_EXPORT void mfront::writeMaterialLaws (std::ostream &, const std::vector< std::string > &)
MFRONT_VISIBILITY_EXPORT void mfront::writeStaticVariables (std::ostream &, const StaticVariableDescriptionContainer &, const std::string_view)
MFRONT_VISIBILITY_EXPORT void mfront::writeF77FUNCMacros (std::ostream &)
 define the F77_FUNC and F77_FUNC_ macros. We support the GNU (gfortran) and the intel compilers. By default, the GNU fortran naming scheme is used. This can be changed when compiling mfront generated sources by defining the INTEL_FORTRAN_COMPILER flag.
MFRONT_VISIBILITY_EXPORT void mfront::writeExportDirectives (std::ostream &, const bool=true)
 define the MFRONT_SHAREDOBJ macro which contains visibility attributes.
MFRONT_VISIBILITY_EXPORT void mfront::writeParametersSymbols (std::ostream &, const std::string_view, const MaterialPropertyDescription &)
 export all symbols related to parameters
MFRONT_VISIBILITY_EXPORT void mfront::writeParametersDeclarationSymbols (std::ostream &, const std::string_view, const VariableDescriptionContainer &)
 export parameters declarations
MFRONT_VISIBILITY_EXPORT void mfront::writeParametersDefaultValuesSymbols (std::ostream &, const std::string_view, const VariableDescriptionContainer &)
 export the default values of a set of parameters
MFRONT_VISIBILITY_EXPORT void mfront::exportArrayOfIntegersSymbol (std::ostream &, const std::string_view, const std::vector< int > &)
 write a symbol describing an array of integers
MFRONT_VISIBILITY_EXPORT void mfront::exportArrayOfStringsSymbol (std::ostream &, const std::string_view, const std::vector< std::string > &)
 write a symbol describing an array of strings
MFRONT_VISIBILITY_EXPORT void mfront::writeBoundsChecks (std::ostream &, const VariableDescription &, const std::string_view, const std::string_view, const std::string_view, const bool, const bool)
MFRONT_VISIBILITY_EXPORT void mfront::writeBoundsChecks (std::ostream &, const VariableDescription &, const VariableBoundsDescription &, const std::string_view, const std::string_view, const std::string_view, const bool, const bool)
MFRONT_VISIBILITY_EXPORT void mfront::writePhysicalBoundsChecks (std::ostream &, const VariableDescription &, const std::string_view, const std::string_view, const bool, const bool)
MFRONT_VISIBILITY_EXPORT void mfront::writePhysicalBoundsChecks (std::ostream &, const VariableDescription &, const VariableBoundsDescription &, const std::string_view, const std::string_view, const bool, const bool)
MFRONT_VISIBILITY_EXPORT void mfront::printLinePragma (std::ostream &, const std::size_t, std::string_view)
 print a #line pragma indicating a line number and a file name
MFRONT_VISIBILITY_EXPORT std::string mfront::printLinePragma (const std::size_t, std::string_view)
 print a #line pragma indicating a line number and a file name
MFRONT_VISIBILITY_EXPORT void mfront::writePhysicalConstantsAlias (std::ostream &, const MaterialKnowledgeDescription &, std::string_view, const bool)
 declare an alias to the PhysicalConstant class
MFRONT_VISIBILITY_EXPORT bool mfront::writeIfDifferentFromExistingFileContent (const std::string &f, const std::string &contents)
 write the contents of a generated file only if the file does not exist or if its contents differ from the given contents.

Detailed Description

Author
Thomas Helfer
Date
23/10/2008