UtilReflectionGetMethod(Type, String, Type) Method
Searches for the target method in the specified Type.
Namespace: DevCase.Core.Diagnostics.Assembly.ReflectionAssembly: DevCase.net48 (in DevCase.net48.dll) Version: 6.0.0.0 (6.0)
XMLNS for XAML: Not mapped to an xmlns.
public static MethodInfo GetMethod(
Type type,
string methodName,
Type[] types
)
Public Shared Function GetMethod (
type As Type,
methodName As String,
types As Type()
) As MethodInfo
Dim type As Type
Dim methodName As String
Dim types As Type()
Dim returnValue As MethodInfo
returnValue = UtilReflection.GetMethod(type,
methodName, types)
public:
static MethodInfo^ GetMethod(
Type^ type,
String^ methodName,
array<Type^>^ types
)
static member GetMethod :
type : Type *
methodName : string *
types : Type[] -> MethodInfo
No code example is currently available or this language may not be supported.
- type Type
-
The source type from which to retrieve the method.
- methodName String
-
The name of the method to search for.
- types Type
-
An array of Type objects representing the number, order, and type of the parameters for the method to get.
You can specify an empty array of Type objects (as provided by the EmptyTypes field)
to get a method that takes no parameters.
MethodInfo
A
MethodInfo instance that represents the resulting method.
This is a code example.
No code example is currently available or this language may not be supported.
Dim types As Type() = {GetType(Integer), GetType(Integer), GetType(Integer), GetType(Integer)}
Dim params As Object() = {Me.Location.X, Me.Location.Y, CInt(Me.Size.Width * 1.5), CInt(Me.Size.Height * 1.5)}
Dim method As MethodInfo = GetMethod(GetType(Form), "SetBounds", types)
method.Invoke(Me, params)
No code example is currently available or this language may not be supported.
No code example is currently available or this language may not be supported.
No code example is currently available or this language may not be supported.
No code example is currently available or this language may not be supported.