Your best option is to use a category in the second header file, for example. MyClass_protected.h and include it in the main class and subclasses as suggested in the solution you are linking. It is really quite simple, and not "too complicated", but just one additional file.
Objective-C has very strong introspection characteristics. No matter how and where you declare a property (or any other function, for that matter), you can access it from anywhere. You will get a compiler warning if only the code you write cannot see the corresponding declaration or implementation (unless you use an introspective method, for example, one of the performSelector... family performSelector... ). The only reasons for the interface are name security, type security, and preventing compiler warnings. Therefore, you have several options:
Main class interface
You get execution security (i.e., the compiler will give a warning if you do not implement the method). However, each class (which imports yours) will see the methods. You can use a comment to indicate that the method should be protected, but of course no one will see it unless it checks the source. I most often use this when I'm the only programmer in a project, because I know what needs to be protected and what is not.
Category in the same .h file
As above, programmers will not protect it if they do not check the source, but if they do, it will be much more obvious. If you declare this in the named category ( @interface MyClass (protected) ), you will lose type safety, but itβs even more clear what you intend. Most often I use this to emulate abstract methods, that is, obviously not for implementation, but should be accessible to everyone.
Category in subclass .m file directly
This is a bad idea, do not do this. You only see methods in the subclass, but you are losing execution safety, and this is really just wrong. I only ever used this for unit tests, and I ended up moving them to a separate header.
Category in a separate header (MyClass_protected.h)
Preferred solution and the closest Objective-C can get protected methods. This is just another file, seriously, don't get your panties up to date. You can use the class extension (these are anonymous categories) and you will not lose execution safety. It is available only for classes that include it, which should only be subclasses; the fact that the methods contained are intended to be used as protected ones should be obvious to everyone except the most incompetent programmers, because of the name of the header.