ManagedToNativeComInteropStubAttribute(Type, String) 构造函数
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
使用指定的类类型和方法名称初始化类的新实例 ManagedToNativeComInteropStubAttribute 。
public:
ManagedToNativeComInteropStubAttribute(Type ^ classType, System::String ^ methodName);
public ManagedToNativeComInteropStubAttribute(Type classType, string methodName);
new System.Runtime.InteropServices.ManagedToNativeComInteropStubAttribute : Type * string -> System.Runtime.InteropServices.ManagedToNativeComInteropStubAttribute
Public Sub New (classType As Type, methodName As String)
参数
- classType
- Type
包含所需存根方法的类。
- methodName
- String
存根方法的名称。
例外
包含托管互操作方法的接口无法访问存根方法,因为存根方法具有私有或受保护的辅助功能,或者由于安全问题。