ParameterInfo.ParameterType
From Xojo Documentation
Read-Only Property (As TypeInfo )
Contains the parameter’s datatype.
Sample Code
This code displays signatures for all methods of a class:
Var cls As Introspection.TypeInfo = GetTypeInfo(Dictionary)
For Each method As Introspection.MethodInfo In cls.GetMethods
// Collect parameter types
Var paramTypes() As String
For Each paramInfo As Introspection.ParameterInfo In method.GetParameters
paramTypes.Add(paramInfo.ParameterType.Name)
Next
// Build the method signature
If method.ReturnType <> Nil Then
Listbox1.AddRow("Function " + method.Name + "(" + Join(paramTypes, ", ") + ") As " + method.ReturnType.Name)
Else
Listbox1.AddRow("Sub " + method.Name + "(" + Join(paramTypes, ", ") + ")")
End If
Next
For Each method As Introspection.MethodInfo In cls.GetMethods
// Collect parameter types
Var paramTypes() As String
For Each paramInfo As Introspection.ParameterInfo In method.GetParameters
paramTypes.Add(paramInfo.ParameterType.Name)
Next
// Build the method signature
If method.ReturnType <> Nil Then
Listbox1.AddRow("Function " + method.Name + "(" + Join(paramTypes, ", ") + ") As " + method.ReturnType.Name)
Else
Listbox1.AddRow("Sub " + method.Name + "(" + Join(paramTypes, ", ") + ")")
End If
Next