NSDictionary *attrs =
[[NSFileManager defaultManager]
attributesOfItemAtPath:@"file.txt"
error:nil];
//文件大小
NSNumber *fileSize = attrs[NSFileSize];
//修改日期
NSDate *modified =
attrs[NSFileModificationDate];
//创建日期
NSDate *created = attrs[NSFileCreationDate];