0

A common pattern I end up applying is the one described in How to override both initWithFrame: and initWithCoder: in subclass of UIView?

But I keep spinning wheels obsessing what to name said method. I've used things like basicInitialize and localInit and sharedInit. I've been tempted to just call it init which would be evil, but appropriately express my frustration with having to implement the same thing twice (even if just via plumbing).

I'm curious if others have seen any common style of convention for what to name that method? Or if you've developed one of your own.

Community
  • 1
  • 1
Travis Griggs
  • 21,522
  • 19
  • 91
  • 167

1 Answers1

1

I only use "shared" and "default" words with the optional singleton pattern since this is the convention by Cocoa itself, so I wouldn't use those.

nstein
  • 339
  • 2
  • 14