Runtime.ConnectMethod Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Overloads
ConnectMethod(MethodInfo, Selector) |
This call allows the specified method in this method to respond to message invocations on the specified selector. |
ConnectMethod(Type, MethodInfo, ExportAttribute) |
This call allows the specified method in this method to respond to message invocations on the specified selector. |
ConnectMethod(Type, MethodInfo, Selector) |
This call allows the specified method in this method to respond to message invocations on the specified selector. |
ConnectMethod(MethodInfo, Selector)
This call allows the specified method in this method to respond to message invocations on the specified selector.
public static void ConnectMethod (System.Reflection.MethodInfo method, ObjCRuntime.Selector selector);
static member ConnectMethod : System.Reflection.MethodInfo * ObjCRuntime.Selector -> unit
Parameters
- method
- MethodInfo
Method that will be called when Objective-C sends a message to the specified selector.
- selector
- Selector
Selector to connect to.
Remarks
The method must be declared on an NSObject-derived class.
Developers can use this method to dynamically reconfigure which methods on a class should respond to which Objective-C selectors.
Applies to
ConnectMethod(Type, MethodInfo, ExportAttribute)
This call allows the specified method in this method to respond to message invocations on the specified selector.
public static void ConnectMethod (Type type, System.Reflection.MethodInfo method, Foundation.ExportAttribute export);
static member ConnectMethod : Type * System.Reflection.MethodInfo * Foundation.ExportAttribute -> unit
Parameters
- type
- Type
Connect to the selector on this type.
- method
- MethodInfo
Method that will be called when Objective-C sends a message to the specified selector.
- export
- ExportAttribute
An export attribute that specifies the selector to connect to.
Remarks
The method must be declared on an NSObject-derived class.
Developers can use this method to dynamically reconfigure which methods on a class should respond to which Objective-C selectors.
Applies to
ConnectMethod(Type, MethodInfo, Selector)
This call allows the specified method in this method to respond to message invocations on the specified selector.
public static void ConnectMethod (Type type, System.Reflection.MethodInfo method, ObjCRuntime.Selector selector);
static member ConnectMethod : Type * System.Reflection.MethodInfo * ObjCRuntime.Selector -> unit
Parameters
- type
- Type
Connect to the selector on this type.
- method
- MethodInfo
Method that will be called when Objective-C sends a message to the specified selector.
- selector
- Selector
Selector to connect to.
Remarks
The method must be declared on an NSObject-derived class.
Developers can use this method to dynamically reconfigure which methods on a class should respond to which Objective-C selectors.