small medium large xlarge

16 Jan 2017, 19:02
Emily Priddy (2 posts)

I am wondering what the best way would be to allow the user to export and import more than one object at a time?

16 Jan 2017, 21:04
Marcus S. Zarra (285 posts)

Personally I always export as JSON. That gives you the flexibility to wrap everything in a dictionary or just an array depending on what you are exporting. You can even add additional information to the top of the structure: date of export, etc.

Import is just the reverse.

I would not try and serialize objects, either Core Data or non-Core Data. I always export into a generic format that can be read by anyone.

16 Jan 2017, 21:36
Emily Priddy (2 posts)

Thanks for the tip about serialization. I was wondering about that but didn’t think to ask!

You must be logged in to comment