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

Side by Side Diff: chrome/browser/chromeos/gdata/gdata_files.h

Issue 10204013: Move FindEntryDelegate and friends to separate file. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 8 years, 8 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 unified diff | Download patch | Annotate | Revision Log
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_CHROMEOS_GDATA_GDATA_FILES_H_ 5 #ifndef CHROME_BROWSER_CHROMEOS_GDATA_GDATA_FILES_H_
6 #define CHROME_BROWSER_CHROMEOS_GDATA_GDATA_FILES_H_ 6 #define CHROME_BROWSER_CHROMEOS_GDATA_GDATA_FILES_H_
7 #pragma once 7 #pragma once
8 8
9 #include <map> 9 #include <map>
10 #include <string> 10 #include <string>
11 11
12 #include "base/callback.h" 12 #include "base/callback.h"
13 #include "base/gtest_prod_util.h" 13 #include "base/gtest_prod_util.h"
14 #include "base/memory/scoped_ptr.h" 14 #include "base/memory/scoped_ptr.h"
15 #include "base/memory/singleton.h" 15 #include "base/memory/singleton.h"
16 #include "base/memory/weak_ptr.h" 16 #include "base/memory/weak_ptr.h"
17 #include "base/platform_file.h" 17 #include "base/platform_file.h"
18 #include "base/synchronization/lock.h" 18 #include "base/synchronization/lock.h"
19 #include "chrome/browser/chromeos/gdata/gdata_params.h" 19 #include "chrome/browser/chromeos/gdata/gdata_params.h"
20 #include "chrome/browser/chromeos/gdata/gdata_parser.h" 20 #include "chrome/browser/chromeos/gdata/gdata_parser.h"
21 #include "chrome/browser/chromeos/gdata/gdata_uploader.h" 21 #include "chrome/browser/chromeos/gdata/gdata_uploader.h"
22 #include "chrome/browser/profiles/profile_keyed_service.h" 22 #include "chrome/browser/profiles/profile_keyed_service.h"
23 #include "chrome/browser/profiles/profile_keyed_service_factory.h" 23 #include "chrome/browser/profiles/profile_keyed_service_factory.h"
24 24
25 namespace gdata { 25 namespace gdata {
26 26
27 class FindEntryDelegate;
27 class GDataFile; 28 class GDataFile;
28 class GDataDirectory; 29 class GDataDirectory;
29 class GDataRootDirectory; 30 class GDataRootDirectory;
30 31
31 class GDataEntryProto; 32 class GDataEntryProto;
32 class GDataFileProto; 33 class GDataFileProto;
33 class GDataDirectoryProto; 34 class GDataDirectoryProto;
34 class GDataRootDirectoryProto; 35 class GDataRootDirectoryProto;
35 36
36 // Directory content origin. 37 // Directory content origin.
(...skipping 378 matching lines...) Expand 10 before | Expand all | Expand 10 after
415 416
416 // Add the entry to resource map. 417 // Add the entry to resource map.
417 void AddEntryToResourceMap(GDataEntry* entry); 418 void AddEntryToResourceMap(GDataEntry* entry);
418 419
419 // Remove the entry from resource map. 420 // Remove the entry from resource map.
420 void RemoveEntryFromResourceMap(GDataEntry* entry); 421 void RemoveEntryFromResourceMap(GDataEntry* entry);
421 422
422 // Remove the entries from resource map. 423 // Remove the entries from resource map.
423 void RemoveEntriesFromResourceMap(const GDataFileCollection& children); 424 void RemoveEntriesFromResourceMap(const GDataFileCollection& children);
424 425
426 // Search for |file_path| triggering callback in |delegate|.
satorux1 2012/04/25 06:01:37 Search -> Searches While you are at it, could you
achuithb 2012/04/25 10:05:35 Done.
427 void FindEntryByPath(const FilePath& file_path,
428 FindEntryDelegate* delegate);
429
425 // Returns the GDataEntry* with the corresponding |resource_id|. 430 // Returns the GDataEntry* with the corresponding |resource_id|.
426 GDataEntry* GetEntryByResourceId(const std::string& resource_id); 431 GDataEntry* GetEntryByResourceId(const std::string& resource_id);
427 432
428 // Set |cache_map_| data member to formal parameter |new_cache_map|. 433 // Set |cache_map_| data member to formal parameter |new_cache_map|.
429 void SetCacheMap(const CacheMap& new_cache_map); 434 void SetCacheMap(const CacheMap& new_cache_map);
430 435
431 // Updates cache map with entry corresponding to |resource_id|. 436 // Updates cache map with entry corresponding to |resource_id|.
432 // Creates new entry if it doesn't exist, otherwise update the entry. 437 // Creates new entry if it doesn't exist, otherwise update the entry.
433 void UpdateCacheMap(const std::string& resource_id, 438 void UpdateCacheMap(const std::string& resource_id,
434 const std::string& md5, 439 const std::string& md5,
(...skipping 29 matching lines...) Expand all
464 base::Time last_serialized_; 469 base::Time last_serialized_;
465 int largest_changestamp_; 470 int largest_changestamp_;
466 size_t serialized_size_; 471 size_t serialized_size_;
467 472
468 DISALLOW_COPY_AND_ASSIGN(GDataRootDirectory); 473 DISALLOW_COPY_AND_ASSIGN(GDataRootDirectory);
469 }; 474 };
470 475
471 } // namespace gdata 476 } // namespace gdata
472 477
473 #endif // CHROME_BROWSER_CHROMEOS_GDATA_GDATA_FILES_H_ 478 #endif // CHROME_BROWSER_CHROMEOS_GDATA_GDATA_FILES_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698