UtilReflectionGetMethod(Type, String, BindingFlags) 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,
BindingFlags bindingFlags = BindingFlags.Instance|BindingFlags.Static|BindingFlags.Public|BindingFlags.NonPublic|BindingFlags.FlattenHierarchy|BindingFlags.InvokeMethod
)
Public Shared Function GetMethod (
type As Type,
methodName As String,
Optional bindingFlags As BindingFlags = BindingFlags.Instance Or BindingFlags.Static Or BindingFlags.Public Or BindingFlags.NonPublic Or BindingFlags.FlattenHierarchy Or BindingFlags.InvokeMethod
) As MethodInfo
Dim type As Type
Dim methodName As String
Dim bindingFlags As BindingFlags
Dim returnValue As MethodInfo
returnValue = UtilReflection.GetMethod(type,
methodName, bindingFlags)
public:
static MethodInfo^ GetMethod(
Type^ type,
String^ methodName,
BindingFlags bindingFlags = BindingFlags::Instance|BindingFlags::Static|BindingFlags::Public|BindingFlags::NonPublic|BindingFlags::FlattenHierarchy|BindingFlags::InvokeMethod
)
static member GetMethod :
type : Type *
methodName : string *
?bindingFlags : BindingFlags
(* Defaults:
let _bindingFlags = defaultArg bindingFlags BindingFlags.Instance|BindingFlags.Static|BindingFlags.Public|BindingFlags.NonPublic|BindingFlags.FlattenHierarchy|BindingFlags.InvokeMethod
*)
-> MethodInfo
No code example is currently available or this language may not be supported.
- type Type
-
The source type from which to retrieve its properties.
- methodName String
-
The name of the method to search for.
- bindingFlags BindingFlags (Optional)
-
Flags that controls binding and the way in which the search for members and types is conducted by Reflection.
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 method As MethodInfo = GetMethod(GetType(Form), "Hide")
method.Invoke(Me, Nothing)
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.