Unravel Engine C++ Reference
Loading...
Searching...
No Matches
unravel::property_path_context Class Reference

Context holder for tracking the current property path during inspection. More...

#include <property_path_generator.h>

Public Member Functions

 property_path_context ()=default
 
void push_segment (const std::string &segment)
 Push a new path segment onto the context stack.
 
void pop_segment ()
 Pop the last path segment from the context stack.
 
auto get_current_path () const -> std::string
 Get the current full property path.
 
auto get_current_path_with_component_type () const -> std::string
 
void set_component_type (const std::string &type)
 Set the component type for this context.
 
auto get_component_type_name () const -> std::string
 Get the component type name.
 
auto is_prefab_context () const -> bool
 Check if we're currently inspecting a prefab instance.
 
void set_prefab_context (bool is_prefab)
 Set whether this is a prefab inspection context.
 
void set_entity_uuid (const hpp::uuid &entity_uuid)
 Set the entity UUID for nested entity tracking.
 
auto get_entity_uuid () const -> hpp::uuid
 Get the entity UUID.
 

Detailed Description

Context holder for tracking the current property path during inspection.

Definition at line 15 of file property_path_generator.h.

Constructor & Destructor Documentation

◆ property_path_context()

unravel::property_path_context::property_path_context ( )
default

Member Function Documentation

◆ get_component_type_name()

auto unravel::property_path_context::get_component_type_name ( ) const -> std::string

Get the component type name.

Returns
The component type name

Definition at line 58 of file property_path_generator.cpp.

◆ get_current_path()

auto unravel::property_path_context::get_current_path ( ) const -> std::string

Get the current full property path.

Returns
The dot-separated property path

Definition at line 23 of file property_path_generator.cpp.

◆ get_current_path_with_component_type()

auto unravel::property_path_context::get_current_path_with_component_type ( ) const -> std::string

Definition at line 44 of file property_path_generator.cpp.

◆ get_entity_uuid()

auto unravel::property_path_context::get_entity_uuid ( ) const -> hpp::uuid

Get the entity UUID.

Returns
The entity UUID if set, or a nil UUID otherwise

Definition at line 68 of file property_path_generator.cpp.

◆ is_prefab_context()

auto unravel::property_path_context::is_prefab_context ( ) const -> bool

Check if we're currently inspecting a prefab instance.

Returns
True if inspecting a prefab instance

◆ pop_segment()

void unravel::property_path_context::pop_segment ( )

Pop the last path segment from the context stack.

Definition at line 15 of file property_path_generator.cpp.

◆ push_segment()

void unravel::property_path_context::push_segment ( const std::string & segment)

Push a new path segment onto the context stack.

Parameters
segmentThe path segment to add

Definition at line 9 of file property_path_generator.cpp.

◆ set_component_type()

void unravel::property_path_context::set_component_type ( const std::string & type)

Set the component type for this context.

Parameters
typeThe RTTR type of the component

Definition at line 53 of file property_path_generator.cpp.

◆ set_entity_uuid()

void unravel::property_path_context::set_entity_uuid ( const hpp::uuid & entity_uuid)

Set the entity UUID for nested entity tracking.

Parameters
entity_uuidThe UUID of the entity being inspected

Definition at line 63 of file property_path_generator.cpp.

◆ set_prefab_context()

void unravel::property_path_context::set_prefab_context ( bool is_prefab)

Set whether this is a prefab inspection context.

Parameters
is_prefabTrue if inspecting a prefab instance

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