Created
February 10, 2014 14:51
-
-
Save yangboz/8917276 to your computer and use it in GitHub Desktop.
App42 API call with try...catch block
This file contains 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
@try{ | |
//App42 service API call here. | |
}@catch (App42BadParameterException *ex) { | |
NSLog(@"BadParameterException found,status code:%d",ex.appErrorCode); | |
}@catch (App42SecurityException *ex) { | |
NSLog(@"SecurityException found!"); | |
}@catch (App42Exception *ex) { | |
NSLog(@"App42 Exception found:%@",ex.description); | |
//NSAlert here. | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment