Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- - (void)loadData {
- GetWhateverRequest* req =
- [[GetWhateverRequest alloc] initWithUsername:@"username" password:@"password";
- [req fetch:self];
- }
- - (void)restRequestSuccess:(id)results {
- NSLog(@"Woot. We're loading shit up!");
- /**This particular call returns a hash/associate array/dictionary so let's cast to that **/
- results = (NSDictionary*) results;
- whateverLabel.text = [results valueForKey:@"whatever"];
- }
- - (void)restRequestFailure:(id)code message:(id)message {
- /** Handle a failure here **/
- NSLog(@"Something went wrong. do something about it ");
- }
Add Comment
Please, Sign In to add comment