Skip to content

Instantly share code, notes, and snippets.

@jonathanpeppers
Created April 9, 2015 15:23
Show Gist options
  • Save jonathanpeppers/d335c8ef7de7c3f0accc to your computer and use it in GitHub Desktop.
Save jonathanpeppers/d335c8ef7de7c3f0accc to your computer and use it in GitHub Desktop.
ObjC Messaging
public static class Messaging
{
[DllImport("/usr/lib/libobjc.dylib", EntryPoint = "objc_msgSend")]
public static extern IntPtr Intptr_objc_msgSend(IntPtr receiver, IntPtr selector);
[DllImport("/usr/lib/libobjc.dylib", EntryPoint = "objc_msgSend")]
public static extern IntPtr IntPtr_objc_msgSend_byte(IntPtr receiver, IntPtr selector, byte arg1);
[DllImport("/usr/lib/libobjc.dylib", EntryPoint = "objc_msgSend")]
public static extern IntPtr IntPtr_objc_msgSend_Double(IntPtr receiver, IntPtr selector, double arg1);
//This list of methods goes on forever...
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment