tfel
Loading...
Searching...
No Matches
mfront::AbstractDSL Struct Referenceabstract

interface class for all domain specific languages. More...

#include </home/runner/work/tfel/tfel/mfront/include/MFront/AbstractDSL.hxx>

Inheritance diagram for mfront::AbstractDSL:
mfront::AbstractBehaviourDSL mfront::DSLBase mfront::BehaviourDSLCommon mfront::BehaviourDSLCommon mfront::MaterialPropertyDSL mfront::ModelDSLCommon mfront::BehaviourDSLBase< DefaultDSLBase > mfront::BehaviourDSLBase< ImplicitDSLBase > mfront::BehaviourDSLBase< IsotropicBehaviourDSLBase > mfront::BehaviourDSLBase< RungeKuttaDSLBase > mfront::BehaviourDSLBase< Child > mfront::BehaviourDSLBase< DefaultDSLBase > mfront::BehaviourDSLBase< ImplicitDSLBase > mfront::BehaviourDSLBase< IsotropicBehaviourDSLBase > mfront::BehaviourDSLBase< RungeKuttaDSLBase > mfront::BehaviourDSLBase< Child > mfront::ModelDSLBase< ModelDSL > mfront::ModelDSLBase< Child >

Classes

struct  DSLOptionDescription
 structure used to describe a DSL option More...

Public Types

enum  DSLTarget { MATERIALPROPERTYDSL , BEHAVIOURDSL , MODELDSL }
 list of dsl targets
using DSLOptions = tfel::utilities::DataMap
 a simple alias

Public Member Functions

virtual std::vector< DSLOptionDescription > getDSLOptions () const =0
virtual DSLTarget getTargetType () const =0
virtual const MaterialKnowledgeDescription & getMaterialKnowledgeDescription () const =0
virtual const FileDescription & getFileDescription () const =0
virtual std::string getMaterialKnowledgeIdentifier () const =0
virtual std::string getMaterialName () const =0
virtual std::string getOverridableVariableNameByExternalName (const std::string &) const =0
virtual std::map< std::string, double > getOverridenParameters () const =0
virtual void analyseFile (const std::string &, const std::vector< std::string > &, const std::map< std::string, std::string > &)=0
 analyse a file
virtual void analyseString (const std::string &)=0
 analyse the specified string.
virtual void importFile (const std::string &, const std::vector< std::string > &, const std::map< std::string, std::string > &)=0
 import a file
virtual void endsInputFileProcessing ()=0
 method called at the end of the input file processing.
virtual void makeConsistencyChecks () const =0
 method called after processing the input file processing.
virtual const TargetsDescription & getTargetsDescription () const =0
virtual void generateOutputFiles ()=0
 treat the specified file.
virtual void setInterfaces (const std::set< std::string > &)=0
 set list of interfaces
virtual void getKeywordsList (std::vector< std::string > &) const =0
 return the list of keywords usable with this parser
virtual ~AbstractDSL ()
 destructor

Detailed Description

interface class for all domain specific languages.

Member Function Documentation

◆ analyseFile()

virtual void mfront::AbstractDSL::analyseFile ( const std::string & ,
const std::vector< std::string > & ,
const std::map< std::string, std::string > &  )
pure virtual

analyse a file

Parameters
[in]f: file name
[in]ecmds: additionnal commands inserted treated before the input file commands (those commands are given through the --@?? option of the command line
[in]s: substitutions patterns inserted (those substitutions are given through command-line options such as --@YYY@=XXX)

Implemented in mfront::BehaviourDSLCommon, mfront::MaterialPropertyDSL, mfront::ModelDSLBase< Child >, and mfront::ModelDSLBase< ModelDSL >.

◆ analyseString()

virtual void mfront::AbstractDSL::analyseString ( const std::string & )
pure virtual

analyse the specified string.

Parameters
[in]s: analysed a string

Implemented in mfront::BehaviourDSLCommon, mfront::MaterialPropertyDSL, mfront::ModelDSLBase< Child >, and mfront::ModelDSLBase< ModelDSL >.

◆ endsInputFileProcessing()

virtual void mfront::AbstractDSL::endsInputFileProcessing ( )
pure virtual

◆ generateOutputFiles()

virtual void mfront::AbstractDSL::generateOutputFiles ( )
pure virtual

treat the specified file.

Note
This method shall be called after the analyseFile method

Implemented in mfront::BehaviourDSLCommon, mfront::MaterialPropertyDSL, and mfront::ModelDSLCommon.

◆ getDSLOptions()

virtual std::vector< DSLOptionDescription > mfront::AbstractDSL::getDSLOptions ( ) const
nodiscardpure virtual
Returns
the list of options accepted by the DSL

Implemented in mfront::BehaviourDSLCommon, and mfront::DSLBase.

◆ getFileDescription()

virtual const FileDescription & mfront::AbstractDSL::getFileDescription ( ) const
nodiscardpure virtual
Returns
the file description associated with the treated file

Implemented in mfront::DSLBase.

◆ getKeywordsList()

virtual void mfront::AbstractDSL::getKeywordsList ( std::vector< std::string > & ) const
pure virtual

return the list of keywords usable with this parser

Parameters
[out]k: the list of keywords registred for this parser

Implemented in mfront::BehaviourDSLCommon, mfront::MaterialPropertyDSL, mfront::ModelDSLBase< Child >, and mfront::ModelDSLBase< ModelDSL >.

◆ getMaterialKnowledgeDescription()

virtual const MaterialKnowledgeDescription & mfront::AbstractDSL::getMaterialKnowledgeDescription ( ) const
nodiscardpure virtual
Returns
the description of the considered material knowledge

Implemented in mfront::BehaviourDSLCommon, mfront::MaterialPropertyDSL, and mfront::ModelDSLCommon.

◆ getMaterialKnowledgeIdentifier()

virtual std::string mfront::AbstractDSL::getMaterialKnowledgeIdentifier ( ) const
nodiscardpure virtual
Returns
the identifier (material property name, behaviour name, model name) of the treated file

Implemented in mfront::BehaviourDSLCommon, mfront::MaterialPropertyDSL, and mfront::ModelDSLCommon.

◆ getMaterialName()

virtual std::string mfront::AbstractDSL::getMaterialName ( ) const
nodiscardpure virtual
Returns
the material described by the treated file

Implemented in mfront::BehaviourDSLCommon, mfront::MaterialPropertyDSL, and mfront::ModelDSLCommon.

◆ getOverridableVariableNameByExternalName()

virtual std::string mfront::AbstractDSL::getOverridableVariableNameByExternalName ( const std::string & ) const
nodiscardpure virtual
Returns
the variable name associated with the given external name
Parameters
[in]nexternal name of the quantity overridable by a parameter

Depending on the DSL's, a parameter may override a parameter, but also a material property for example.

Implemented in mfront::BehaviourDSLCommon, mfront::MaterialPropertyDSL, and mfront::ModelDSLCommon.

◆ getOverridenParameters()

virtual std::map< std::string, double > mfront::AbstractDSL::getOverridenParameters ( ) const
nodiscardpure virtual
Returns
the list of overriden parameters

Implemented in mfront::BehaviourDSLCommon, mfront::MaterialPropertyDSL, and mfront::ModelDSLCommon.

◆ getTargetsDescription()

virtual const TargetsDescription & mfront::AbstractDSL::getTargetsDescription ( ) const
nodiscardpure virtual
Returns
the target description
Note
This method shall be called after the analyseFile or analyseString methods.

Implemented in mfront::DSLBase.

◆ getTargetType()

virtual DSLTarget mfront::AbstractDSL::getTargetType ( ) const
nodiscardpure virtual
Returns
the target of the dsl

Implemented in mfront::AbstractBehaviourDSL, mfront::MaterialPropertyDSL, and mfront::ModelDSLCommon.

◆ importFile()

virtual void mfront::AbstractDSL::importFile ( const std::string & ,
const std::vector< std::string > & ,
const std::map< std::string, std::string > &  )
pure virtual

import a file

Parameters
[in]f: file name
[in]ecmds: additionnal commands inserted treated before the input file commands
[in]s: substitutions patterns inserted (those substitutions are given through command-line options such as --@YYY@=XXX)

Implemented in mfront::BehaviourDSLCommon, mfront::MaterialPropertyDSL, mfront::ModelDSLBase< Child >, and mfront::ModelDSLBase< ModelDSL >.

◆ makeConsistencyChecks()

virtual void mfront::AbstractDSL::makeConsistencyChecks ( ) const
pure virtual

method called after processing the input file processing.

Note
This method shall be called after the endsInputFileProcessing.

Implemented in mfront::BehaviourDSLCommon, mfront::ImplicitDSLBase, mfront::MaterialPropertyDSL, and mfront::ModelDSLCommon.

◆ setInterfaces()

virtual void mfront::AbstractDSL::setInterfaces ( const std::set< std::string > & )
pure virtual

set list of interfaces

Parameters
[in]inames: list of interfaces

Implemented in mfront::BehaviourDSLCommon, mfront::MaterialPropertyDSL, mfront::ModelDSL, and mfront::ModelDSLCommon.


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