cf2:Property

Purpose

Allows custom properties to be added to existing components and XDIME 2 elements.

There are two ways in which a property can be added: as a new property or as an alias for another property. In the second case, the observable property is retrieved from its component and stored under a new name in the owning component.

The owner of a new or aliased property can be either an existing component or an element. If the owner is an element, i.e. it is not associated with a component, then a new component is created with the same id as the element. The newly created component implements the cf2:ObservablePropertySet API. The property is then added to this component. If the owner is a component, or an element that is associated with a component internally, then it depends on whether the component implements the cf2:ObservablePropertySet API. If it does, then the property is simply added to the set. Otherwise, the cf2:ObservablePropertySet API is mixed into the object (not the class) and then the property is added.

Exported Features

cf2:Property

Imported Features

cf2:ObservablePropertySet, cf2:ConstructionComponent

Markup

This component is provided by the cf2:property element.

Related topics