20 #ifndef MODEL_ATTRIBUTEINTEGER_H_
21 #define MODEL_ATTRIBUTEINTEGER_H_
24 #include <ModelAPI_AttributeInteger.h>
26 #include <TDF_Label.hxx>
39 MODEL_EXPORT
virtual void setValue(
const int theValue);
42 MODEL_EXPORT
virtual int value();
48 MODEL_EXPORT
virtual void setText(
const std::wstring& theText);
51 MODEL_EXPORT
virtual std::wstring
text();
66 MODEL_EXPORT
virtual void setUsedParameters(
const std::set<std::wstring>& theUsedParameters);
69 MODEL_EXPORT
virtual std::set<std::wstring>
usedParameters()
const;
80 std::shared_ptr<ModelAPI_ExpressionInteger> myExpression;
API for the attribute that contains integer (int).
Definition: ModelAPI_AttributeInteger.h:34
Expression for calculated integer values.
Definition: ModelAPI_Expression.h:122
Attribute that contains integer.
Definition: Model_AttributeInteger.h:36
virtual MODEL_EXPORT std::set< std::wstring > usedParameters() const
Returns the used parameters.
Definition: Model_AttributeInteger.cpp:99
virtual MODEL_EXPORT void setExpressionError(const std::string &theError)
Allows to set expression (text) error (by the parameters listener)
Definition: Model_AttributeInteger.cpp:83
virtual MODEL_EXPORT void setValue(const int theValue)
Defines the integer value.
Definition: Model_AttributeInteger.cpp:48
virtual MODEL_EXPORT int value()
Returns the integer value.
Definition: Model_AttributeInteger.cpp:53
virtual MODEL_EXPORT void setCalculatedValue(const int theValue)
Defines the calculated value.
Definition: Model_AttributeInteger.cpp:40
virtual MODEL_EXPORT void setUsedParameters(const std::set< std::wstring > &theUsedParameters)
Defines the used parameters.
Definition: Model_AttributeInteger.cpp:94
virtual MODEL_EXPORT bool expressionInvalid()
Returns true if text is invalid.
Definition: Model_AttributeInteger.cpp:78
virtual MODEL_EXPORT std::wstring text()
Returns the text value.
Definition: Model_AttributeInteger.cpp:68
Model_AttributeInteger(TDF_Label &theLabel)
Initializes attributes.
Definition: Model_AttributeInteger.cpp:27
virtual MODEL_EXPORT void setExpressionInvalid(const bool theFlag)
Allows to set expression (text) as invalid (by the parameters listener)
Definition: Model_AttributeInteger.cpp:73
virtual MODEL_EXPORT void setText(const std::wstring &theText)
Defines the text value.
Definition: Model_AttributeInteger.cpp:58
virtual void reinit()
Reinitializes the internal state of the attribute (may be needed on undo/redo, abort,...
Definition: Model_AttributeInteger.cpp:34
virtual MODEL_EXPORT std::string expressionError()
Returns an expression error.
Definition: Model_AttributeInteger.cpp:89
General object of the application that allows to get/set attributes from the document and compute res...
Definition: Model_Data.h:62