What is class extension? Why do we require them?



What is class extension? Why do we require them?..

Answer / Gaurav Prakash

Class extensions in Objective-C are a way to add methods and properties to existing classes without subclassing. This allows for code organization and prevents conflicts with other extensions or the original class implementation. You might need them when you want to extend the functionality of an existing class without modifying its source code.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More Objective-C Interview Questions

What are the three main types of property?

1 Answers  


Can we create dynamic classes in objective c?

1 Answers  


What is the difference between nsstring and string?

1 Answers  


Is closure a function?

1 Answers  


What is objective c used for?

1 Answers  


What are class b properties?

1 Answers  


What is 'protocol' on objective c?

1 Answers  


What is a process and thread?

1 Answers  


Can a protocol have properties?

1 Answers  


What are nsautoreleasepool and how can we use them?

1 Answers  


What is umbrella header?

1 Answers  


What is the latest version of objective-c?

1 Answers  


Categories