SHAPER
9.12.0
|
API for the attribute that contains tables of some values type. More...
Public Types | |
enum | ValueType { BOOLEAN , INTEGER , DOUBLE , STRING } |
Type of the value in the table. More... | |
Public Member Functions | |
virtual int | rows () |
Returns the number of rows in the table. More... | |
virtual int | columns () |
Returns the number of columns in the table. More... | |
virtual int | tables () |
Returns the number of tables. More... | |
virtual void | setSize (const int theRows, const int theColumns, const int theTables=1) |
Sets the new size of the tables set. More... | |
virtual void | setType (ValueType theType) |
Defines the tyoe of values in the table. If it differs from the current, erases the content. More... | |
virtual const ValueType & | type () const |
Defines the tyoe of values in the table. If it differs from the current, erases the content. More... | |
virtual void | setValue (const Value theValue, const int theRow, const int theColumn, const int theTable=0) |
Defines the value by the index in the tables set (indexes are zero-based). More... | |
virtual Value | value (const int theRow, const int theColumn, const int theTable=0) |
Returns the value by the index (indexes are zero-based). More... | |
virtual std::string | valueStr (const int theRow, const int theColumn, const int theTable=0) |
Returns the value in the format of string (usefull for the python connection) More... | |
virtual MODELAPI_EXPORT std::string | attributeType () |
Returns the type of this class of attributes, not static method. More... | |
virtual void | setObject (const std::shared_ptr< ModelAPI_Object > &theObject) |
Sets the owner of this attribute. More... | |
const std::shared_ptr< ModelAPI_Object > & | owner () const |
Returns the owner of this attribute. More... | |
virtual bool | isInitialized () |
Returns true if attribute was initialized by some value. More... | |
void | setInitialized () |
Makes attribute initialized. More... | |
bool | blockSetInitialized (const bool theBlock) |
Blocks sending "attribute updated" if theBlock is true. More... | |
void | setIsArgument (const bool theFlag) |
Set this attribute is argument for result (change of this attribute requires update of result). More... | |
bool | isArgument () |
Returns true if attribute causes the result change. More... | |
bool | setImmutable (const bool theFlag) |
Immutable argument can not be changed programmatically (e.g. More... | |
bool | isImmutable () |
Returns true if can not be changed programmatically. More... | |
const std::string & | id () const |
ID of the attribute in Data. More... | |
virtual void | reset () |
Resets attribute to deafult state. More... | |
Static Public Member Functions | |
static MODELAPI_EXPORT std::string | typeId () |
Returns the type of this class of attributes. More... | |
Protected Member Functions | |
Model_AttributeTables (TDF_Label &theLabel) | |
Objects are created for features automatically. More... | |
virtual void | reinit () |
Reinitializes the internal state of the attribute (may be needed on undo/redo, abort, etc) More... | |
virtual void | setID (const std::string theID) |
Sets the ID of the attribute in Data (called from Data) More... | |
Protected Attributes | |
bool | myIsInitialized |
is some value assigned to this attribute More... | |
bool | mySetInitializedBlocked |
is initialized blocked More... | |
bool | myIsArgument |
is this attribute used as an argument for execution More... | |
bool | myIsImmutable |
is this attribute can be changed programmatically (e.g. by constraint) More... | |
Friends | |
class | Model_Data |
API for the attribute that contains tables of some values type.
The type of values can be changed. But all the values in the tables must have the same one type. The currently allowed types now are: Boolean, Integer, Double, String. By default there is only one table, but it may be increased/decreased by adding/removing tables one by one. The number of rows and columns are equal in all tables. If table, row or column is added, the previous values are kept unchanged. New cells are filled by zero, false or empty strings.
|
inherited |
Type of the value in the table.
|
protected |
Objects are created for features automatically.
|
virtual |
Returns the number of rows in the table.
Implements ModelAPI_AttributeTables.
|
virtual |
Returns the number of columns in the table.
Implements ModelAPI_AttributeTables.
|
virtual |
Returns the number of tables.
Implements ModelAPI_AttributeTables.
|
virtual |
Sets the new size of the tables set.
This method tries to keep old values if number of rows, columns or tables is increased.
Implements ModelAPI_AttributeTables.
|
virtual |
Defines the tyoe of values in the table. If it differs from the current, erases the content.
Implements ModelAPI_AttributeTables.
|
virtual |
Defines the tyoe of values in the table. If it differs from the current, erases the content.
Implements ModelAPI_AttributeTables.
|
virtual |
Defines the value by the index in the tables set (indexes are zero-based).
Implements ModelAPI_AttributeTables.
|
virtual |
Returns the value by the index (indexes are zero-based).
Implements ModelAPI_AttributeTables.
|
virtual |
Returns the value in the format of string (usefull for the python connection)
Implements ModelAPI_AttributeTables.
|
protectedvirtual |
Reinitializes the internal state of the attribute (may be needed on undo/redo, abort, etc)
Reimplemented from ModelAPI_Attribute.
|
inlinestaticinherited |
Returns the type of this class of attributes.
|
virtualinherited |
Returns the type of this class of attributes, not static method.
Implements ModelAPI_Attribute.
|
virtualinherited |
Sets the owner of this attribute.
Reimplemented in Model_AttributeSelection, and Model_AttributeReference.
|
inherited |
Returns the owner of this attribute.
|
virtualinherited |
Returns true if attribute was initialized by some value.
Reimplemented in Model_AttributeSelectionList, Model_AttributeSelection, Model_AttributeRefList, Model_AttributeReference, Model_AttributeRefAttrList, Model_AttributeRefAttr, and GeomData_Dir.
|
inherited |
Makes attribute initialized.
|
inherited |
Blocks sending "attribute updated" if theBlock is true.
theBlock | a block value |
|
inherited |
Set this attribute is argument for result (change of this attribute requires update of result).
By default it is true.
|
inherited |
Returns true if attribute causes the result change.
|
inherited |
Immutable argument can not be changed programmatically (e.g.
by constraint) By default it is false. Returns the previous state of the attribute's immutability.
|
inherited |
Returns true if can not be changed programmatically.
|
inherited |
ID of the attribute in Data.
|
virtualinherited |
Resets attribute to deafult state.
Reimplemented in Model_AttributeSelection, Model_AttributeDouble, GeomData_Point2D, and GeomData_Dir.
|
protectedvirtualinherited |
Sets the ID of the attribute in Data (called from Data)
Reimplemented in Model_AttributeSelection.
|
protectedinherited |
is some value assigned to this attribute
|
protectedinherited |
is initialized blocked
|
protectedinherited |
is this attribute used as an argument for execution
|
protectedinherited |
is this attribute can be changed programmatically (e.g. by constraint)