Table of Contents

Method CheckBindMethodsOn

Namespace
Zyl.VectorTraits.Impl
Assembly
VectorTraits.dll

CheckBindMethodsOn(Func<MethodInfo, MethodInfo, bool>, Type, Type, IDictionary<string, List<MethodInfo>>?, Func<MethodInfo, MethodInfo?, object?, bool>?, object?)

Check the binding of the method set on funcEquals (基于 funcEquals 检查方法集的绑定.

public static int CheckBindMethodsOn(Func<MethodInfo, MethodInfo, bool> funcEquals, Type staticType, Type objectType, IDictionary<string, List<MethodInfo>>? interfaceMethodsDictionary, Func<MethodInfo, MethodInfo?, object?, bool>? onMissed = null, object? userdata = null)

Parameters

funcEquals Func<MethodInfo, MethodInfo, bool>

The callback function to determine equality (判断相等的回调函数). Prototype: bool isEquals = funcEquals(MethodInfo a, MethodInfo b). e.g. EqualsParametersType(MethodInfo, MethodInfo)

staticType Type

The type of a static class (静态类的类型).

objectType Type

The type of a object class (对象类的类型).

interfaceMethodsDictionary IDictionary<string, List<MethodInfo>>

The methods of interface (接口类型的方法集合). If it is not null, the staticType is checked in the scope of the method set of the interface (如果它非空,则在接口的方法集范围内检查 staticType ).

onMissed Func<MethodInfo, MethodInfo, object, bool>

The callback function for finding a missed method (找到未命中方法时的回调函数). Prototype: bool isIgnore = onMissed(MethodInfo methodStatic, MethodInfo? methodInterface, object? userdata). If it is null, OnMissed_Default(MethodInfo, MethodInfo?, object?) will be used.

userdata object

The userdata.

Returns

int

Returns the number of missed methods. Specifically, the number of times when onMissed returns false (返回未命中方法的个数。具体来说,是 onMissed 返回false的次数).