OSDN Git Service

不要になっていたメソッドを削除
authormasakih <masakih@users.sourceforge.jp>
Mon, 12 Oct 2015 01:13:12 +0000 (10:13 +0900)
committermasakih <masakih@users.sourceforge.jp>
Mon, 12 Oct 2015 01:13:12 +0000 (10:13 +0900)
KCD/HMJSONReciever.m

index 6dd79b6..21f00cb 100644 (file)
 }
 - (void)customHTTPProtocol:(CustomHTTPProtocol *)protocol didFailWithError:(NSError *)error
 {
-       [self removeDataForProtocol:protocol];
-}
-
-- (void)customHTTPProtocol:(CustomHTTPProtocol *)protocol didCompleteWithError:(NSError *)error
-{
-       if(!error) {
-               NSData  *data = [self dataForProtocol:protocol];
-               if(!data) {
-                       [self removeDataForProtocol:protocol];
-                       return;
-               }
-               
-#define JSON_LOG_STRING 0
-#if JSON_LOG_STRING
-               NSString *string = [[NSString alloc] initWithData:data encoding:NSUTF8StringEncoding];
-               [[NSApp delegate] logLineReturn:@"body -> \n%@", string];
-#else
-               HMAPIResult *apiResult = [[HMAPIResult alloc] initWithRequest:protocol.request data:data];
-               if(apiResult) {
-                       [self.queueu enqueue:apiResult];
-               }
-#endif
-       }
+       NSString *errorLog = [NSString stringWithFormat:@"Connection Error!.\nRequest: %@\nError: %@", protocol.request, error];
+       NSLog(@"%@", errorLog);
        
        [self removeDataForProtocol:protocol];
 }
 
-
 //- (void)customHTTPProtocol:(CustomHTTPProtocol *)protocol logWithFormat:(NSString *)format arguments:(va_list)argList
 //{
 //     NSURL *url = protocol.request.URL;