The scenario is
- I want to pass NSManagedObject across thread.
- The NSManagedObject I want to pass is temporary, which means that I don't want to store it in CoreData.
Currently, I have two solutions:
Create a normal NSManagedObject, do something, store it in CoreData, and pass the permanent objectID to another thread, then delete it in another thread.
[My concern]Efficiency is low to CoreData.
Create a temporary NSManagedObject as this, do something, generate a NSDictioanry as this, and pass the NSDictioanry to another thread, then Create a temporary NSManagedObject and init with this NSDictionary in another thread.
[My concern]I don't know how to init a NSManagedObject with a NSDictionary.
Any suggestion?