class ManagedObjectInfo

Contains data about serializable fields of a managed object, and the object's class hierarchy if it belongs to one.

All public fields are by default serializable if their type support serialization. Type is serializable if it has the SerializeObject attribute, or is one of the built-in supported serializable types (primitive such as int or bool, game object, resource or resource reference). Array/List/Dictionary of serializable types is also considered serializable. Public field can be made non-serializable via the DontSerializeField attribute. Private/protected/internal field can be made serializable by specifying the SerializeField attribute.

Public

Constructors

ManagedObjectInfo

ManagedObjectInfo() = default

Methods

GetFullTypeName

String GetFullTypeName() const

Returns the managed type name of the object's type, including the namespace in format "namespace.typename".

GetReflectionType

MonoReflectionType *GetReflectionType() const

FindMatchingField

SPtr<ManagedMemberInfo> FindMatchingField(const SPtr<ManagedMemberInfo> &fieldInfo, const SPtr<ManagedTypeInfo> &fieldTypeInfo) const

Attempts to find a field part of this object that matches the provided parameters.

fieldInfo
Object describing the managed field. Normally this will be a field that was deserialized and you need to ensure it still exists in its parent type, while retrieving the new field info.
fieldTypeInfo
Type information about the type containing the object. Used for debug purposes to ensure the current object's type matches.

Returns: Found field info within this object, or null if not found.

staticGetRttiStatic

static RTTIType *GetRttiStatic()

GetRtti

RTTIType *GetRtti() const override

Returns an interface you can use to access class' Run Time Type Information.

Fields

TypeInfo

SPtr<ManagedTypeInfoObject> TypeInfo

ScriptClass

MonoClass * ScriptClass

MemberNameToIndex

UnorderedMap<String, u32> MemberNameToIndex

Members

Vector<SPtr<ManagedMemberInfo>> Members

BaseClass

SPtr<ManagedObjectInfo> BaseClass

DerivedClasses

Vector<std::weak_ptr<ManagedObjectInfo>> DerivedClasses