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

Side by Side Diff: chrome/browser/sync_file_system/drive_file_sync_client.h

Issue 11411280: Sync FileSystem: Use app id part of the URL for its directory title. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: testfix Created 8 years 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | chrome/browser/sync_file_system/drive_file_sync_client.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CHROME_BROWSER_SYNC_FILE_SYSTEM_DRIVE_FILE_SYNC_CLIENT_H_ 5 #ifndef CHROME_BROWSER_SYNC_FILE_SYSTEM_DRIVE_FILE_SYNC_CLIENT_H_
6 #define CHROME_BROWSER_SYNC_FILE_SYSTEM_DRIVE_FILE_SYNC_CLIENT_H_ 6 #define CHROME_BROWSER_SYNC_FILE_SYSTEM_DRIVE_FILE_SYNC_CLIENT_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/callback_forward.h" 10 #include "base/callback_forward.h"
(...skipping 132 matching lines...) Expand 10 before | Expand all | Expand 10 after
143 143
144 // Deletes the file identified by |resource_id|. 144 // Deletes the file identified by |resource_id|.
145 // |remote_file_md5| represents the expected hash value of the file to be 145 // |remote_file_md5| represents the expected hash value of the file to be
146 // deleted from Drive. If |remote_file_md5| is different from the actual 146 // deleted from Drive. If |remote_file_md5| is different from the actual
147 // value, cancels the deletion and invokes |callback| with 147 // value, cancels the deletion and invokes |callback| with
148 // GDataErrorCode::HTTP_CONFLICT immediately. 148 // GDataErrorCode::HTTP_CONFLICT immediately.
149 void DeleteFile(const std::string& resource_id, 149 void DeleteFile(const std::string& resource_id,
150 const std::string& remote_file_md5, 150 const std::string& remote_file_md5,
151 const GDataErrorCallback& callback); 151 const GDataErrorCallback& callback);
152 152
153 static std::string OriginToDirectoryTitle(const GURL& origin);
154 static GURL DirectoryTitleToOrigin(const std::string& title);
155
153 private: 156 private:
154 friend class DriveFileSyncClientTest; 157 friend class DriveFileSyncClientTest;
155 friend class DriveFileSyncServiceTest; 158 friend class DriveFileSyncServiceTest;
156 159
157 // Constructor for test use. 160 // Constructor for test use.
158 DriveFileSyncClient( 161 DriveFileSyncClient(
159 Profile* profile, 162 Profile* profile,
160 scoped_ptr<google_apis::DriveServiceInterface> drive_service, 163 scoped_ptr<google_apis::DriveServiceInterface> drive_service,
161 scoped_ptr<google_apis::DriveUploaderInterface> drive_uploader); 164 scoped_ptr<google_apis::DriveUploaderInterface> drive_uploader);
162 165
(...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after
237 240
238 scoped_ptr<google_apis::DriveServiceInterface> drive_service_; 241 scoped_ptr<google_apis::DriveServiceInterface> drive_service_;
239 scoped_ptr<google_apis::DriveUploaderInterface> drive_uploader_; 242 scoped_ptr<google_apis::DriveUploaderInterface> drive_uploader_;
240 243
241 DISALLOW_COPY_AND_ASSIGN(DriveFileSyncClient); 244 DISALLOW_COPY_AND_ASSIGN(DriveFileSyncClient);
242 }; 245 };
243 246
244 } // namespace sync_file_system 247 } // namespace sync_file_system
245 248
246 #endif // CHROME_BROWSER_SYNC_FILE_SYSTEM_DRIVE_FILE_SYNC_CLIENT_H_ 249 #endif // CHROME_BROWSER_SYNC_FILE_SYSTEM_DRIVE_FILE_SYNC_CLIENT_H_
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/sync_file_system/drive_file_sync_client.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698