what is protocol? . The use of protocol?

Answer Posted / babu

Protocol is the named list of independent methods. Protocol declaration having two sections

@required

In this section you will declare all required methods. If a class adopting this protocol should implement all required methods

@optional

In this section you will declare all optional methods.

Eg: @protocol myViewProtocol

@required

-(void)passDataToNextClass : (NSString*)myViewName

@optional

-(void)passDataToNextClass : (NSString*)myViewName

@end

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Differentiate 'app id' from 'bundle id'.

468


What is singleton class in ios?

413


How do you create a fetched property?

442


Explain about the applications that can be used with iphone ?

444


What is suspended state in ios?

467






What is iphone reference library?

468


Functionality of accelerometer of an iphone

487


What is delegation pattern in ios?

418


Define encoding or serialization??

441


Describe what “app thinning” means ?

492


Is xcode a framework?

480


What is delegate in ios objective c?

477


Will iphone 6 get ios 13?

441


What is concurrency in ios?

420


Explain the steps involved in submitting the App to App-Store in iOS operating system?

490