I trying to understand class hierarchy. What are the sub classes of NSObject
. Is there any graphical representation of the hierarchy?

- 14,195
- 22
- 56
- 52

- 209
- 1
- 2
- 9
-
The set of potential `NSObject` subclasses is not finite - you can add custom ones as much as you want. Are you asking for a diagram for the Cocoa Touch classes? – Georg Fritzsche Jul 24 '10 at 00:08
5 Answers
You can explore the hierarchy in the hierarchical view of the Symbols navigator in a Xcode project. Be sure to de-select the document icon below to display all symbols and not just those defined in your project.

- 3,597
- 4
- 27
- 31
Here is a diagram explaining about NSObject class references but its not the one. There are so many things to know about NSObject. On the other hand its not finite, means you can add your custom classes also.
Hope this helped.
Thanks.

- 6,500
- 4
- 28
- 37
The class browser under Project>Class Browser
will display a hierarchal view of all the classes. There are a lot of them.

- 64,370
- 15
- 118
- 145
-
2Where do u find this Project>Class Browser ? Can u please show the exact path where we can check the hierarchy of the classes? – Pradeep Reddy Kypa Apr 20 '12 at 10:00
You can use Xcode
Show the Navigator -> Show the Symbol Navigator
//or
Command + 3
Hierarchical -> Classes -> NSObject
You can use Filter
field or Navigate -> Reveal in Symbol Navigator
. Sometimes Filter
field is buggy that is why you should repeat actions

- 29,217
- 8
- 193
- 205
NSObject is the root class of most Objective-C class hierarchies, from which subclasses inherit a basic interface to the runtime system and the ability to behave as Objective-C objects.
https://developer.apple.com/documentation/objectivec/nsobject
I found this this diagram on Google showing the inheritance relationships.
A comprehensive blog is written by Chris (Just read Chapter#12):
https://codewithchris.com/swift-tutorial-complete/#uikit Chapter 12

- 401
- 6
- 10