Mercurial > hg > soniczoomios
diff ServerComms.mm @ 41:79c129e500e1
r
author | Robert Tubb <rt300@eecs.qmul.ac.uk> |
---|---|
date | Fri, 12 Apr 2013 17:50:25 +0100 |
parents | a42903c61558 |
children | a1e75b94c505 |
line wrap: on
line diff
--- a/ServerComms.mm Fri Apr 12 16:13:42 2013 +0100 +++ b/ServerComms.mm Fri Apr 12 17:50:25 2013 +0100 @@ -20,7 +20,7 @@ } return self; } - +//------------------------------------------------------------------------------- // asynchronous one -(BOOL)doPostRequest:(NSString *)type withData:(NSString *)data{ @@ -149,7 +149,7 @@ if([self.currentRequestType isEqualToString:@"questionnaire"]) eventLogger.questionnaireNotOK(); } } - +//------------------------------------------------------------------------------- - (void)connection:(NSURLConnection *)connection didFailWithError:(NSError *)error { NSLog(@"fail with error"); @@ -168,7 +168,7 @@ self.requestInProgress = NO; // we won't know what kind of request method this was... } - +//------------------------------------------------------------------------------- - (void)connectionDidFinishLoading:(NSURLConnection *)connection { NSString *responseText = [[NSString alloc] initWithData:self.data encoding:NSUTF8StringEncoding]; @@ -179,7 +179,7 @@ self.requestInProgress = NO; } - +//------------------------------------------------------------------------------- // Handle basic authentication challenge if needed - (void)connection:(NSURLConnection *)connection didReceiveAuthenticationChallenge:(NSURLAuthenticationChallenge *)challenge { NSString *username = @"username"; @@ -198,5 +198,5 @@ } */ - +//------------------------------------------------------------------------------- @end