Category

From GNUstepWiki
Jump to navigation Jump to search
The printable version is no longer supported and may have rendering errors. Please update your browser bookmarks and please use the default browser print function instead.

Categories let you extend the behaviour of a class without having to subclass it.

The obvious advantage is that all classes that inherit from the original class would automagically also inherit the additions of your category.

One disadvantage is that a category cannot add instance variables.