对于某种基于套接字的应用程序,我只需要1个字节,我找不到创建它的方法。
unsigned char mydata = 3;
[NSMutableData dataWithBytes:&mydata length:sizeof(mydata)];
NSData reference , unsigned char
is used to save 1 byte.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.