Επεξεργασία

Κοινή χρήση μέσω


SignatureHelper.GetMethodSigHelper Method

Definition

Returns a signature helper for a method.

Overloads

GetMethodSigHelper(Module, Type, Type[])

Returns a signature helper for a method with a standard calling convention, given the method's module, return type, and argument types.

GetMethodSigHelper(Module, CallingConvention, Type)

Returns a signature helper for a method given the method's module, unmanaged calling convention, and return type.

GetMethodSigHelper(CallingConvention, Type)

Returns a signature helper for a method given the method's unmanaged calling convention and return type.

GetMethodSigHelper(CallingConventions, Type)

Returns a signature helper for a method given the method's calling convention and return type.

GetMethodSigHelper(Module, CallingConventions, Type)

Returns a signature helper for a method given the method's module, calling convention, and return type.

GetMethodSigHelper(Module, Type, Type[])

Source:
SignatureHelper.cs
Source:
SignatureHelper.cs
Source:
SignatureHelper.cs

Returns a signature helper for a method with a standard calling convention, given the method's module, return type, and argument types.

public:
 static System::Reflection::Emit::SignatureHelper ^ GetMethodSigHelper(System::Reflection::Module ^ mod, Type ^ returnType, cli::array <Type ^> ^ parameterTypes);
public static System.Reflection.Emit.SignatureHelper GetMethodSigHelper (System.Reflection.Module? mod, Type? returnType, Type[]? parameterTypes);
public static System.Reflection.Emit.SignatureHelper GetMethodSigHelper (System.Reflection.Module mod, Type returnType, Type[] parameterTypes);
static member GetMethodSigHelper : System.Reflection.Module * Type * Type[] -> System.Reflection.Emit.SignatureHelper
Public Shared Function GetMethodSigHelper (mod As Module, returnType As Type, parameterTypes As Type()) As SignatureHelper

Parameters

mod
Module

The ModuleBuilder that contains the method for which the SignatureHelper is requested.

returnType
Type

The return type of the method, or null for a void return type (Sub procedure in Visual Basic).

parameterTypes
Type[]

The types of the arguments of the method, or null if the method has no arguments.

Returns

The SignatureHelper object for a method.

Exceptions

mod is null.

-or-

An element of parameterTypes is null.

Remarks

This overload creates a signature with a standard calling convention.

To create a method signature with custom modifiers, use the GetMethodSigHelper(Module, CallingConventions, Type) method overload and then use the AddArgument(Type, Type[], Type[]) or AddArguments(Type[], Type[][], Type[][]) method overloads to add arguments with custom modifiers.

Applies to

GetMethodSigHelper(Module, CallingConvention, Type)

Returns a signature helper for a method given the method's module, unmanaged calling convention, and return type.

public:
 static System::Reflection::Emit::SignatureHelper ^ GetMethodSigHelper(System::Reflection::Module ^ mod, System::Runtime::InteropServices::CallingConvention unmanagedCallConv, Type ^ returnType);
public static System.Reflection.Emit.SignatureHelper GetMethodSigHelper (System.Reflection.Module mod, System.Runtime.InteropServices.CallingConvention unmanagedCallConv, Type returnType);
static member GetMethodSigHelper : System.Reflection.Module * System.Runtime.InteropServices.CallingConvention * Type -> System.Reflection.Emit.SignatureHelper
Public Shared Function GetMethodSigHelper (mod As Module, unmanagedCallConv As CallingConvention, returnType As Type) As SignatureHelper

Parameters

mod
Module

The ModuleBuilder that contains the method for which the SignatureHelper is requested.

unmanagedCallConv
CallingConvention

The unmanaged calling convention of the method.

returnType
Type

The return type of the method, or null for a void return type (Sub procedure in Visual Basic).

Returns

The SignatureHelper object for a method.

Exceptions

mod is null.

mod is not a ModuleBuilder.

-or-

unmanagedCallConv is an unknown unmanaged calling convention.

Applies to

GetMethodSigHelper(CallingConvention, Type)

Returns a signature helper for a method given the method's unmanaged calling convention and return type.

public:
 static System::Reflection::Emit::SignatureHelper ^ GetMethodSigHelper(System::Runtime::InteropServices::CallingConvention unmanagedCallingConvention, Type ^ returnType);
public static System.Reflection.Emit.SignatureHelper GetMethodSigHelper (System.Runtime.InteropServices.CallingConvention unmanagedCallingConvention, Type returnType);
static member GetMethodSigHelper : System.Runtime.InteropServices.CallingConvention * Type -> System.Reflection.Emit.SignatureHelper
Public Shared Function GetMethodSigHelper (unmanagedCallingConvention As CallingConvention, returnType As Type) As SignatureHelper

Parameters

unmanagedCallingConvention
CallingConvention

The unmanaged calling convention of the method.

returnType
Type

The return type of the method, or null for a void return type (Sub procedure in Visual Basic).

Returns

The SignatureHelper object for a method.

Exceptions

unmanagedCallConv is an unknown unmanaged calling convention.

Applies to

GetMethodSigHelper(CallingConventions, Type)

Source:
SignatureHelper.cs
Source:
SignatureHelper.cs
Source:
SignatureHelper.cs

Returns a signature helper for a method given the method's calling convention and return type.

public:
 static System::Reflection::Emit::SignatureHelper ^ GetMethodSigHelper(System::Reflection::CallingConventions callingConvention, Type ^ returnType);
public static System.Reflection.Emit.SignatureHelper GetMethodSigHelper (System.Reflection.CallingConventions callingConvention, Type? returnType);
public static System.Reflection.Emit.SignatureHelper GetMethodSigHelper (System.Reflection.CallingConventions callingConvention, Type returnType);
static member GetMethodSigHelper : System.Reflection.CallingConventions * Type -> System.Reflection.Emit.SignatureHelper
Public Shared Function GetMethodSigHelper (callingConvention As CallingConventions, returnType As Type) As SignatureHelper

Parameters

callingConvention
CallingConventions

The calling convention of the method.

returnType
Type

The return type of the method, or null for a void return type (Sub procedure in Visual Basic).

Returns

The SignatureHelper object for a method.

Applies to

GetMethodSigHelper(Module, CallingConventions, Type)

Source:
SignatureHelper.cs
Source:
SignatureHelper.cs
Source:
SignatureHelper.cs

Returns a signature helper for a method given the method's module, calling convention, and return type.

public:
 static System::Reflection::Emit::SignatureHelper ^ GetMethodSigHelper(System::Reflection::Module ^ mod, System::Reflection::CallingConventions callingConvention, Type ^ returnType);
public static System.Reflection.Emit.SignatureHelper GetMethodSigHelper (System.Reflection.Module? mod, System.Reflection.CallingConventions callingConvention, Type? returnType);
public static System.Reflection.Emit.SignatureHelper GetMethodSigHelper (System.Reflection.Module mod, System.Reflection.CallingConventions callingConvention, Type returnType);
static member GetMethodSigHelper : System.Reflection.Module * System.Reflection.CallingConventions * Type -> System.Reflection.Emit.SignatureHelper
Public Shared Function GetMethodSigHelper (mod As Module, callingConvention As CallingConventions, returnType As Type) As SignatureHelper

Parameters

mod
Module

The ModuleBuilder that contains the method for which the SignatureHelper is requested.

callingConvention
CallingConventions

The calling convention of the method.

returnType
Type

The return type of the method, or null for a void return type (Sub procedure in Visual Basic).

Returns

The SignatureHelper object for a method.

Exceptions

mod is null.

Applies to