Objective C BitConverter Equivalent
Posted
by user352891
on Stack Overflow
See other posts from Stack Overflow
or by user352891
Published on 2010-05-28T12:41:41Z
Indexed on
2010/05/28
13:01 UTC
Read the original article
Hit count: 425
Hi there, I'm wondering if there is an Objective C equivalent to .Net's BitConverter.GetBytes() method.
For example, in C#, I can write something like this:
byte[] lengthPrefix = BitConverter.GetBytes(message.length);
What would the equivalent be in Objective C?
Some example code would be greatly appreciated.
Thanks in advance.
© Stack Overflow or respective owner