I am trying to implement the below protocol in Swift which is written in objective-c however I am still receiving compiler errors saying that the class does not conform to the protocol. What am I doing wrong? I have tried setting getters and setters and applying the @NSCopying flag but to no avail.
#import <Foundation/Foundation.h>
@protocol AIConfiguration <NSObject>
@property(nonatomic, copy) NSURL *baseURL;
@property(nonatomic, copy) NSString *clientAccessToken;
@property(nonatomic, copy) NSString *subscriptionKey;
@end
Here is my implementation
class AIMyConfiguration : NSObject, AIConfiguration {
var baseURL : NSURL
var clientAccessToken : NSString
var subscriptionKey : NSString
override init() {
super.init()
}
}
Thank you