A symbol naming the class to define.
A symbol naming a superclass.
A slot description as used by
A class option as used by
Each superclass-name argument specifies a direct superclass of the new class, which can be another Objective-C implementation class or any other
standard-class, provided that standard-objc-object is included somewhere in the overall class precedence list. The class standard-objc-object is the default superclass if no others are specified.
This option makes the Objective-C class name used for instances of name be the string objc-class-name. If none of the classes in the class precedence list of name have a
:objc-class-name option then no Objective-C object is created.
This option makes the Objective-C superclass name of the Objective-C class defined by the
:objc-class-name option be the string objc-superclass-name. If omitted, the objc-superclass-name defaults to the objc-class-name of the first class in the class precedence list that specifies such a name or to
"NSObject" if no such class is found. It is an error to specify a objc-superclass-name which is different from the one that would be inherited from a superclass.
This option allows Objective-C formal protocols to be registered as being implemented by the class. Each protocol-name should be a string naming a previously defined formal protocol (see define-objc-protocol). The class will automatically implement all protocols specified by its superclasses.
If name is not referenced at runtime and you deliver an application relying on your class, then you need to arrange for name to be retained during delivery. This can be achieved with the Delivery keyword
:keep-symbols (see the
LispWorks Delivery User Guide
), but a more modular approach is shown in the example below.
If your Lisp code does not actually reference
foo at runtime then you must take care to retain your class during Delivery. The best way to achieve this is to keep its name on the plist of some other symbol like this:
(setf (get 'make-a-foo 'owner-class) 'foo)
LispWorks Objective-C and Cocoa Interface User Guide and Reference Manual - 15 Feb 2015