Kanzi  3.9.6
Kanzi Engine API
kanzi::ExclusiveActivityHostConcept Class Referenceabstract

This is the base class for all Exclusive Activity Host nodes. More...

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

Inheritance diagram for kanzi::ExclusiveActivityHostConcept:
[legend]

Classes

struct  ActivityInExclusiveHostInfo
 Stores information that identifies an Activity node under an ExclusiveActivityHost. More...
 
struct  ExclusiveActivityHostContent
 Container for the content information for an ExclusiveActivityHost. More...
 
class  ImplicitActivityChangeRequestMessageArguments
 Base class for Exclusive Activity Host Concept message argument classes. More...
 

Public Types

enum  ExclusiveActivityHostFocusingPolicy { ExclusiveActivityHostFocusingPolicy::WhenHostHasFocus, ExclusiveActivityHostFocusingPolicy::AlwaysFocus, ExclusiveActivityHostFocusingPolicy::NeverFocus }
 Specifies the focusing policy that Kanzi applies to an activating Activity in an Exclusive Activity Host. More...
 

Public Member Functions

virtual const vector< ExclusiveActivityHostConcept::ActivityInExclusiveHostInfo > & getActivitiesInfo () const =0
 Provides access to the list of all registered activities. More...
 
virtual NodegetNode ()=0
 Returns underlying Node of this ExclusiveActivityHostConcept instance. More...
 
virtual const NodegetNode () const =0
 Returns underlying Node of this ExclusiveActivityHostConcept instance. More...
 
virtual void onActivityActivated (NodeSharedPtr activity, string_view prefabPath)=0
 Informs that an Activity node is activated. More...
 
virtual void onActivityDeactivated (NodeSharedPtr activity)=0
 Informs that an Activity node is deactivated. More...
 
virtual NodeSharedPtr onPrefabLoaded (PrefabTemplateSharedPtr prefab, string_view name)=0
 Informs this ExclusiveActivityHost that the prefab for an Activity node has been loaded. More...
 
virtual ~ExclusiveActivityHostConcept ()=default
 Destructor. More...
 

Static Public Member Functions

static PropertyTypeEditorInfoSharedPtr makeEditorInfo ()
 Returns PropertyType editor info of exclusive activity concept. More...
 

Static Public Attributes

static MessageType< ImplicitActivityChangeRequestMessageArgumentsNavigateNextMessage
 In an Exclusive Activity Host requests the activation of the next Activity node in that Exclusive Activity Host node. More...
 
static MessageType< ImplicitActivityChangeRequestMessageArgumentsNavigatePreviousMessage
 In an Exclusive Activity Host requests the activation of the previous Activity node in that Exclusive Activity Host node. More...
 
Properties
static PropertyType< string > ExclusiveActivityHostContentProperty
 Describes the content of an Exclusive Activity Host node. More...
 
static PropertyType< string > ActiveActivityProperty
 The name of the child Activity node of an Exclusive Activity Host, that is either in ActivityConcept::Status::Active or in ActivityConcept::Status::Activating state. More...
 
static PropertyType< string > ActivationPathProperty
 The activation path containing the branch of the Activity tree that is requested to be activated. More...
 
static PropertyType< ExclusiveActivityHostFocusingPolicyFocusOnActivatingActivityProperty
 Sets the policy that an Exclusive Activity Host uses to decide whether it tries to set focus to an activating Activity. More...
 

Protected Member Functions

virtual void onNavigateNextMessage (const ExclusiveActivityHostConcept::ImplicitActivityChangeRequestMessageArguments &args)=0
 Message handler for ExclusiveActivityHostConcept::NavigateNextMessage. More...
 
virtual void onNavigatePreviousMessage (const ExclusiveActivityHostConcept::ImplicitActivityChangeRequestMessageArguments &args)=0
 Message handler for ExclusiveActivityHostConcept::NavigatePreviousMessage. More...
 

Detailed Description

This is the base class for all Exclusive Activity Host nodes.

See also
ExclusiveActivityHost2D, ExclusiveActivityHost3D.

Member Enumeration Documentation

◆ ExclusiveActivityHostFocusingPolicy

Specifies the focusing policy that Kanzi applies to an activating Activity in an Exclusive Activity Host.

Apply this rule to an Exclusive Activity Host.

Since
Kanzi 3.9.4
Enumerator
WhenHostHasFocus 

If the Activity Host contains focus, set focus to the Activity.

AlwaysFocus 

Always set focus to the Activity.

NeverFocus 

Never set focus to the Activity.

Constructor & Destructor Documentation

◆ ~ExclusiveActivityHostConcept()

virtual kanzi::ExclusiveActivityHostConcept::~ExclusiveActivityHostConcept ( )
virtualdefault

Destructor.

Member Function Documentation

◆ makeEditorInfo()

static PropertyTypeEditorInfoSharedPtr kanzi::ExclusiveActivityHostConcept::makeEditorInfo ( )
static

Returns PropertyType editor info of exclusive activity concept.

◆ getActivitiesInfo()

◆ getNode() [1/2]

◆ getNode() [2/2]

◆ onActivityActivated()

virtual void kanzi::ExclusiveActivityHostConcept::onActivityActivated ( NodeSharedPtr  activity,
string_view  prefabPath 
)
pure virtual

◆ onActivityDeactivated()

◆ onPrefabLoaded()

virtual NodeSharedPtr kanzi::ExclusiveActivityHostConcept::onPrefabLoaded ( PrefabTemplateSharedPtr  prefab,
string_view  name 
)
pure virtual

◆ onNavigateNextMessage()

virtual void kanzi::ExclusiveActivityHostConcept::onNavigateNextMessage ( const ExclusiveActivityHostConcept::ImplicitActivityChangeRequestMessageArguments args)
protectedpure virtual

Message handler for ExclusiveActivityHostConcept::NavigateNextMessage.

Activates an activity following the currently active activity. Activates first if no activity active.

◆ onNavigatePreviousMessage()

virtual void kanzi::ExclusiveActivityHostConcept::onNavigatePreviousMessage ( const ExclusiveActivityHostConcept::ImplicitActivityChangeRequestMessageArguments args)
protectedpure virtual

Message handler for ExclusiveActivityHostConcept::NavigatePreviousMessage.

Activates an activity following the currently active activity. Activates first if no activity active.

Member Data Documentation

◆ NavigateNextMessage

MessageType<ImplicitActivityChangeRequestMessageArguments> kanzi::ExclusiveActivityHostConcept::NavigateNextMessage
static

In an Exclusive Activity Host requests the activation of the next Activity node in that Exclusive Activity Host node.

◆ NavigatePreviousMessage

MessageType<ImplicitActivityChangeRequestMessageArguments> kanzi::ExclusiveActivityHostConcept::NavigatePreviousMessage
static

In an Exclusive Activity Host requests the activation of the previous Activity node in that Exclusive Activity Host node.

◆ ExclusiveActivityHostContentProperty

PropertyType<string> kanzi::ExclusiveActivityHostConcept::ExclusiveActivityHostContentProperty
static

Describes the content of an Exclusive Activity Host node.

An Exclusive Activity Host node uses the value of this property to instantiate Activity node prefabs and to control the status and lifetime of its child Activity nodes.

Kanzi Studio user cannot directly edit this property. The ActivityBrowserController sets the value of this property according to the changes done to the state of the Activity Tree in the ActivityBrowser.

The expected format for the property value is the name of an Activity node that an ExclusiveActivityHost initially activates, followed by a list of Activity node descriptions. Each of this Activity node descriptions contains:

  • The name of the Activity node
  • ControllerProperty reference value of the Activity node
  • Path to the prefab of that Activity node The values in this property must be separated by a comma.

Syntax: {<is-initially-active-activity-name>,{<child-activity-name>,<controller-property-value>,<activity-prefab-path>},{<child-activity-name>,<controller-property-value>,<activity-prefab-path>},...} Example: {name0,{name1,666,path1},{name2,123,path2}}.

By default the value of this property is empty, that is, the Activity Host does not contain any content.

Since
Kanzi 3.9.0

◆ ActiveActivityProperty

PropertyType<string> kanzi::ExclusiveActivityHostConcept::ActiveActivityProperty
static

The name of the child Activity node of an Exclusive Activity Host, that is either in ActivityConcept::Status::Active or in ActivityConcept::Status::Activating state.

By default this property does not point to any Activity node. The default value is "".

◆ ActivationPathProperty

PropertyType<string> kanzi::ExclusiveActivityHostConcept::ActivationPathProperty
static

The activation path containing the branch of the Activity tree that is requested to be activated.

It stores the path value only from the moment of receiving an activation request with an activation path longer than just one node, to when this path is forwarded to the first element in the activation path, then The property is reset to default. By default, this property does not contain any activation path. You should not update this property. The Exclusive Activity Host does not react to a change on this property. Kanzi uses this property internally, together with ActiveActivityProperty, during activation with ActivityHostConcept::ActivateActivityMessage.

Since
Kanzi 3.9.0

◆ FocusOnActivatingActivityProperty

PropertyType<ExclusiveActivityHostFocusingPolicy> kanzi::ExclusiveActivityHostConcept::FocusOnActivatingActivityProperty
static

Sets the policy that an Exclusive Activity Host uses to decide whether it tries to set focus to an activating Activity.

See also
ExclusiveActivityHostConcept::ExclusiveActivityHostFocusingPolicy.
Since
Kanzi 3.9.4

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