I am creating a subclass of UIBarButtonItem, to provide some specific functionality.
The new class has an initializer, that is the only one that should be used when creating an instance of the class:
- (id) initWithSomeObject:(SomeObject *)param;
The problem is, all the initializers from UIBarButtonItem are still available, so I could create an instance of my new class using something like
MyCustomUIBarButtonItem *button = [[MyCustomUIBarButtonItem alloc] initWithBarButtonSystemItem:systemItem target:target action:action];
or something else...
Is there a way to hide the initializers from UIBarButtomItem in my subclass, so that they cannot be used?