Difference between revisions of "ConstructorInfo"
From Xojo Documentation
(→Examples) |
|||
Line 20: | Line 20: | ||
This code uses the Invoke method to call the FolderItem constructor that takes no parameters: | This code uses the Invoke method to call the FolderItem constructor that takes no parameters: | ||
<rbcode> | <rbcode> | ||
− | + | Var ti As Introspection.TypeInfo = GetTypeInfo(FolderItem) | |
− | + | Var ci() As Introspection.ConstructorInfo = ti.GetConstructors | |
− | + | Var f As FolderItem | |
f = ci(0).Invoke | f = ci(0).Invoke | ||
</rbcode> | </rbcode> |
Latest revision as of 21:50, 16 July 2019
Class (inherits from MemberInfo)
Contains information about the constructors for a class via the Introspection system.
Properties | ||||
|
Methods | |||
|
Sample Code
This code uses the Invoke method to call the FolderItem constructor that takes no parameters:
Var ti As Introspection.TypeInfo = GetTypeInfo(FolderItem)
Var ci() As Introspection.ConstructorInfo = ti.GetConstructors
Var f As FolderItem
f = ci(0).Invoke
Var ci() As Introspection.ConstructorInfo = ti.GetConstructors
Var f As FolderItem
f = ci(0).Invoke
See Also
Introspection module; AttributeInfo, MemberInfo, MethodInfo, ObjectIterator, ParameterInfo, PropertyInfo, TypeInfo classes; GetTypeInfo function.