Arcane  4.1.12.0
User documentation
Loading...
Searching...
No Matches
Arcane::CaseFunction Class Reference

Public Member Functions

 CaseFunction (const CaseFunctionBuildInfo &info)
 Constructs a dataset function.
String name () const override
 function name
void setName (const String &new_name) override
 Sets the function name to new_name.
eParamType paramType () const override
 Function parameter type.
void setParamType (eParamType type) override
 Sets the function parameter type.
eValueType valueType () const override
 Function value type.
void setValueType (eValueType type) override
 Sets the function value type.
void setTransformValueFunction (const String &str) override
 Sets a value transformation function. For now, this is just a multiplicative coefficient. The string str must be convertible to the value type.
String transformValueFunction () const override
 Returns the value transformation function.
void setTransformParamFunction (const String &str) override
 Sets a parameter transformation function. For now, this is just a multiplicative coefficient. It is only applied to real parameters. The string str must be convertible to a real number.
String transformParamFunction () const override
 Parameter transformation function.
void setDeltatCoef (Real v) override
 Sets the value of the deltat multiplier coefficient.
Real deltatCoef () const override
 Value of the deltat multiplier coefficient.
bool checkIfValid () const override
 Checks the validity of the function.
Ref< ICaseFunctiontoReference ()
ITraceMngtraceMng () const
Public Member Functions inherited from Arcane::ICaseFunction
virtual ~ICaseFunction ()=default
 Releases resources.
virtual void value (Real param, Real &v) const =0
 Value v of the option for parameter param.
virtual void value (Real param, Integer &v) const =0
 Value v of the option for parameter param.
virtual void value (Real param, bool &v) const =0
 Value v of the option for parameter param.
virtual void value (Real param, String &v) const =0
 Value v of the option for parameter param.
virtual void value (Real param, Real3 &v) const =0
 Value v of the option for parameter param.
virtual void value (Integer param, Real &v) const =0
 Value v of the option for parameter param.
virtual void value (Integer param, Integer &v) const =0
 Value v of the option for parameter param.
virtual void value (Integer param, bool &v) const =0
virtual void value (Integer param, String &v) const =0
 Value v of the option for parameter param.
virtual void value (Integer param, Real3 &v) const =0
 Value v of the option for parameter param.
Public Member Functions inherited from Arcane::ReferenceCounterImpl
void addReference ()
void removeReference ()
void _internalAddReference ()
bool _internalRemoveReference ()

Protected Member Functions

template<typename ParamType>
void _applyParamTransform2 (ParamType &param) const
Real _applyValueComulTransform (Real v, Real comul) const
Integer _applyValueComulTransform (Integer v, Integer comul) const
String _applyValueComulTransform (const String &v, const String &comul) const
bool _applyValueComulTransform (bool v, bool comul) const
Real3 _applyValueComulTransform (Real3 v, Real3 comul) const
void _applyValueTransform (Real &value) const
void _applyValueTransform (Integer &value) const
void _applyValueTransform (String &value) const
void _applyValueTransform (Real3 &value) const
void _applyValueTransform (bool &value) const
template<typename ValueType>
void _applyValueTransform2 (ValueType &value) const
void _applyParamTransform (Real &value) const
void _applyParamTransform (Integer &value) const

Additional Inherited Members

Public Types inherited from Arcane::ICaseFunction
enum  eParamType { ParamUnknown = 0 , ParamReal = 1 , ParamInteger = 2 }
 Type of a function parameter. More...
enum  eValueType {
  ValueUnknown = 0 , ValueReal = 1 , ValueInteger = 2 , ValueBool = 3 ,
  ValueString = 4 , ValueReal3 = 5
}
 Type of a function value. More...

Detailed Description

Definition at line 80 of file CaseFunction.h.

Constructor & Destructor Documentation

◆ CaseFunction()

Arcane::CaseFunction::CaseFunction ( const CaseFunctionBuildInfo & info)
explicit

◆ ~CaseFunction()

Arcane::CaseFunction::~CaseFunction ( )
override

Definition at line 60 of file CaseFunction.cc.

Member Function Documentation

◆ _applyParamTransform() [1/2]

void Arcane::CaseFunction::_applyParamTransform ( Integer & value) const
protected

Definition at line 242 of file CaseFunction.cc.

◆ _applyParamTransform() [2/2]

void Arcane::CaseFunction::_applyParamTransform ( Real & value) const
protected

Definition at line 233 of file CaseFunction.cc.

◆ _applyParamTransform2()

template<typename ParamType>
void Arcane::CaseFunction::_applyParamTransform2 ( ParamType & param) const
protected

Definition at line 213 of file CaseFunction.cc.

◆ _applyValueComulTransform() [1/5]

bool Arcane::CaseFunction::_applyValueComulTransform ( bool v,
bool comul ) const
protected

Definition at line 156 of file CaseFunction.cc.

◆ _applyValueComulTransform() [2/5]

String Arcane::CaseFunction::_applyValueComulTransform ( const String & v,
const String & comul ) const
protected

Definition at line 149 of file CaseFunction.cc.

◆ _applyValueComulTransform() [3/5]

Integer Arcane::CaseFunction::_applyValueComulTransform ( Integer v,
Integer comul ) const
protected

Definition at line 139 of file CaseFunction.cc.

◆ _applyValueComulTransform() [4/5]

Real Arcane::CaseFunction::_applyValueComulTransform ( Real v,
Real comul ) const
protected

Definition at line 134 of file CaseFunction.cc.

◆ _applyValueComulTransform() [5/5]

Real3 Arcane::CaseFunction::_applyValueComulTransform ( Real3 v,
Real3 comul ) const
protected

Definition at line 144 of file CaseFunction.cc.

◆ _applyValueTransform() [1/5]

void Arcane::CaseFunction::_applyValueTransform ( bool & value) const
protected

Definition at line 204 of file CaseFunction.cc.

◆ _applyValueTransform() [2/5]

void Arcane::CaseFunction::_applyValueTransform ( Integer & value) const
protected

Definition at line 194 of file CaseFunction.cc.

◆ _applyValueTransform() [3/5]

void Arcane::CaseFunction::_applyValueTransform ( Real & value) const
protected

Definition at line 184 of file CaseFunction.cc.

◆ _applyValueTransform() [4/5]

void Arcane::CaseFunction::_applyValueTransform ( Real3 & value) const
protected

Definition at line 189 of file CaseFunction.cc.

◆ _applyValueTransform() [5/5]

void Arcane::CaseFunction::_applyValueTransform ( String & value) const
protected

Definition at line 199 of file CaseFunction.cc.

◆ _applyValueTransform2()

template<typename ValueType>
void Arcane::CaseFunction::_applyValueTransform2 ( ValueType & value) const
protected

Definition at line 167 of file CaseFunction.cc.

◆ checkIfValid()

bool Arcane::CaseFunction::checkIfValid ( ) const
overridevirtual

Checks the validity of the function.

Return values
trueif the function is valid,
falseotherwise.

Implements Arcane::ICaseFunction.

Reimplemented in Arcane::CaseTable.

Definition at line 125 of file CaseFunction.cc.

◆ deltatCoef()

Real Arcane::CaseFunction::deltatCoef ( ) const
inlineoverridevirtual

Value of the deltat multiplier coefficient.

Implements Arcane::ICaseFunction.

Definition at line 110 of file CaseFunction.h.

◆ name()

String Arcane::CaseFunction::name ( ) const
inlineoverridevirtual

function name

Implements Arcane::ICaseFunction.

Definition at line 94 of file CaseFunction.h.

Referenced by Arcane::CaseTable::_findValue().

◆ paramType()

eParamType Arcane::CaseFunction::paramType ( ) const
inlineoverridevirtual

Function parameter type.

Implements Arcane::ICaseFunction.

Definition at line 97 of file CaseFunction.h.

Referenced by Arcane::CaseTable::setParamType().

◆ setDeltatCoef()

void Arcane::CaseFunction::setDeltatCoef ( Real v)
inlineoverridevirtual

Sets the value of the deltat multiplier coefficient.

This coefficient, 0.0 by default, is used for functions that take physical time as a parameter. In this case, the function uses the global current time as a parameter, to which the global current time step multiplied by this coefficient is added.

Implements Arcane::ICaseFunction.

Definition at line 109 of file CaseFunction.h.

◆ setName()

void Arcane::CaseFunction::setName ( const String & new_name)
overridevirtual

Sets the function name to new_name.

Implements Arcane::ICaseFunction.

Definition at line 68 of file CaseFunction.cc.

References Arcane::String::null().

◆ setParamType()

void Arcane::CaseFunction::setParamType ( eParamType type)
overridevirtual

Sets the function parameter type.

Implements Arcane::ICaseFunction.

Reimplemented in Arcane::CaseTable.

Definition at line 82 of file CaseFunction.cc.

Referenced by Arcane::CaseTable::setParamType().

◆ setTransformParamFunction()

void Arcane::CaseFunction::setTransformParamFunction ( const String & str)
overridevirtual

Sets a parameter transformation function. For now, this is just a multiplicative coefficient. It is only applied to real parameters. The string str must be convertible to a real number.

Implements Arcane::ICaseFunction.

Definition at line 116 of file CaseFunction.cc.

◆ setTransformValueFunction()

void Arcane::CaseFunction::setTransformValueFunction ( const String & str)
overridevirtual

Sets a value transformation function. For now, this is just a multiplicative coefficient. The string str must be convertible to the value type.

Implements Arcane::ICaseFunction.

Definition at line 107 of file CaseFunction.cc.

◆ setValueType()

void Arcane::CaseFunction::setValueType ( eValueType type)
overridevirtual

Sets the function value type.

Implements Arcane::ICaseFunction.

Definition at line 93 of file CaseFunction.cc.

◆ toReference()

Ref< ICaseFunction > Arcane::CaseFunction::toReference ( )

Definition at line 251 of file CaseFunction.cc.

◆ traceMng()

ITraceMng * Arcane::CaseFunction::traceMng ( ) const
inline

Definition at line 115 of file CaseFunction.h.

◆ transformParamFunction()

String Arcane::CaseFunction::transformParamFunction ( ) const
inlineoverridevirtual

Parameter transformation function.

Implements Arcane::ICaseFunction.

Definition at line 107 of file CaseFunction.h.

◆ transformValueFunction()

String Arcane::CaseFunction::transformValueFunction ( ) const
inlineoverridevirtual

Returns the value transformation function.

Implements Arcane::ICaseFunction.

Definition at line 104 of file CaseFunction.h.

◆ valueType()

eValueType Arcane::CaseFunction::valueType ( ) const
inlineoverridevirtual

Function value type.

Implements Arcane::ICaseFunction.

Definition at line 100 of file CaseFunction.h.


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