Method SerializedPropertyToType
SerializedPropertyToType(SerializedProperty)
Gets the Type of a SerializedProperty object, if possible.
Declaration
public static Type SerializedPropertyToType(SerializedProperty property)
Parameters
Type | Name | Description |
---|---|---|
SerializedProperty | property | The |
Returns
Type | Description |
---|---|
Type | The best guess type. |
Remarks
Guesses the type of a SerializedProperty
and returns a System.Type
, if one exists.
This function checks the type of the target object by iterating through its fields looking for
one that matches the property name. This may return null if property
is a
SerializedProperty
that represents a native type with no managed equivalent.