SHAPER
9.12.0
|
Attribute that contains reference to the sub-shape of some result, the selected shape. More...
Public Types | |
enum | CenterType { NOT_CENTER , CIRCLE_CENTER , ELLIPSE_FIRST_FOCUS , ELLIPSE_SECOND_FOCUS } |
Type of the center of the circular of elliptic edge. More... | |
Public Member Functions | |
virtual bool | setValue (const ObjectPtr &theContext, const std::shared_ptr< GeomAPI_Shape > &theSubShape, const bool theTemporarily=false)=0 |
Defines the result and its selected sub-shape. More... | |
virtual void | setValueCenter (const ObjectPtr &theContext, const std::shared_ptr< GeomAPI_Edge > &theEdge, const CenterType theCenterType, const bool theTemporarily=false)=0 |
Same as SetValue, but it takes an edge (on circular or elliptic curve) and stores the vertex of the central point (for ellipse the first or the second focus point) More... | |
virtual void | selectValue (const std::shared_ptr< ModelAPI_AttributeSelection > &theSource)=0 |
Makes this selection attribute selects the same as in theSource selection. More... | |
virtual void | removeTemporaryValues ()=0 |
Reset temporary stored values. More... | |
virtual std::shared_ptr< GeomAPI_Shape > | value ()=0 |
Returns the selected subshape. More... | |
virtual ResultPtr | context ()=0 |
Returns the context of the selection (the whole shape owner) More... | |
virtual std::shared_ptr< ModelAPI_Feature > | contextFeature ()=0 |
Returns the context of the selection if the whole feature was selected. More... | |
virtual std::shared_ptr< ModelAPI_Object > | contextObject ()=0 |
Returns the context of the selection : result or feature. More... | |
virtual bool | update ()=0 |
Updates the selection due to the changes in the referenced objects. More... | |
virtual std::string | attributeType () |
Returns the type of this class of attributes, not static method. More... | |
virtual std::wstring | namingName (const std::wstring &theDefaultValue=L"")=0 |
Returns a textual string of the selection. More... | |
virtual void | setId (int theID)=0 |
Defines an id of the selection. More... | |
virtual void | selectSubShape (const std::string &theType, const std::wstring &theSubShapeName)=0 |
Selects sub-shape by the textual Name. More... | |
virtual void | selectSubShape (const std::string &theType, const std::shared_ptr< GeomAPI_Pnt > &thePoint)=0 |
Selects sub-shape by its inner point. More... | |
virtual void | selectSubShape (const std::string &theType, const std::wstring &theContextName, const int theIndex)=0 |
Selects sub-shape by weak naming index. More... | |
virtual bool | isInvalid ()=0 |
Returns true if recompute of selection become impossible. More... | |
virtual bool | isGeometricalSelection () const =0 |
Returns true if is geometrical selection. More... | |
virtual | ~ModelAPI_AttributeSelection () |
To virtually destroy the fields of successors. More... | |
virtual std::wstring | contextName (const ResultPtr &theContext) const =0 |
Returns the name by context. Adds the part name if the context is located in other document. More... | |
virtual void | combineGeometrical ()=0 |
Makes the current local selection becomes all sub-shapes with same base geometry. More... | |
virtual void | updateInHistory (bool &theRemove)=0 |
Updates the arguments of selection if something was affected by creation or reorder of features upper in the history line. 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 std::string | typeId () |
Returns the type of this class of attributes. More... | |
Protected Member Functions | |
ModelAPI_AttributeSelection () | |
Objects are created for features automatically. More... | |
virtual void | setID (const std::string theID) |
Sets the ID of the attribute in Data (called from Data) More... | |
virtual void | reinit () |
Reinitializes the internal state of the attribute (may be needed on undo/redo, abort, etc) 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... | |
Attribute that contains reference to the sub-shape of some result, the selected shape.
|
virtual |
To virtually destroy the fields of successors.
|
protected |
Objects are created for features automatically.
|
pure virtual |
Defines the result and its selected sub-shape.
theContext | object where the sub-shape was selected |
theSubShape | selected sub-shape (if null, the whole context is selected) |
theTemporarily | if it is true, do not store and name the added in the data framework (used to remove immediately, without the following updates) |
Implemented in Model_AttributeSelection.
|
pure virtual |
Same as SetValue, but it takes an edge (on circular or elliptic curve) and stores the vertex of the central point (for ellipse the first or the second focus point)
Implemented in Model_AttributeSelection.
|
pure virtual |
Makes this selection attribute selects the same as in theSource selection.
Implemented in Model_AttributeSelection.
|
pure virtual |
Reset temporary stored values.
Implemented in Model_AttributeSelection.
|
pure virtual |
Returns the selected subshape.
Implemented in Model_AttributeSelection.
|
pure virtual |
Returns the context of the selection (the whole shape owner)
Implemented in Model_AttributeSelection.
|
pure virtual |
Returns the context of the selection if the whole feature was selected.
Implemented in Model_AttributeSelection.
|
pure virtual |
Returns the context of the selection : result or feature.
Implemented in Model_AttributeSelection.
|
pure virtual |
Updates the selection due to the changes in the referenced objects.
Implemented in Model_AttributeSelection.
|
inlinestatic |
Returns the type of this class of attributes.
|
virtual |
Returns the type of this class of attributes, not static method.
Implements ModelAPI_Attribute.
|
pure virtual |
Returns a textual string of the selection.
theDefaultValue | a value, which is used if the naming name can not be obtained |
Implemented in Model_AttributeSelection.
|
pure virtual |
Defines an id of the selection.
Implemented in Model_AttributeSelection.
|
pure virtual |
Selects sub-shape by the textual Name.
Implemented in Model_AttributeSelection.
|
pure virtual |
Selects sub-shape by its inner point.
Implemented in Model_AttributeSelection.
|
pure virtual |
Selects sub-shape by weak naming index.
Implemented in Model_AttributeSelection.
|
pure virtual |
Returns true if recompute of selection become impossible.
Implemented in Model_AttributeSelection.
|
pure virtual |
Returns true if is geometrical selection.
Implemented in Model_AttributeSelection.
|
pure virtual |
Returns the name by context. Adds the part name if the context is located in other document.
Implemented in Model_AttributeSelection.
|
pure virtual |
Makes the current local selection becomes all sub-shapes with same base geometry.
Implemented in Model_AttributeSelection.
|
pure virtual |
Updates the arguments of selection if something was affected by creation or reorder of features upper in the history line.
Returns theRemove true if this attribute must be removed (become deleted)
Implemented in Model_AttributeSelection.
|
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.
|
protectedvirtualinherited |
Reinitializes the internal state of the attribute (may be needed on undo/redo, abort, etc)
Reimplemented in Model_AttributeTables, Model_AttributeString, Model_AttributeSelectionList, Model_AttributeRefList, Model_AttributeReference, Model_AttributeRefAttrList, Model_AttributeRefAttr, Model_AttributeInteger, Model_AttributeIntArray, Model_AttributeImage, Model_AttributeDoubleArray, Model_AttributeDouble, Model_AttributeDocRef, Model_AttributeBoolean, GeomData_Point2DArray, GeomData_Point2D, GeomData_Point, and GeomData_Dir.
|
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)