Re: Converting a .strings text file to a NSArray or NSDictionary
Re: Converting a .strings text file to a NSArray or NSDictionary
- Subject: Re: Converting a .strings text file to a NSArray or NSDictionary
- From: Alexander Spohr <email@hidden>
- Date: Thu, 28 Sep 2006 09:31:00 +0200
Am 27.09.2006 um 21:16 schrieb Chuck Hill:
I'll be using it for 3 type of thing:
-get a complete NSDictionary or NSArray from a .strings
NSPropertyListSerialization already does that.
a .strings file is not a valid plist. so it does not.
you have to convert them to a plist (add the {}, as you already told
xavier) before NSPropertyListSerialization can read them.
-get a partial NSDictionary or NSArray from a .strings based on a
qualifer like "key contains xxxxx" (easy if I can get a complete
NSArray)
It won't do that.
why not? do you know what xavier needs that for?
-create a reverse NSDictionary/Array from value to key (I know
I'll have to ensure the uniqueness of the value on my own if I do
that)
What would be the best way to approach this? and maybe some
pointer for the following steps;)
I'd still use NSPropertyListSerialization and use another class to
get the last two points from above.
agreed, i never use .strings-files because a plist is more dynamic to
use.
xavier, just forget those .strings and convert them all to dictionary-
plists.
you could even use xml in those files.
see http://www.apple.com/DTDs/PropertyList-1.0.dtd
atze
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden