[Solved] how to define delegate method as property in class category? [closed]


Your terms are all confused. A category is not a superclass or a subclass. A category adds methods to an existing class.

A method is not a property, so “defining a delegate method property” does not make sense.

You can’t add new instance variables to an object in a category, so you can’t add normal properties at all. You can create properties with custom getters/setters that don’t use instance variables, or that use existing instance variables (for example if you had a “Person” class that had a “firstName” property and a “lastName” property you could create a new read-only property “fullName” that concatenated the first and last name and returned the result.)

4

solved how to define delegate method as property in class category? [closed]