tags:

views:

39

answers:

2

What does "conform to" means in IPhone Development? This word is extensively used but I can't find a satisfactory definition of it.

Let's say If we have 3 classes - A,B & C

If A inherits B & If A conforms to C

What does that means?

Also, Why does most classes,protocols conforms to NSObject.

A: 

Means class has the necessary methods to make it compliant to the given protocol . you can read about objective c protocols here

Surya
+1  A: 

In your example, C would have to be a protocol. Protocols are just a lists of method signatures.

If A conforms to C, it means it implements all the methods listed in the protocol (ie method bodies are provided for each of the method signatures defined in the protocol.)

Since A also inherits from B, A does does not have to explicitly implement methods that B has already implemented.

Tom
Thanks for the lucid explanation. Much Appreciated.Thanks Anuj
Anuj