Skip to end of metadata
Go to start of metadata

ArkAttributeType is a python object representing an arKItect Attribute Type.

Standard interface methods

  • GetName()
    Returns the name of the attribute type.
  • SetName( name )
    *Works only with arKItect Designer*
    Changes the name of the attribute type. name cannot contain the following symbols : '\ / : * ? " < > |' - in this case the method raises a ValueError exception.
  • GetType()
    Returns type of attribute value (see constants ARK_ATTRIB_xxxx)
  • SetType( attribtype )
    *Works only with arKItect Designer*
    Valid only for ARK_ATTRIB_MEMO and ARK_ATTRIB_TEXT
    Changes type of attribute value to attribtype: ARK_ATTRIB_MEMO can be promoted to ARK_ATTRIB_MARKUP and ARK_ATTRIB_TEXT can be promoted to ARK_ATTRIB_TEXTLARGE.

    Icon

    Method is only available in arKItect 4.4.2 and following

  • GetDefaultValue()
    Returns the default value of the attribute type.
  • SetDefaultValue( defaultvalue, isModifiable=True )
    *Works only with arKItect Designer*
    Sets the default value of the attribute type and defines whether it can be modified later for objects. If isModifiable is False - the default value will be displayed for all objects (even if individual attribute value was defined for the object before) (excluding Date and Author attributes)

  • ResetDefaultValue()
    *Works only with arKItect Designer*
    Removes default value.

  • IsModifiable()
    Returns True if attribute value can be modified, False otherwise. If returned value is False, then any attribute of this type will retain its default value forever. Use SetDefaultValue() method to modify this flag.
  • SetModifiable( isModifiable )
    *Works only with arKItect Designer*
    Defines whether default value of the attribute type can be modified. If default value is not yet defined, the method raises an error - SetDefaultValue method should be used instead.
    To apply changes, FlushProperties() method must be called after.
    Note that the modification does not changes behavior of ArkAttribute objects, requested before the call to SetModifiable.
  • GetAttributeList()
    Returns the list of child ArkAttributeType objects. The list will be non empty only for the attribute types ARK_ATTRIB_ENUM and ARK_ATTRIB_GROUP.
  • GetParentsList()
    Returns list of all ArkMatrixType and ArkAttributeType objects, that represent rules and attribute groups, containing given attribute.
  • AddAttribute( arkattrib, attribtype=None, defaultvalue=None )
    *Works only with arKItect Designer*
    Valid only for ARK_ATTRIB_GROUP and ARK_ATTRIB_ENUM. In the case of ARK_ATTRIB_ENUM only attributes of type ARK_ATTRIB_ENUM_VALUE can be added. For further description refer to the ArkMatrixType method.
  • DeleteAttribute( arkattrib )
    *Works only with arKItect Designer*
    Removes the given arkattrib from the parent object. arkattrib can be a name or an ArkAttributeType object.
  • SetKeys( key_list )
    *Works only with arKItect Designer*
    Sets object's keys.
  • GetKeys()
    Returns list of keys (strings)
  • GetIconHandle()
    Returns the objt`s Icon handle

Properties management methods

  • SetProperty( PropEntry, PropValue )
    *Works only with arKItect Designer*
    See the same method in the ArkMatrixType object.
    Additional PropEntry specific to ArkAttributeType:
    • ARK_ATYPE_READ_ONLY: a flag specifying whether attribute can be modified through GUI (in views and properties) - not available for attributes of type ARK_ATTRIB_GROUP and ARK_ATTRIB_ENUM_VALUE
    • ARK_ATYPE_UNIQUE: a flag specifying whether attribute value should be unique in the project - available only for attributes of type ARK_ATTRIB_TEXT
    • ARK_ATYPE_EXCLUDE_FROM_REVMNG: a flag specifying whether changes of object attribute values of this Attribute Type are excluded from object revision management
    • ARK_ATYPE_DISPLAY_ATTRIB_NAME: a flag specifying whether attribute name is displayed in views
    • ARK_ATYPE_DISPLAY_ATTRIB_ICON: a flag specifying whether attribute icon is displayed in views
    • ARK_ATYPE_DISPLAY_ATTRIB_VALUE: a flag specifying whether attribute value is displayed in views
  • FlashProperties()
    *Works only with arKItect Designer*
    See the same method in the ArkMatrixType object.
  • RestoreProperties()
    *Works only with arKItect Designer*
    See the same method in the ArkMatrixType object.
  • GetObjBGImage()
    Returns an ArkImage holding the ArkObjRef background image, or None if the background image does not exist.
  • GetObjFGImage()
    Returns an ArkImage holding the ArkObjRef foreground image, or None if the foreground image does not exist.
  • SetObjBGImage( image )
    *Works only with arKItect Designer*
    Sets the object background image. The parameter image should be an ArkImage object.
  • SetObjFGImage( image )
    *Works only with arKItect Designer*
    Sets the object foreground image. The parameter image should be an ArkImage object.

 

  • No labels