ScriptObject.GetMethod Метод
Определение
Получает метод с указанным именем.Gets a method that has a specified name.
Перегрузки
GetMethod(String, BindingFlags) |
Получает метод с заданным именем.Gets a method that has the specified name. |
GetMethod(String, BindingFlags, Binder, Type[], ParameterModifier[]) |
Получает метод с заданным именем, используя указанные критерии выбора.Gets a method that has the specified name by using the specified selection criteria. |
GetMethod(String, BindingFlags)
Получает метод с заданным именем.Gets a method that has the specified name.
public:
virtual System::Reflection::MethodInfo ^ GetMethod(System::String ^ name, System::Reflection::BindingFlags bindingAttr);
public System.Reflection.MethodInfo GetMethod (string name, System.Reflection.BindingFlags bindingAttr);
abstract member GetMethod : string * System.Reflection.BindingFlags -> System.Reflection.MethodInfo
override this.GetMethod : string * System.Reflection.BindingFlags -> System.Reflection.MethodInfo
Public Function GetMethod (name As String, bindingAttr As BindingFlags) As MethodInfo
Параметры
- name
- String
Имя метода, который необходимо получить.The name of the method to get.
- bindingAttr
- BindingFlags
Битовая комбинация значений перечисления, задающая способ поиска членов путем отражения.A bitwise combination of the enumeration values that specifies how the search for members is conducted by reflection.
Возвраты
Метод, для которого задан параметр name
, или значение NULL, если объект не содержит такой метод.A method that has the specified name
, or null if the script object does not contain the method.
Реализации
Дополнительно
GetMethod(String, BindingFlags, Binder, Type[], ParameterModifier[])
Получает метод с заданным именем, используя указанные критерии выбора.Gets a method that has the specified name by using the specified selection criteria.
public:
virtual System::Reflection::MethodInfo ^ GetMethod(System::String ^ name, System::Reflection::BindingFlags bindingAttr, System::Reflection::Binder ^ binder, cli::array <Type ^> ^ types, cli::array <System::Reflection::ParameterModifier> ^ modifiers);
public System.Reflection.MethodInfo GetMethod (string name, System.Reflection.BindingFlags bindingAttr, System.Reflection.Binder binder, Type[] types, System.Reflection.ParameterModifier[] modifiers);
abstract member GetMethod : string * System.Reflection.BindingFlags * System.Reflection.Binder * Type[] * System.Reflection.ParameterModifier[] -> System.Reflection.MethodInfo
override this.GetMethod : string * System.Reflection.BindingFlags * System.Reflection.Binder * Type[] * System.Reflection.ParameterModifier[] -> System.Reflection.MethodInfo
Параметры
- name
- String
Имя искомого метода.The name of the method to search for.
- bindingAttr
- BindingFlags
Битовая комбинация значений перечисления, задающая способ поиска членов путем отражения.A bitwise combination of the enumeration values that specifies how the search for members is conducted by reflection.
- binder
- Binder
Объект, выполняющий преобразование фактического типа аргумента в формальный тип аргумента.An object that performs type conversion from actual argument type to formal argument type.
- types
- Type[]
Типы параметров, используемые для нахождения соответствующего метода.The parameter types that are used to locate a matching method.
- modifiers
- ParameterModifier[]
Массив модификаторов параметров, позволяющий привязке работать с сигнатурами параметров, в которых были изменены типы.An array of parameter modifiers that enable binding to work with parameter signatures in which the types have been modified.
Возвраты
Метод, для которого задан параметр name
, или значение NULL, если объект не содержит такой метод.A method that has the specified name
, or null if the script object does not contain the method.