Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(3344)

Unified Diff: chrome/installer/mac/app/downloader.h

Issue 2094583004: Initial commit for Chrome metainstaller on Mac. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fully addressed making the .dmg download asynchronously Created 4 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/installer/mac/app/downloader.h
diff --git a/chrome/installer/mac/app/downloader.h b/chrome/installer/mac/app/downloader.h
new file mode 100644
index 0000000000000000000000000000000000000000..085e5e3a0f21a0d984100515b50708ba675d37ae
--- /dev/null
+++ b/chrome/installer/mac/app/downloader.h
@@ -0,0 +1,27 @@
+// Copyright 2016 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef CHROME_INSTALLER_MAC_APP_DOWNLOADER_H_
+#define CHROME_INSTALLER_MAC_APP_DOWNLOADER_H_
+
+#import <Foundation/Foundation.h>
+
+@interface Downloader : NSObject <NSXMLParserDelegate>
+
+// Calls parseXML and returns the first URL. Then calls appendFilename to form
Elly Fong-Jones 2016/07/06 15:22:02 Comments in headers should be about the interface
+// complete download URLs.
+// TODO(ivan): check the URL's actually work ie. response is a 200/202 and
Elly Fong-Jones 2016/07/06 15:22:02 TODOs should have your username in them, so this w
+// return the first working URL.
+- (NSURL*)parseOhamaResponseForChromeImageURLAndFilename:(NSData*)omahaResponseXML;
+
+// Writes the chrome image in memory to the user's download directory.
+- (void)writeChromeImageToDownloadsDirectory:(NSURL*)chromeURL;
+
+// Calls all the other methods in this class to download the latest version of
+// chrome.
+- (void)downloadChromeImageToDownloadsDirectory:(NSData*)responseXMLData;
Elly Fong-Jones 2016/07/06 15:22:02 I think this is the only function that should real
+
+@end
+
+#endif // CHROME_INSTALLER_MAC_APP_DOWNLOADER_H_

Powered by Google App Engine
This is Rietveld 408576698