Manual binding source. More...
#include <kanzi/core.ui/binding/manual_binding_source.hpp>
Public Member Functions | |
string | getPath () const |
Gets the source object path. More... | |
PropertyField | getPropertyField () const |
Gets the source property field. More... | |
AbstractPropertyType | getPropertyType () const |
Gets the source property type. More... | |
Public Member Functions inherited from kanzi::BindingSource | |
BindingSourceRuntimePtr | createRuntime (BindingLookupContextPtr lookupContext) |
Creates binding source runtime. More... | |
virtual | ~BindingSource () |
Destructor. More... | |
Static Public Member Functions | |
static BindingSourcePtr | create (string_view path, AbstractPropertyType propertyType, PropertyField field) |
Creates a manual binding source. More... | |
Protected Member Functions | |
BindingSourceRuntimePtr | createRuntimeOverride (BindingLookupContextPtr lookupContext) override |
BindingSource::createRuntime implementation. More... | |
ManualBindingSource (string_view path, AbstractPropertyType propertyType, PropertyField field) | |
Constructor. More... | |
Protected Member Functions inherited from kanzi::BindingSource | |
BindingSource () | |
Constructor. More... | |
Protected Attributes | |
PropertyField | m_field |
Source property field. More... | |
string | m_path |
Path to object. More... | |
AbstractPropertyType | m_propertyType |
Source property type. More... | |
Manual binding source.
ManualBindingSource works like ObjectPropertyBindingSource, reading values from Node or RenderPass objects, but does not connect or install any listeners. Property changes cannot cause the binding to be executed.
Kanzi Engine uses ManualBindingSource internally with actions and triggers, utilizing ManualBinding.
To create a manual binding source:
Because property changes do not cause the binding to be executed, ManualBindingSourceRuntime would only read the value once when used with regular bindings - when the binding runtime is first attached. When used with ManualBinding, it would only read values when the binding runtime is explicitly updated.
|
inlineprotected |
Constructor.
path | Path to object. |
propertyType | Property type to listen to. |
field | Property field to read. |
|
static |
Creates a manual binding source.
path | Path to object. |
propertyType | Property type to listen to. |
field | Property field to read. |
|
inline |
Gets the source object path.
|
inline |
Gets the source property type.
|
inline |
Gets the source property field.
|
overrideprotectedvirtual |
BindingSource::createRuntime implementation.
Implements kanzi::BindingSource.
|
protected |
Path to object.
|
protected |
Source property type.
|
protected |
Source property field.