Adds an observer to a notification center.
cocoa
add-observer target selector &key name object center
target⇩ |
A pointer to an Objective-C foreign object. |
selector⇩ |
A selector of type sel. |
name⇩ |
A string or nil . |
object⇩ |
A pointer to an Objective-C foreign object or nil . |
center⇩ |
A notification center. |
The function add-observer
calls the Objective-C instance method "addObserver:selector:name:object:"
of center to add target as an observer for selector with the given name and object, which both default to nil
.
If center is omitted then it defaults to the default notification center.
LispWorks Objective-C and Cocoa Interface User Guide and Reference Manual - 01 Dec 2021 19:38:33