What is “category” in Objective-C?

前端 未结 2 1263
误落风尘
误落风尘 2020-12-14 03:01

Possible Duplicate:
How does a category work in Objective-C?

I am just getting started with Objective-C and w

相关标签:
2条回答
  • 2020-12-14 03:12

    There is a section in the Objective-C 2.0 programming Language document about Categories and Extensions.

    As you are just getting started it's a good doc to have on hand to look things up.

    There is also a section on Categories in the Cocoa Core Competencies document, which is easier to get started with, and also has a lot of useful information for the beginner.

    0 讨论(0)
  • 2020-12-14 03:18

    A category allows you to add methods to an existing class—even to one for which you do not have the source.

    Categories are a powerful feature that allows you to extend the functionality of existing classes without subclassing

    Check the apple doc for the Category in Objective-C

    0 讨论(0)
提交回复
热议问题