Implementing Services
Cocoa offers several facilities to help developers take advantage of services. The Services menu is automatically populated by the application object. Existing responder subclasses, such as the NSApplication, NSWindow, and many controls are already set up to make use of services. Custom controls need to implement a few special methods to take advantage of services. Also, a function call is available for invoking services programmatically. To publish a service, a service provider object is created and changes are made in the application’s Info.plist.
Using Services
Several steps are required to take advantage of services in custom NSResponder subclasses. First, each object that can respond to a service must register the ...
Get Cocoa® Programming now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.