SpanAction<T,TArg> 委托
定义
封装一个方法,该方法接收 T 类型的对象范围和 TArg 类型的状态对象。Encapsulates a method that receives a span of objects of type T and a state object of type TArg.
generic <typename T, typename TArg>
public delegate void SpanAction(Span<T> span, TArg arg);
public delegate void SpanAction<T,in TArg>(Span<T> span, TArg arg);
type SpanAction<'T, 'Arg> = delegate of Span<'T> * 'Arg -> unit
Public Delegate Sub SpanAction(Of T, In TArg)(span As Span(Of T), arg As TArg)
类型参数
- T
范围内的对象的类型。The type of the objects in the span.
- TArg
表示状态的对象的类型。The type of the object that represents the state.
这是逆变类型参数。 即,可以使用指定的类型,也可以使用派生程度较低的任何类型。 有关协变和逆变的详细信息,请参阅泛型中的协变和逆变。参数
- span
- Span<T>
T 类型的对象范围。A span of objects of type T.
- arg
- TArg
TArg 类型的状态对象。A state object of type TArg.
扩展方法
| GetMethodInfo(Delegate) |
获取指示指定委托表示的方法的对象。Gets an object that represents the method represented by the specified delegate. |