Created
August 24, 2012 01:51
-
-
Save stevemoser/3444636 to your computer and use it in GitHub Desktop.
RestKit Post
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
NSURL* baseURL = [NSURL URLWithString:@"https://api.example.com/"]; | |
RKObjectManager* objectManager = [RKObjectManager objectManagerWithBaseURL:baseURL]; | |
objectManager.acceptMIMEType = RKMIMETypeJSON; | |
objectManager.serializationMIMEType = RKMIMETypeJSON; | |
[objectManager.mappingProvider setMapping:[SMArticle mapping] forKeyPath:@"article"]; | |
[objectManager.mappingProvider | |
setSerializationMapping:[SMArticle serializationMapping] forClass:[SMArticle class]]; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment