• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Core Data migration: how to use NSAddEntityMappingType in xcmappingmodel editor?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Core Data migration: how to use NSAddEntityMappingType in xcmappingmodel editor?


  • Subject: Core Data migration: how to use NSAddEntityMappingType in xcmappingmodel editor?
  • From: Sean McBride <email@hidden>
  • Date: Thu, 06 Nov 2014 12:19:52 -0500
  • Organization: Rogue Research Inc.

Hi all,

I'm trying to create, in Xcode's .xcmappingmodel editor, a working NSAddEntityMappingType type mapping.

I press the 'Add Entity Mapping' button and a new mapping is created with both the source and destination set to 'invalid value'.  If I change only the destination to my desired entity then the 'type' indeed becomes 'Add', presumably corresponding to NSAddEntityMappingType.  Everything builds without warning.

But the mapping never seems to get executed.  I conclude this both because there is no entity created and also because I set one of the attribute mappings to invoke a custom NSEntityMigrationPolicy subclass, and I never break inside it.

What am I missing in how to use this?  Or am I misunderstanding what NSAddEntityMappingType is for?  My goal is to unconditionally create a single instance of a new entity when migrating old stores.

Thanks,

--
____________________________________________________________
Sean McBride, B. Eng                 email@hidden
Rogue Research                        www.rogue-research.com
Mac Software Developer              Montréal, Québec, Canada



 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden


  • Prev by Date: Re: NSOpenGLView with broken -initWithFrame: in Xcode 6?
  • Next by Date: Objective Git can't link to libiconv
  • Previous by thread: Re: NSOpenGLView with broken -initWithFrame: in Xcode 6?
  • Next by thread: Objective Git can't link to libiconv
  • Index(es):
    • Date
    • Thread