我在plist文件(iOS)中存储一些字典,随后加密。 读取文件内容和解密他们之后,我返回文件的XML内容的字符串:plist XML字符串到NSMutableDictionary
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>password</key>
<string>apassword</string>
<key>username</key>
<string>ausername</string>
</dict>
</plist>
我知道的方法:dictionaryWithContentsOfFile:(NSString *)
和dictionaryWithContentsOfFile:(NSURL *)
创建字典从这种类型的数据,但我惊讶没有这样的dictionaryWithXML:(NSString *)
写这个数据到一个文件然后阅读它的东西,我试图避免,因为它只是过度,是否有任何明显的解决方法,我失踪?
[解析的plist(NSString的)转换成的NSDictionary](http://stackoverflow.com/questions/1072308/parse-plist-nsstring-into-nsdictionary) – ismail 2013-02-28 16:32:04