Skip to content

Class ActionHelper<T>

Namespace: Tool.Utils.ActionDelegate
Assembly: Tool.Net.dll

根据 指定类,获取该类下面指定的 集合,

类的扩展帮助类
csharp
public sealed class ActionHelper<T> : IEnumerable

Type Parameters

T

类对象

Inheritance

objectActionHelper<T>

Implements

IEnumerable

Inherited Members

object.Equals(object?), object.Equals(object?, object?), object.GetHashCode(), object.GetType(), object.ReferenceEquals(object?, object?), object.ToString()

Extension Methods

ObjectExtension.Add<T>(object, object, object), ObjectExtension.CopyEntity(object, object, params string[]), ObjectExtension.EntityToJson(object), ObjectExtension.EntityToJson(object, bool), ObjectExtension.EntityToJson(object, bool, string), DictionaryExtension.GetDictionary(object), TypeExtension.GetFieldKey(object, string, out bool), TypeExtension.GetFieldKey<T>(object, string, out bool), TypeExtension.GetFieldKey(object, Type, string, out bool), ObjectExtension.GetIntPtr(object), ObjectExtension.GetIntPtrInt(object), TypeExtension.GetPropertieFind(object, string, bool), TypeExtension.GetProperties(object), TypeExtension.GetPropertyKey(object, string, out bool), TypeExtension.GetPropertyKey<T>(object, string, out bool), TypeExtension.GetPropertyKey(object, Type, string, out bool), TypeExtension.GetValue(object, PropertyDescriptor), TypeExtension.GetValue(object, string, bool), TypeExtension.GetValue(object, string), ObjectExtension.Read<T>(object, object, int, int), ObjectExtension.Read<T>(object, int, object, int, int), DictionaryExtension.SetDictionary(object, IDictionary<string, object>), TypeExtension.SetFieldKey(object, string, object), TypeExtension.SetFieldKey<T>(object, string, object), TypeExtension.SetFieldKey(object, Type, string, object), TypeExtension.SetPropertyKey(object, string, object), TypeExtension.SetPropertyKey<T>(object, string, object), TypeExtension.SetPropertyKey(object, Type, string, object), TypeExtension.SetValue(object, PropertyDescriptor, object), TypeExtension.SetValue(object, string, object, bool), TypeExtension.SetValue(object, string, object), ObjectExtension.ToBase64String(object), ObjectExtension.ToBytes(object), ObjectExtension.ToBytes(object, out Type), DictionaryExtension.ToDictionary(object), DictionaryExtension.ToDictionary<T>(object), DictionaryExtension.ToIDictionary(object), DictionaryExtension.ToIDictionary<T>(object), ObjectExtension.ToJson(object), ObjectExtension.ToJson(object, JsonSerializerOptions), ObjectExtension.ToJsonWeb(object), ObjectExtension.ToJsonWeb(object, Action<JsonSerializerOptions>), ObjectExtension.ToTryVar<T>(object, T), ObjectExtension.ToVar<T>(object), ObjectExtension.ToVar(object, Type, bool), ObjectExtension.ToVar(object, string), ObjectExtension.ToXml(object)

Constructors

ActionHelper(MethodFlags)

获取指定类的方法

csharp
public ActionHelper(MethodFlags methodFlags)

Parameters

methodFlags MethodFlags

根据查找类型,获得相应方法

ActionHelper(Type, MethodFlags)

获取指定类的方法

csharp
public ActionHelper(Type type, MethodFlags methodFlags)

Parameters

type Type

指定获取类的

methodFlags MethodFlags

根据查找类型,获得相应方法

Properties

ActionMethods

当前类下面的所有方法

csharp
public List<ActionMethod<T>> ActionMethods { get; }

Property Value

List<ActionMethod<T>>

Count

可访问的方法数量

csharp
public int Count { get; }

Property Value

int

MethodFlag

当前类查询的方法条件

csharp
public MethodFlags MethodFlag { get; }

Property Value

MethodFlags

this[int]

根据下标获取指定方法

csharp
public ActionMethod<T> this[int i] { get; }

Property Value

ActionMethod<T>

Methods

GetActionMethodHelper(MethodFlags)

获取指定类的方法 等同于NEW

csharp
public static ActionHelper<T> GetActionMethodHelper(MethodFlags methodFlags)

Parameters

methodFlags MethodFlags

根据查找类型,获得相应方法

Returns

ActionHelper<T>

返回要获取的类下面的方法

GetActionMethodHelper(Type, MethodFlags)

获取指定类的方法 等同于NEW

csharp
public static ActionHelper<T> GetActionMethodHelper(Type type, MethodFlags methodFlags)

Parameters

type Type

指定获取类的

methodFlags MethodFlags

根据查找类型,获得相应方法

Returns

ActionHelper<T>

返回要获取的类下面的方法

GetEnumerator()

返回一个循环访问集合的枚举器。

csharp
public IEnumerator GetEnumerator()

Returns

IEnumerator

GetName(string)

根据方法名获取方法

csharp
public List<ActionMethod<T>> GetName(string name)

Parameters

name string

方法名称

Returns

List<ActionMethod<T>>

返回匹配到的方法

ToString()

返回方法信息缩写

csharp
public override string ToString()

Returns

string

基于Apache-2.0协议开源