Converting long value to unichar* in objective-c

Posted by conmulligan on Stack Overflow See other posts from Stack Overflow or by conmulligan
Published on 2010-04-21T01:42:37Z Indexed on 2010/04/21 1:43 UTC
Read the original article Hit count: 814

Filed under:
|
|
|

I'm storing large unicode characters (0x10000+) as long types which eventually need to be converted to NSStrings. Smaller unicode characters can be created as a unichar, and an NSString can be created using

[NSString stringWithCharacters:(const unichar *)characters length:(NSUInteger)length]

So, I imagine the best way to get an NSString from the unicode long value would be to first get a unichar* from the long value. Any idea on how I might go about doing this?

© Stack Overflow or respective owner

Related posts about unichar

Related posts about long