Interface for objects that need to use functions. More...
#include <FunctionInterface.h>
Public Member Functions | |
FunctionInterface (const MooseObject *moose_object) | |
const Function & | getFunction (const std::string &name) const |
Get a function with a given name. More... | |
const Function & | getFunctionByName (const FunctionName &name) const |
Get a function with a given name. More... | |
bool | hasFunction (const std::string ¶m_name) const |
Determine if the function exists. More... | |
bool | hasFunctionByName (const FunctionName &name) const |
Determine if the function exists. More... | |
Static Public Member Functions | |
static InputParameters | validParams () |
Private Attributes | |
const InputParameters & | _fni_params |
Parameters of the object with this interface. More... | |
FEProblemBase & | _fni_feproblem |
Reference to FEProblemBase instance. More... | |
const THREAD_ID | _fni_tid |
Thread ID. More... | |
Interface for objects that need to use functions.
Inherit from this class at a very low level to make the getFunction method available.
Definition at line 35 of file FunctionInterface.h.
FunctionInterface::FunctionInterface | ( | const MooseObject * | moose_object | ) |
params | The parameters used by the object being instantiated. This class needs them so it can get the function named in the input file, but the object calling getFunction only needs to use the name on the left hand side of the statement "function = func_name" |
Definition at line 22 of file FunctionInterface.C.
const Function & FunctionInterface::getFunction | ( | const std::string & | name | ) | const |
Get a function with a given name.
name | The name of the parameter key of the function to retrieve |
Definition at line 30 of file FunctionInterface.C.
Referenced by FunctionDT::FunctionDT(), and Output::Output().
const Function & FunctionInterface::getFunctionByName | ( | const FunctionName & | name | ) | const |
Get a function with a given name.
name | The name of the function to retrieve |
Definition at line 36 of file FunctionInterface.C.
Referenced by ArrayBodyForce::ArrayBodyForce(), ArrayFunctionIC::ArrayFunctionIC(), CompositeFunction::CompositeFunction(), FunctionArrayAux::FunctionArrayAux(), FunctionScalarAux::FunctionScalarAux(), FunctionScalarIC::FunctionScalarIC(), GenericFunctionMaterialTempl< is_ad >::GenericFunctionMaterialTempl(), GenericFunctionRankTwoTensorTempl< is_ad >::GenericFunctionRankTwoTensorTempl(), GenericFunctionVectorMaterialTempl< is_ad >::GenericFunctionVectorMaterialTempl(), LinearCombinationFunction::LinearCombinationFunction(), and LineFunctionSampler::LineFunctionSampler().
bool FunctionInterface::hasFunction | ( | const std::string & | param_name | ) | const |
Determine if the function exists.
param_name | The name of the function parameter |
index | The index of the function |
Definition at line 42 of file FunctionInterface.C.
bool FunctionInterface::hasFunctionByName | ( | const FunctionName & | name | ) | const |
Determine if the function exists.
name | The name of the function |
Definition at line 48 of file FunctionInterface.C.
Referenced by hasFunction().
|
static |
Definition at line 17 of file FunctionInterface.C.
Referenced by Control::validParams(), and FVInterfaceKernel::validParams().
|
private |
Reference to FEProblemBase instance.
Definition at line 84 of file FunctionInterface.h.
Referenced by getFunction(), getFunctionByName(), and hasFunctionByName().
|
private |
Parameters of the object with this interface.
Definition at line 81 of file FunctionInterface.h.
Referenced by getFunction(), and hasFunction().
|
private |
Thread ID.
Definition at line 87 of file FunctionInterface.h.
Referenced by getFunction(), getFunctionByName(), and hasFunctionByName().