开发者

NSDictionary with specific property of plist

开发者 https://www.devze.com 2022-12-27 20:20 出处:网络
I have a plist with key values. Each key represent a language, let\'s say \'it\' \'en\' ....ecc The value of each key is another key/value(=array) set. At startup I would like to create a dictionary

I have a plist with key values. Each key represent a language, let's say 'it' 'en' ....ecc

The value of each key is another key/value(=array) set. At startup I would like to create a dictionary by reading only a specific key. Let's say the locale of my iphone is 'it', then the init method would only parse it key, becaus开发者_C百科e the only way I found by now is to make a dictionary from the whole plist file and then another dictionary.

But I can imagine this can become quite cpu consuming if I add more language in the future.

thanks Leonardo


Why not localize the plist file, thus having multiple plists?

0

精彩评论

暂无评论...
验证码 换一张
取 消