美文网首页
Objective-C 类型编码

Objective-C 类型编码

作者: May_Dobin | 来源:发表于2019-02-20 11:23 被阅读2次

使用以下方法时type参数释义:

+ (NSValue *)valueWithBytes:(const void *)value objCType:(const char *)type; 
+ (nullable NSMethodSignature *)signatureWithObjCTypes:(const char *)types;

例如

[NSMethodSignature signatureWithObjCTypes:"v@?"];

一.Objective-C Type Encodings

Objective-C Type Encodings

二.Objective-C Method Encodings

Objective-C Method Encodings

参考文档:https://developer.apple.com/library/archive/documentation/Cocoa/Conceptual/ObjCRuntimeGuide/Articles/ocrtTypeEncodings.html#//apple_ref/doc/uid/TP40008048-CH100-SW1

相关文章

网友评论

      本文标题:Objective-C 类型编码

      本文链接:https://www.haomeiwen.com/subject/zmbcyqtx.html