I have a json string like:
{
\"a\":\"val1\",
\"b\":\"val2\",
\"c\":\"val3\"
}
And I have an objective C header file like:
Use OCMapper to automate your mapping. it has the ability to automatically map all fields, and simple to use.
https://github.com/aryaxt/OCMapper
let request = Manager.sharedInstance.request(requestWithPath("example.com/users/5", method: .GET, parameters: nil))
request.responseObject(User.self) { request, response, user, error in
println(user.firstName)
}