如何解决 fileAttributesAtPath 警告问题? [英] How to resolve issues with fileAttributesAtPath warning?
本文介绍了如何解决 fileAttributesAtPath 警告问题?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
现在我使用这个代码:
NSDictionary* attr = [[NSFileManager defaultManager] fileAttributesAtPath:file traverseLink:YES];
并得到警告:
'fileAttributesAtPath:traverseLink:' is deprecated
谁知道用什么代替?
谢谢!
推荐答案
使用 attributesOfItemAtPath:error:
代替.
这篇关于如何解决 fileAttributesAtPath 警告问题?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文