다음을 통해 공유


ISqlActivationService.CreateInstance<T> 메서드 (Type, BindingFlags, Binder, array<Object , CultureInfo)

Creates an instance of the specified type using the constructor that best matches the specified parameters.

네임스페이스:  Microsoft.SqlServer.Management
어셈블리:  SqlWorkbench.Interfaces(SqlWorkbench.Interfaces.dll)

구문

‘선언
Function CreateInstance(Of T) ( _
    type As Type, _
    bindingAttr As BindingFlags, _
    binder As Binder, _
    args As Object(), _
    culture As CultureInfo _
) As T
‘사용 방법
Dim instance As ISqlActivationService 
Dim type As Type 
Dim bindingAttr As BindingFlags 
Dim binder As Binder 
Dim args As Object()
Dim culture As CultureInfo 
Dim returnValue As T

returnValue = instance.CreateInstance(type, _
    bindingAttr, binder, args, culture)
T CreateInstance<T>(
    Type type,
    BindingFlags bindingAttr,
    Binder binder,
    Object[] args,
    CultureInfo culture
)
generic<typename T>
T CreateInstance(
    Type^ type, 
    BindingFlags bindingAttr, 
    Binder^ binder, 
    array<Object^>^ args, 
    CultureInfo^ culture
)
abstract CreateInstance : 
        type:Type * 
        bindingAttr:BindingFlags * 
        binder:Binder * 
        args:Object[] * 
        culture:CultureInfo -> 'T 
JScript는 제네릭 형식 및 메서드를 지원하지 않습니다.

유형 매개 변수

  • T

매개 변수

  • type
    유형: System.Type
    The type of object to create.
  • bindingAttr
    유형: System.Reflection.BindingFlags
    A combination of zero or more bit flags that affect the search for the type constructor. If bindingAttr is zero, a case-sensitive search for public constructors is conducted.
  • binder
    유형: System.Reflection.Binder
    An object that uses bindingAttr and args to seek and identify the type constructor.
  • args
    유형: array<System.Object[]
    An array of arguments that match in number, order, and type the parameters of the constructor to invoke.
  • culture
    유형: System.Globalization.CultureInfo
    Culture-specific information that governs the coercion of args to the formal types declared for the type constructor.

반환 값

유형: T
A reference to the newly created object.

참고 항목

참조

ISqlActivationService 인터페이스

CreateInstance 오버로드

Microsoft.SqlServer.Management 네임스페이스