Я установил Realm
со стручками, и все соответствует.У меня даже есть подкласс для двух RLMObjects
, которые будут использоваться для сохранения объектов моего пользовательского класса в пространстве по умолчанию для областей.
@interface RLNotification : RLMObject
- (instancetype)initWithNotification:(KANotification *)notification;
@property NSString *docID, *userID, *username;
@property NSInteger time, type;
@end
@interface RLProfilePicture : RLMObject
- (instancetype)initWithImage:(UIImage *)image;
@property (nonatomic) NSString *userID;
@property (nonatomic) NSData *imageData;
@property NSInteger timeLastUpdated;
@end
ПРОБЛЕМА
Когда я иду использоватьхотя, в любом классе, например:
NSLog(@"test: %@", [RLNotification allObjects]);
RLNotification *noti = RLNotification.new;
noti.userID = @"hey";
noti.username = @"nope!";
[RLMRealm.defaultRealm addObject:noti];
NSLog(@"test2: %@", [RLNotification allObjects]);
Я получаю это предупреждение ...
Undefined symbols for architecture arm64:
"_OBJC_CLASS_$_RLNotification", referenced from:
objc-class-ref in AnyClassName.o
ld: symbol(s) not found for architecture arm64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
Что я делаю на земле?неправильно / надо менять? ....