Creating a framework within an application?
I have a cocoa application which has certain subroutines / methods. So if I have a method like this:
- (void) 开发者_开发百科dummyMethod:(NSObject*)dummy
{
//code
}
Can I call it from an outside application providing I have the correct headers? I mean linking an application with another application. That method is an instance method by the way.
Sorry if that sounds absurd.
Have a look at ScriptingBridge framework that allows different applications to communicate with each other - may that's what you need.
You can not call method from another application (process). You can call methods of framework,static or dynamic library.
To call method on another application you have to use interprocess communication mechanism. In cocoa you can achieve this by using Distributed notification.
精彩评论