[英]Objective C UIViewController subclass?
Recently I've been looking into RESideMenu . 最近,我一直在研究RESideMenu 。 What really piqued my interest was his 'UIViewController+RESideMenu.h/m'.
真正引起我兴趣的是他的“ UIViewController + RESideMenu.h / m”。 It appears to me that this is a way to subclass a UIViewController.
在我看来,这是继承UIViewController的一种方法。 It includes IBActions and methods in it that are accessible from anything that inherits from UIViewController.
它包括IBAction和方法,可从UIViewController继承的任何内容中访问。
All of my attempts to replicate this have failed. 我所有重复此操作的尝试都失败了。 Is there a special way to go about it?
有什么特别的方法吗?
Usually that sort of classname is used to denote a category. 通常,这种类名用于表示类别。 Instead of subclassing it adds additional methods and properties to a class.
它没有子类化,而是向类添加了其他方法和属性。 For more information see here: CustomizingExistingClasses
有关更多信息,请参见此处: CustomizingExistingClasses
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.