
154 vFoglight
Web Component Guide
At runtime, if no specific renderer has been specified on a runtime value, the Web
Component Framework will look in the type mappings to see if a renderer has been
mapped to the type of the data or the property the data was retrieved from. In the event
of a conflict, renderers mapped to properties take precedence over renderers mapped to
types.
When an Icon Renderer is explicitly specified as the renderer on a runtime value, the
renderer looks in the type mappings to find the icon that has been mapped to the type of
the data evaluated from the runtime value.
Units
Unit mappings associate renderers to a specific data unit. At runtime, if no specific
renderer has been specified on a runtime value and no renderer has been found in the
type mappings, the Web Component Framework looks in the unit mappings to see if a
renderer has been mapped to the unit of the data.
Mappings of renderers to units are configured in the Units tab. When a renderer is
mapped to a unit any view property bound to data of the unit displays using the mapped
renderer. This is unless a specific renderer is set on the property or another renderer is
mapped to the data’s type or property.
Determining the Appropriate Renderer for a Runtime Value
Determining which renderer to use for a given RuntimeValue involves several
possibilities. The following are the current possibilities, listed in priority order, which
means if the first one does not apply, the second one is tried, and so on.
• If a named renderer is given for this RuntimeValue (in the renderer-id attribute),
use it.
• If the value is a Web Component Framework DataObject, and a renderer is
associated with its SDO Type's name (via a <type> element within the
<associations> element), use that renderer.
• If the value is derived from a metric, and is a Number, and a renderer is associated
with the fully qualified name property of the metric (via a <metric> element
within the <associations> element), use that renderer. Metric names are fully
qualified as datasource name, a colon and the metric name, for example
cpuUsage
Comentarios a estos manuales