============================ Reference (hwx.inspire.core) ============================ Store a Named entity or Feature. Use List or ListOfList(Reference) to store multiple values. Default for references is not currently supported. -------------- Public Methods -------------- +--------------------------------------------------------------+ | OnAttributeModify_ (self, obj, attr, value, oldValue, units) | +--------------------------------------------------------------+ | activateListener_ (self, obj) | +--------------------------------------------------------------+ | castForGet_ (self, obj, value) | +--------------------------------------------------------------+ | castForSet_ (self, obj, value) | +--------------------------------------------------------------+ | create_ (self, obj) | +--------------------------------------------------------------+ | createList_ (self, obj) | +--------------------------------------------------------------+ | createListList_ (self, obj) | +--------------------------------------------------------------+ | deactivateListener_ (self, obj) | +--------------------------------------------------------------+ | disable_ (self, obj) | +--------------------------------------------------------------+ | enable_ (self, obj) | +--------------------------------------------------------------+ | getGuiValue_ (self, obj) | +--------------------------------------------------------------+ | getInCoreValue_ (self, obj) | +--------------------------------------------------------------+ | getReferences_ (self, obj) | +--------------------------------------------------------------+ | getType_ (self, obj) | +--------------------------------------------------------------+ | getValue_ (self, obj) | +--------------------------------------------------------------+ | getValueList_ (self, obj) | +--------------------------------------------------------------+ | getValueListList_ (self, obj) | +--------------------------------------------------------------+ | setValue_ (self, obj, value) | +--------------------------------------------------------------+ | setValueList_ (self, obj, value) | +--------------------------------------------------------------+ | setValueListList_ (self, obj, value) | +--------------------------------------------------------------+ -------------- Method Details -------------- .. _OnAttributeModify: .. method:: OnAttributeModify(self, obj, attr, value, oldValue, units) Callback method when the reference gets modified. .. _activateListener: .. method:: activateListener(self, obj) Listen to referenced object for any changes. .. _castForGet: .. method:: castForGet(self, obj, value) Converts and returns the reference value to its external type. :param obj: Object this attribute belongs to. :type obj: GeneralObject :param value: Value of the attribute to be converted. :type value: Named :returns: Converted value. :rtype: Named, Feature .. _castForSet: .. method:: castForSet(self, obj, value) Converts and validates the reference values before setting. :param obj: Object this attribute belongs to. :type obj: GeneralObject :param value: Value of the attribute to set. :type value: Material, Part, Feature, Named :returns: Validated and converted value. :rtype: Reference .. _create: .. method:: create(self, obj) Creates a reference attribute of the specified object. .. _createList: .. method:: createList(self, obj) Creates a list of references. .. _createListList: .. method:: createListList(self, obj) Creates a nested list of references. .. _deactivateListener: .. method:: deactivateListener(self, obj) Stop listening to referenced objects. .. _disable: .. method:: disable(self, obj) Disables listener for the reference object. .. _enable: .. method:: enable(self, obj) Enables listener for the reference object. .. _getGuiValue: .. method:: getGuiValue(self, obj) Returns the reference value as a string. .. _getInCoreValue: .. method:: getInCoreValue(self, obj) Calls the incore get method (defined in C++) of the reference. :param obj: Object this attribute belongs to. :type obj: GeneralObject :param value: Value of the attribute to get. :type value: Named :returns: Value returned by the incore get method. :rtype: Reference .. _getReferences: .. method:: getReferences(self, obj) Returns the list of references from the object. .. _getType: .. method:: getType(self, obj) Returns the type of the Reference attribute. .. _getValue: .. method:: getValue(self, obj) Returns the reference value. .. _getValueList: .. method:: getValueList(self, obj) Returns the list of references. .. _getValueListList: .. method:: getValueListList(self, obj) Returns the nested list of references. .. _setValue: .. method:: setValue(self, obj, value) Sets the specified reference value. .. _setValueList: .. method:: setValueList(self, obj, value) Sets the specified list of references. .. _setValueListList: .. method:: setValueListList(self, obj, value) Sets the specified nested list of references.