• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Quick way to convert hex string represented in ASCII to binary?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Quick way to convert hex string represented in ASCII to binary?


  • Subject: Re: Quick way to convert hex string represented in ASCII to binary?
  • From: Andreas Mayer <email@hidden>
  • Date: Sat, 29 Jul 2006 10:03:44 +0200


Am 29.07.2006 um 09:20 Uhr schrieb Ken Tozier:

and then getting a description of these objects for storage.

'-description' is *not* meant for storage!

Try NSPropertyListSerialization instead.
This should give you an XML representation of your inputData object:

NSData *xmlData = [NSPropertyListSerialization dataFromPropertyList:inputData format:NSPropertyListXMLFormat_v1_0 errorDescription:NULL];

To get the data back:

NSData *outputData = [NSPropertyListSerialization propertyListFromData:xmlData mutabilityOption:NSPropertyListImmutable format:NSPropertyListXMLFormat_v1_0 errorDescription:NULL];


(Code untested; written in Mail)


Andreas _______________________________________________ Do not post admin requests to the list. They will be ignored. Cocoa-dev mailing list (email@hidden) Help/Unsubscribe/Update your Subscription: This email sent to email@hidden
References: 
 >Quick way to convert hex string represented in ASCII to binary? (From: Ken Tozier <email@hidden>)

  • Prev by Date: Quick way to convert hex string represented in ASCII to binary?
  • Next by Date: Fwd: Quick way to convert hex string represented in ASCII to binary?
  • Previous by thread: Quick way to convert hex string represented in ASCII to binary?
  • Next by thread: Fwd: Quick way to convert hex string represented in ASCII to binary?
  • Index(es):
    • Date
    • Thread