unreal.PyTestTypeHint
¶
- class unreal.PyTestTypeHint(outer: Optional[Object] = None, name: Union[Name, str] = 'None')¶
Bases:
Object
Used to verify if the generated Python stub is correctly type-hinted (if type hint is enabled). The stub is generated * in the project intermediate folder when the Python developer mode is enabled (Editor preferences). The type hints can * be checked in the stub itself or PythonScriptPlugin/Content/Python/test_type_hints.py can be loaded in a Python IDE that * supports type checking and look at the code to verify that there is not problems with the types.
C++ Source:
Plugin: PythonScriptPlugin
Module: PythonScriptPlugin
File: PyTest.h
Editor Properties: (see get_editor_property/set_editor_property)
bool_prop
(bool): [Read-Write] Bool Prop: Check type hinted properties (setter/getter)delegate_prop
(PyTestDelegate): [Read-Write] Delegate Propenum_prop
(PyTestEnum): [Read-Write] Enum Propfield_path_prop
(FieldPath): [Read-Write] Field Path Propfloat_prop
(float): [Read-Write] Float Propint_prop
(int32): [Read-Write] Int Propmap_prop
(Map[int32, str]): [Read-Write] Map Propmulticast_delegate_prop
(PyTestMulticastDelegate): [Read-Write] Multicast Delegate Propname_array_prop
(Array[Name]): [Read-Write] Name Array Propname_prop
(Name): [Read-Write] Name Propobject_array_prop
(Array[Object]): [Read-Write] Object Array Propobject_prop
(PyTestObject): [Read-Write] Object Propset_prop
(Set[str]): [Read-Write] Set Propslate_tick_delegate
(PyTestSlateTickDelegate): [Read-Write] Slate Tick Delegate: Members to facilitate testing particular Python API.str_array_prop
(Array[str]): [Read-Write] Str Array Propstring_prop
(str): [Read-Write] String Propstruct_prop
(PyTestStruct): [Read-Write] Struct Proptext_array_prop
(Array[Text]): [Read-Write] Text Array Proptext_prop
(Text): [Read-Write] Text Prop
- property bool_prop: bool¶
[Read-Write] Bool Prop: Check type hinted properties (setter/getter)
- Type:
(bool)
- check_delegate_type_hints(param1) PyTestDelegate ¶
Check Delegate Type Hints
- Parameters:
param1 (PyTestDelegate) –
- Return type:
- check_enum_type_hints(param1, param2=PyTestEnum.ONE) PyTestEnum ¶
Check Enum Type Hints
- Parameters:
param1 (PyTestEnum) –
param2 (PyTestEnum) –
- Return type:
- check_float_type_hints(param1, param2, param3=-3.300000, param4=4.400000) double ¶
Check Float Type Hints
- check_integer_type_hints(param1, param2=4, param3=5) int32 ¶
Check Integer Type Hints
- Parameters:
param1 (uint8) –
param2 (int32) –
param3 (int64) –
- Return type:
int32
- check_object_type_hints(param1, param4=None) PyTestObject ¶
Check Object Type Hints
- Parameters:
param1 (PyTestObject) –
param4 (PyTestObject) –
- Return type:
- check_struct_type_hints(param1, param2=[False, 0, 0.000000, PyTestEnum.ONE, '', 'None', '', FieldPath(), FieldPath(), [], [], {}]) PyTestStruct ¶
Check Struct Type Hints
- Parameters:
param1 (PyTestStruct) –
param2 (PyTestStruct) –
- Return type:
- classmethod check_tuple_return_type(out_string) -> (int32, out_string=str)¶
Check Tuple Return Type
- property delegate_prop: PyTestDelegate¶
[Read-Write] Delegate Prop
- Type:
- property enum_prop: PyTestEnum¶
[Read-Write] Enum Prop
- Type:
- property multicast_delegate_prop: PyTestMulticastDelegate¶
[Read-Write] Multicast Delegate Prop
- Type:
- property object_prop: PyTestObject¶
[Read-Write] Object Prop
- Type:
- property slate_tick_delegate: PyTestSlateTickDelegate¶
[Read-Write] Slate Tick Delegate: Members to facilitate testing particular Python API.
- Type:
- property struct_prop: PyTestStruct¶
[Read-Write] Struct Prop
- Type: