iphone - Is its ok to have multiple implementations per target in XCode? -


i have header file defines class interface:

// myclass.h - included in targets // @interface myclass + (void) dothing; @end 

and have 2 different implementation files - 1 per target.

// myclass+targeta.m - included in targeta // @implementation myclass + (void) dothing { nslog(@"targeta"); } @end   // myclass+targetb.m - included in targetb // @implementation myclass + (void) dothing { nslog(@"targetb"); } @end 
  • are there issues approach?
  • is there better or simpler way customise behaviour of each target?

the method myclass themeing appearance of app. there several methods on myclass , several targets

yes work fine, , have taken similar approach, except have used conditional compilation, 1 target exposing private functionality , target exposing public functionality, targets sharing same set of source files.

however results of both our approaches same.


Comments

Popular posts from this blog

html - How to style widget with post count different than without post count -

How to remove text and logo OR add Overflow on Android ActionBar using AppCompat on API 8? -

javascript - storing input from prompt in array and displaying the array -