swift - Referencing App Object Across Multiple Build Targets iOS -


i need make several versions of ios application each different target , name. of differences between applications in applications resources , not source code. trying share source code across versions possible.

my issue arises when try access application object in version not have same name original. instance, have 2 versions of application named userapp , userapp2 , following code references data store:

var user = userapp.user 

when try run code in userapp2 target, throws error saying userapp undefined.

my question is: how can make code load proper application object depending on target running? solution can used across targets without need change code.

edit: userapp object xcdatamodel.

the userapp class might not added in of application targets. verify target membership class.

enter image description here


Comments

Popular posts from this blog

c# - Binding a comma separated list to a List<int> in asp.net web api -

how to prompt save As Box in Excel Interlop c# MVC 4 -

xslt 1.0 - How to access or retrieve mets content of an item from another item? -