Private classes in Objective C

后端 未结 2 916
长情又很酷
长情又很酷 2021-02-01 14:50

I would like a pattern for a nested private class in Objective C.

Requirements are:

  • class will not be visible/accessible to other classes.
2条回答
  •  轮回少年
    2021-02-01 15:23

    Well you can have "semi-hidden" private methods. You can include an interface file that provides extension methods that is in the implementation file and then just implement the methods declared in there. I was curious about this before and asked a similar question.

    Proper Objective-C Helper "Wannabe" Private methods?

提交回复
热议问题