In , a metaclass is a whose instances are classes. Just as an ordinary class defines the behavior of certain objects, a metaclass defines the behavior of certain classes and their instances.fa
元类定义了类的通用属性;
是类方法;
建立了类层面的依赖选择;
+ (Class)layerClass; // default is [CALayer class]. Used when creating the underlying layer for the view.
它配置的属性或者是根、或者是他的更上一层的抽象。
元类用于更改类的结构和行为。有缺省的结构。