Kanzi  3.9.6
Kanzi Engine API
kanzi::DataDrivenExclusiveActivityHostConcept Class Referenceabstract

Base class for the Data-Driven Exclusive Activity Host classes. More...

#include <kanzi/ui/node/concept/activity/data_driven_exclusive_activity_host_concept.hpp>

Inheritance diagram for kanzi::DataDrivenExclusiveActivityHostConcept:
[legend]

Public Member Functions

int getActiveActivityIndex () const
 Gets the value of the ActiveActivityIndexProperty. More...
 
ResourceSharedPtr getActivitySource () const
 Gets the value of the ActivitySourceProperty. More...
 
string getActivityTemplate () const
 Gets the value of the ActivityTemplateProperty. More...
 
virtual NodegetNode ()=0
 Returns the underlying Node of this DataDrivenExclusiveActivityHostConcept instance. More...
 
virtual const NodegetNode () const =0
 Returns the underlying Node of this DataDrivenExclusiveActivityHostConcept instance. More...
 
void setActiveActivityIndex (int value)
 Sets the value of the ActiveActivityIndexProperty. More...
 
void setActivitySource (ResourceSharedPtr value)
 Sets the value of the ActivitySourceProperty. More...
 
void setActivityTemplate (string_view prefabUrl)
 Sets the value of the ActivityTemplateProperty. More...
 
virtual ~DataDrivenExclusiveActivityHostConcept ()=default
 Destructor. More...
 

Static Public Member Functions

static string getNameForIndex (int index)
 Returns a unique name for the data Activity at the given index in the Data Source List. More...
 
static PropertyTypeEditorInfoSharedPtr makeEditorInfo ()
 Returns PropertyType editor info of DataDrivenExclusiveActivityHostConcept. More...
 

Static Public Attributes

static constexpr const char * s_activeDataActivityName
 Public name which Kanzi uses to refer to the currently and exclusively active data Activity of a Data-Driven Exclusive Activity Host. More...
 
static constexpr int s_defaultActiveActivityIndex
 The default value of the DataDrivenExclusiveActivityHostConcept::ActiveActivityIndexProperty. More...
 
Properties
static PropertyType< ResourceSharedPtrActivitySourceProperty
 Sets the DataObject that provides the data for the Activities of a Data-Driven Exclusive Activity Host. More...
 
static PropertyType< string > ActivityTemplateProperty
 Sets the prefab template that a Data-Driven Exclusive Activity Host uses for the Activities that it creates. More...
 
static PropertyType< int > ActiveActivityIndexProperty
 The index of the active Activity in the Data-Driven Exclusive Activity Host. More...
 

Detailed Description

Base class for the Data-Driven Exclusive Activity Host classes.

This class defines the common types, functionality, and properties for the Data-Driven Exclusive Activity Host classes.

See also
DataDrivenExclusiveActivityHost2D, DataDrivenExclusiveActivityHost3D
Since
Kanzi 3.9.0

Constructor & Destructor Documentation

◆ ~DataDrivenExclusiveActivityHostConcept()

virtual kanzi::DataDrivenExclusiveActivityHostConcept::~DataDrivenExclusiveActivityHostConcept ( )
virtualdefault

Destructor.

Member Function Documentation

◆ makeEditorInfo()

static PropertyTypeEditorInfoSharedPtr kanzi::DataDrivenExclusiveActivityHostConcept::makeEditorInfo ( )
static

◆ getNode() [1/2]

◆ getNode() [2/2]

◆ getActivitySource()

ResourceSharedPtr kanzi::DataDrivenExclusiveActivityHostConcept::getActivitySource ( ) const

Gets the value of the ActivitySourceProperty.

Returns
The DataObject that provides the data for Activities of this Data-Driven Exclusive Activity Host.
See also
setActivitySource()

◆ setActivitySource()

void kanzi::DataDrivenExclusiveActivityHostConcept::setActivitySource ( ResourceSharedPtr  value)

Sets the value of the ActivitySourceProperty.

Parameters
valueThe DataObject that provides the data for Activities of this Data-Driven Exclusive Activity Host.
See also
getActivitySource()

◆ getActivityTemplate()

string kanzi::DataDrivenExclusiveActivityHostConcept::getActivityTemplate ( ) const

Gets the value of the ActivityTemplateProperty.

Returns
The path of the prefab template that this Data-Driven Exclusive Activity Host uses to create Activities.
See also
setActivityTemplate()

◆ setActivityTemplate()

void kanzi::DataDrivenExclusiveActivityHostConcept::setActivityTemplate ( string_view  prefabUrl)

Sets the value of the ActivityTemplateProperty.

Parameters
prefabUrlThe path of the prefab template that this Data-Driven Exclusive Activity Host uses to create Activities.
See also
getActivityTemplate()
Since
Kanzi 3.9.1. Refactor setActivityTemplate(string prefabUrl) to setActivityTemplate(string_view prefabUrl).

◆ getActiveActivityIndex()

int kanzi::DataDrivenExclusiveActivityHostConcept::getActiveActivityIndex ( ) const

Gets the value of the ActiveActivityIndexProperty.

Returns
The index of the active Activity in this Data-Driven Exclusive Activity Host.
See also
setActiveActivityIndex()
Since
Kanzi 3.9.1. Renamed getActiveItemIndex() to getActiveActivityIndex().

◆ setActiveActivityIndex()

void kanzi::DataDrivenExclusiveActivityHostConcept::setActiveActivityIndex ( int  value)

Sets the value of the ActiveActivityIndexProperty.

Parameters
valueThe index of the active Activity in this Data-Driven Exclusive Activity Host.
See also
getActiveActivityIndex()
Since
Kanzi 3.9.1. Renamed getActiveItemIndex() to setActiveActivityIndex().

◆ getNameForIndex()

static string kanzi::DataDrivenExclusiveActivityHostConcept::getNameForIndex ( int  index)
static

Returns a unique name for the data Activity at the given index in the Data Source List.

Parameters
indexIndex of the data Activity in the Data Source List.
Returns
Unique name for data Activity at the given index.

Member Data Documentation

◆ ActivitySourceProperty

PropertyType<ResourceSharedPtr> kanzi::DataDrivenExclusiveActivityHostConcept::ActivitySourceProperty
static

Sets the DataObject that provides the data for the Activities of a Data-Driven Exclusive Activity Host.

The default value is ResourceSharedPtr().

See also
setActivitySource(), getActivitySource()

◆ ActivityTemplateProperty

PropertyType<string> kanzi::DataDrivenExclusiveActivityHostConcept::ActivityTemplateProperty
static

Sets the prefab template that a Data-Driven Exclusive Activity Host uses for the Activities that it creates.

The default value is "".

See also
setActivityTemplate(), getActivityTemplate()

◆ ActiveActivityIndexProperty

PropertyType<int> kanzi::DataDrivenExclusiveActivityHostConcept::ActiveActivityIndexProperty
static

The index of the active Activity in the Data-Driven Exclusive Activity Host.

After instantiating all Activities from a Data Source, this property refers to the only currently active Activity in the Data-Driven Exclusive Activity Host. To deactivate all the Activities in an Activity Host, set this property to -1. By default the value of this index is -1 and all Activities are inactive.

See also
setActiveActivityIndex(), getActiveActivityIndex()
Since
Kanzi 3.9.1. Renamed ActiveItemIndexProperty to ActiveActivityIndexProperty.

◆ s_activeDataActivityName

constexpr const char* kanzi::DataDrivenExclusiveActivityHostConcept::s_activeDataActivityName
static

Public name which Kanzi uses to refer to the currently and exclusively active data Activity of a Data-Driven Exclusive Activity Host.

The Activity with this name internally holds the data of the currently active Activity from the Data Source List.

◆ s_defaultActiveActivityIndex

constexpr int kanzi::DataDrivenExclusiveActivityHostConcept::s_defaultActiveActivityIndex
static

The default value of the DataDrivenExclusiveActivityHostConcept::ActiveActivityIndexProperty.

Set the DataDrivenExclusiveActivityHostConcept::ActiveActivityIndexProperty to this value to deactivate all the Activities in a Data-Driven Exclusive Activity Host.

Since
Kanzi 3.9.1. Renamed s_defaultActiveItemIndex to s_defaultActiveActivityIndex.

The documentation for this class was generated from the following file: