Open Glavin001 opened 10 years ago
pushPayload
, see http://emberjs.com/api/data/classes/DS.Store.html#method_pushPayload The more I think about it the more I believe that SLAPIManager
should really act as the Store
and the Adapter
, since the Store
is really CoreData but that layer is already implemented and it would be redundant to add something to the CoreData NSManagedObjectContext
since MagicalRecord makes it pretty easy to use already.
Continue on with #7
Okay, so I created a SLStore
class..
It should create it's own NSManagedObjectContext
and use it internally.
The SLStore
(Store) should be associated to a single SLAPIManager
(Adapter) which has a default and generalized Serializer
that has registered all of the Transforms
.
Yes, this will be HEAVILY inspired by Ember. And I like it!
Similar to Ember, the Store
could be what is created (instead of SLAPIManager
) and then it would automatically create it's own API Manager (which could be overridden).
Instead of using Strings
like Ember it would be great to be able to pass Class
es and therefore verify that the model class exists and can be instantiated right on that class argument.
Only allow SLModel
classes as modelClass
arguments. Seehttp://stackoverflow.com/a/5874006/2578205
Base off of http://emberjs.com/api/data/classes/DS.Store.html
Currently MagicalRecord's
[NSManagedObjectContext MR_defaultContext]
is the effectivestore
, backed by CoreData.