#include <ReflectContext.h>
Inherited by AZ::BehaviorContext, AZ::JsonRegistrationContext, and AZ::SerializeContext.
Public Member Functions | |
AZ_TYPE_INFO_WITH_NAME_DECL (ReflectContext) | |
AZ_RTTI_NO_TYPE_INFO_DECL () | |
void | EnableRemoveReflection () |
void | DisableRemoveReflection () |
bool | IsRemovingReflection () const |
bool | IsOnDemandTypeReflected (AZ::Uuid typeId) |
Check if an OnDemandReflection type's typeid is already reflected. | |
virtual bool | IsTypeReflected (AZ::Uuid) const |
void | ExecuteQueuedOnDemandReflections () |
Execute all queued OnDemandReflection calls. | |
Protected Attributes | |
bool | m_isRemoveReflection |
True if all calls in the context should be considered to remove not to add reflection. | |
AZStd::unordered_map< AZ::Uuid, AZStd::weak_ptr< Internal::ReflectionFunctionRef > > | m_onDemandReflection |
Store the on demand reflect functions so we can avoid double-reflecting something. | |
AZStd::vector< AZStd::pair< AZ::Uuid, StaticReflectionFunctionPtr > > | m_toProcessOnDemandReflection |
OnDemandReflection functions that need to be called. | |
AZStd::deque< AZ::Uuid > | m_currentlyProcessingTypeIds |
The type ids of the currently reflecting type. Used to prevent circular references. Is a set to prevent recursive circular references. | |
friend | OnDemandReflectionOwner |
Base class for all reflection contexts. Currently we recommend to follow the following declarative format for all context. (Keep in mind this if only for direct C++ interface, code generators will generate code on the top of this interface) context->Class<TYPE>("Other descriptive parameters") ->Field/Propety("field name",&TYPE::m_field) ->Method("method name),&TYPE::Method) ... We recommend that all ReflectContext implement a path to remove reflection when a reflected class/descriptor is deleted. To do so make sure that when \ref ReflectContext::m_isRemoveReflection is set to true any calls to Class<...>() actualy remove reflection. We recommend this approach so the user can write only one reflection function (not Reflect and "Unreflect")