Re: Compiler error - method not found on object which conforms to protocol


Sak Wathanasin
 



On 27 Mar 2021, at 01:41, Sandor Szatmari <admin.szatmari.net@...> wrote:
@protocol dataSrcProto
-(NSUinteger)serverPort;
@end

serverPort isn't a property, so you have to use

[self.dataSource serverPort];

If you want it to be a property, make it so

@protocol dataSrcProto
@property (readonly) NSUinteger serverPort;
@end

Regards
Sak

Join cocoa@apple-dev.groups.io to automatically receive all group messages.