How to check the library?

I was provided with a .a library with very poor documentation. Is there a way to test public types, methods, and properties?

+7
source share
1 answer

There are several options: the one I prefer is otool;

From his man page for possible options:

-o Display the contents of the __OBJC segment used by the Objective-C time system.

Example:

otool -o libRaptureXML_universal.a

[...] contents of (__DATA,__objc_classlist) section 00006fe0 0x65d4 isa 0x65e8 superclass 0x0 cache 0x0 vtable 0x0 data 0x6fb8 (struct class_ro_t *) flags 0x0 instanceStart 4 instanceSize 12 ivarLayout 0x0 name 0x6b84 RXMLElement baseMethods 0x6e08 (struct method_list_t *) entsize 12 count 27 name 0x66bb initFromXMLString:encoding: types 0x6b90 @ 16@0 : 4@8I12 imp 0x1 name 0x66e3 initFromXMLFile: types 0x6b9d @ 12@0 : 4@8 imp 0xd5 name 0x66f4 initFromXMLFile:fileExtension: types 0x6ba7 @ 16@0 : 4@8 @12 imp 0x209 name 0x6713 initFromURL: types 0x6b9d @ 12@0 : 4@8 imp 0x335 name 0x6720 initFromXMLData: types 0x6b9d @ 12@0 : 4@8 imp 0x411 name 0x6731 initFromXMLNode: [...] 
+7
source

All Articles