================================ GeneralObject (hwx.inspire.core) ================================ GeneralObject class provides the ability to extend the Inspire data model with a custom entity. ---------- Attributes ---------- +------------------+------------------+------------------+ | active_: Bool | name_: Attribute | visible_: Bool | +------------------+------------------+------------------+ ---------- Properties ---------- +-------------------------+-------------------------+-------------------------+ | inbrowser_ | movable_ | redrawWhenUnitsChanged_ | +-------------------------+-------------------------+-------------------------+ -------------- Public Methods -------------- +-------------------------------+ | getIcon_ (self) | +-------------------------------+ | hasRequiredReferences_ (self) | +-------------------------------+ | requireRedraw_ (self) | +-------------------------------+ | resurrect_ (self) | +-------------------------------+ ----------------- Attribute Details ----------------- .. _active: ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ active : :ref:`Bool ` ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ Returns or sets the object activeness. Setting this on or off sets all children. Setting to True sets all the parents active too. .. _name: ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ name : :ref:`Attribute ` ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ Returns or sets the name of the object. It can be any text string, including spaces, although it's best to avoid using the following characters: " ' * ? and $. While these characters are allowed, they could create difficulties when you export the model to other applications. .. _visible: ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ visible : :ref:`Bool ` ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ Determines whether the object is visible in the modeling window. Setting this on or off sets all children. Setting to True sets all the parents visible too. ---------------- Property Details ---------------- .. _inbrowser: .. method:: inbrowser Shows the object in the Model Browser. .. _movable: .. method:: movable Specifies if the object can be moved using the move tool. If yes then getting/setting the object.position must be implemented. Can be True, False or a subset of "TX TY TZ RX RY RZ". .. _redrawWhenUnitsChanged: .. method:: redrawWhenUnitsChanged Specifies whether the objects gets redrawn when gui units change. -------------- Method Details -------------- .. _getIcon: .. method:: getIcon(self) Specifies the icon used to display in Model Browser, Object Tables etc .. _hasRequiredReferences: .. method:: hasRequiredReferences(self) Returns whether object is in a valid state or not. Called when references are destroyed and resurrected. Default implementation: - If any references are destroyed then destroy self. - If all references come back then resurrect self. .. _requireRedraw: .. method:: requireRedraw(self) Marks the object that needs to be redrawn in the graphics window. .. _resurrect: .. method:: resurrect(self) Brings back an object to active state, if zombie. Only call from onReferenceResurrected.