psineur / NSObject-AutomagicCoding

Ability to save every object to PLIST without any special coding.
Other
237 stars 35 forks source link

Architecture Improvement #26

Open psineur opened 11 years ago

psineur commented 11 years ago

One of the thoughts is take a deep look at MTLJSONAdapter and combine best from both. Model & external nature of it is interesting for me.

Feel free to comment & create any new issues. AMC needs your opinion

alexnauda commented 11 years ago

Do you mean to say that you like the externalized mapping? I don't like that aspect. I'm using yours because it allows me to directly instantiate my model classes (plain old NSObject subclasses) from JSON much the same way that http://jackson.codehaus.org/ deserializes JSON into POJOs. NSObject-AutomagicCoding does this with no external configuration, so any directives on how to deserialize are conveniently encapsulated in the plain old NSObject subclasses. Mantle seems to require that your model classes be subclasses of their MTLModel, which is, in my opinion, not desirable.

On the contrary, I'd like to have some additional features to have finer control over the deserialization that can be coded within the target NSObject subclasses. For example: