1. Is it possible to put more time-consuming operations in the notification Center?
Notice in which line Cheng, then the processing of the notification event is carried out in the same thread;
if the asynchronous line Cheng the notification, then you can perform more time-consuming operations;if the Cheng of the main line is notified, then it is not possible to perform more time-consuming operations. What is the difference between a 2.Foundation object and a Corefoundation object? when the foundation object is OC;the Corefoundation object is C;The Foundation object and the Corefoundation object can be converted to each other, and the conversion between data types· ARC: __bridge_retained, __bridge_transfer, Cfbridgingretain, cfbridgingrelease• Non-arc: __bridge 3. What is runtime?
1> Runtime is a set of underlying C language APIs (including many powerful and practical C-language data types, C-language functions)
2> Actually, we write the OC code, the bottom layer is based on the runtime implementation
* In other words, the OC code that we write at the end is turned into the underlying runtime code (c language Code)
What's the use of runtime?
1> can dynamically produce a class, a member variable, a method
2> can dynamically modify a class, a member variable, a method
3> can dynamically delete a class, a member variable, a method
Common functions, header files
#import <objc/runtime.h>: Member variables, classes, methods
Ivar * Class_copyivarlist: Get all member variables inside a class
Method * Class_copymethodlist: Get all the methods inside a class
Method Class_getinstancemethod: Get an instance approach (object method, minus-start)
Method Class_getclassmethod: Get a class approach (plus + start)
Method_exchangeimplementations: A specific implementation of 2 methods of exchange
#import <objc/message.h>: Messaging mechanisms
Objc_msgsend (...)
What is iOS swizzle? Implementation of 2 methods using run-time function exchange
Objective-c: Runtime Runtime