如果我枚举一个数组,我会得到
<myArray: 0x71b26b0>
<myArray: 0x71b2830>
<myArray: 0x71b2900>
我可以认为 myData 在列出的指针后面,但是如果我想明确查看(记录)每个地址的内容,该怎么做?
我试过 &myData 无济于事
--
为了uchuugaka的利益:
-(void)loadObservedItems{
NSString *path = [self observationFilePath];
if ([[NSFileManager defaultManager] fileExistsAtPath:path]) {
NSData *data = [[NSData alloc] initWithContentsOfFile:path];
NSKeyedUnarchiver *unarchiver = [[NSKeyedUnarchiver alloc] initForReadingWithData:data];
myArray = [unarchiver decodeObjectForKey:@"ObserveKey"];
[unarchiver finishDecoding];
} else {
myArray = [[NSMutableArray alloc] initWithCapacity:10];
}
NSLog(@" %@",myArray);
}