我有一个从 Web 服务返回的数组,其中包含字节值(非二进制格式,即 0-255)。它们代表缩略图。我想需要从这些值创建一个 NSData 对象。我该怎么做?
I have an array returned from a web service containing byte values (non binary format, i.e. 0-255). These represent a thumbnail image. I want need to create an NSData object from these values. How can I do this?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
+ (id)dataWithBytes:(const void *)字节长度:(NSUInteger)长度是你的朋友:
+ (id)dataWithBytes:(const void *)bytes length:(NSUInteger)length is your friend: