Multi-enumeration data set option. More...
#include <arcane/core/CaseOptionEnum.h>
Public Member Functions | |
| CaseOptionMultiEnum (const CaseOptionBuildInfo &cob, const String &type_name) | |
| virtual void | print (const String &lang, std::ostream &o) const |
| Prints the option value in the language lang, to the stream o. | |
| virtual ICaseFunction * | function () const |
| Returns the function linked to this option or nullptr if none exists. | |
| virtual void | updateFromFunction (Real, Integer) |
| Updates the option value from a function. | |
| void | addEnumValue (CaseOptionEnumValue *value, bool do_clone) |
| CaseOptionEnumValues * | enumValues () const |
| virtual void | visit (ICaseDocumentVisitor *visitor) const |
| Applies the visitor to this option. | |
| Public Member Functions inherited from Arcane::CaseOptionBase | |
| String | trueName () const |
| Returns the true name (untranslated) of the option. | |
| String | name () const |
| Returns the option name corresponding to the data set language. | |
| String | translatedName (const String &lang) const |
| Name of the option in the language lang. Returns name() if no translation exists. | |
| void | search (bool is_phase1) |
| Retrieves the value from the configuration file for the variable. | |
| ICaseMng * | caseMng () const |
| Case manager. | |
| ICaseOptionList * | parentOptionList () const |
| Parent OptionList. | |
| ITraceMng * | traceMng () const |
| Trace manager. | |
| ISubDomain * | subDomain () const |
| Sub-domain manager. | |
| ICaseDocument * | caseDocument () const |
| Returns the document manager. | |
| ICaseDocumentFragment * | caseDocumentFragment () const |
| Returns the document associated with this option. | |
| void | setRootElement (const XmlNode &root_element) |
| Positions the root element at root_element. | |
| XmlNode | rootElement () const |
| Returns the root element of the DOM. | |
| Integer | minOccurs () const |
| Minimum number of occurrences (for a multiple option). | |
| Integer | maxOccurs () const |
| Maximum number of occurrences (for a multiple option) (-1 == unbounded). | |
| bool | isOptional () const |
| Allows knowing if an option is optional. | |
| void | addAlternativeNodeName (const String &lang, const String &name) |
| Adds a translation for the option name. | |
| void | addDefaultValue (const String &category, const String &value) |
| Adds the default value value to the category category. | |
| void | checkIsInitialized () const |
| Throws an exception if the option has not been initialized. | |
Protected Member Functions | |
| virtual void | _search (bool is_phase1) |
| virtual bool | _allowPhysicalUnit () |
| virtual void | _allocate (Integer size)=0 |
| Allocates an array for size elements. | |
| virtual Integer | _nbElem () const =0 |
| Returns the number of elements in the array. | |
| virtual void | _setOptionValue (Integer index, int v)=0 |
| virtual int | _optionValue (Integer index) const =0 |
| Returns the enumeration value for index index. | |
| Protected Member Functions inherited from Arcane::CaseOptionBase | |
| CaseOptionBase (const CaseOptionBuildInfo &cob) | |
| String | _defaultValue () const |
| Returns the default value of the option or 0 if none exists. | |
| void | _setDefaultValue (const String &def_value) |
| void | _setIsInitialized () |
| bool | _isInitialized () const |
| void | _checkIsInitialized () const |
| void | _checkMinMaxOccurs (Integer nb_occur) |
| String | _xpathFullName () const |
Multi-enumeration data set option.
Definition at line 287 of file CaseOptionEnum.h.
| Arcane::CaseOptionMultiEnum::CaseOptionMultiEnum | ( | const CaseOptionBuildInfo & | cob, |
| const String & | type_name ) |
Definition at line 356 of file CaseOptionEnum.cc.
| Arcane::CaseOptionMultiEnum::~CaseOptionMultiEnum | ( | ) |
Definition at line 367 of file CaseOptionEnum.cc.
|
protectedpure virtual |
Allocates an array for size elements.
Implemented in Arcane::CaseOptionMultiEnumT< T >.
|
inlineprotectedvirtual |
Definition at line 314 of file CaseOptionEnum.h.
|
protectedpure virtual |
Returns the number of elements in the array.
Implemented in Arcane::CaseOptionMultiEnumT< T >.
Referenced by print().
|
protectedpure virtual |
Returns the enumeration value for index index.
Implemented in Arcane::CaseOptionMultiEnumT< T >.
Referenced by print().
|
protectedvirtual |
Implements Arcane::CaseOptionBase.
Definition at line 376 of file CaseOptionEnum.cc.
|
protectedpure virtual |
Sets the option value to the value v. v is directly converted to the enumeration value.
Implemented in Arcane::CaseOptionMultiEnumT< T >.
|
inline |
Definition at line 302 of file CaseOptionEnum.h.
|
inline |
Definition at line 307 of file CaseOptionEnum.h.
|
inlinevirtual |
Returns the function linked to this option or nullptr if none exists.
Implements Arcane::CaseOptionBase.
Definition at line 299 of file CaseOptionEnum.h.
|
virtual |
Prints the option value in the language lang, to the stream o.
Implements Arcane::CaseOptionBase.
Definition at line 422 of file CaseOptionEnum.cc.
References _nbElem(), and _optionValue().
|
inlinevirtual |
Updates the option value from a function.
If the option is not linked to a workflow table, it does nothing. Otherwise, it uses current_time or current_iteration depending on the function parameter type to calculate the new option value. This value will then be normally accessible via the operator() method.
Implements Arcane::CaseOptionBase.
Definition at line 300 of file CaseOptionEnum.h.
|
virtual |
Applies the visitor to this option.
Implements Arcane::CaseOptionBase.
Definition at line 434 of file CaseOptionEnum.cc.