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

Side by Side Diff: chrome/browser/chromeos/drive/file_system/remove_operation.h

Issue 11106007: drive: Rename 'gdata' namespace to 'drive' in chrome/browser/chromeos/drive (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase Created 8 years, 2 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_DRIVE_FILE_SYSTEM_REMOVE_OPERATION_H_ 5 #ifndef CHROME_BROWSER_CHROMEOS_DRIVE_FILE_SYSTEM_REMOVE_OPERATION_H_
6 #define CHROME_BROWSER_CHROMEOS_DRIVE_FILE_SYSTEM_REMOVE_OPERATION_H_ 6 #define CHROME_BROWSER_CHROMEOS_DRIVE_FILE_SYSTEM_REMOVE_OPERATION_H_
7 7
8 #include "base/basictypes.h" 8 #include "base/basictypes.h"
9 #include "base/memory/scoped_ptr.h" 9 #include "base/memory/scoped_ptr.h"
10 #include "base/memory/weak_ptr.h" 10 #include "base/memory/weak_ptr.h"
11 #include "chrome/browser/chromeos/drive/drive_resource_metadata.h" 11 #include "chrome/browser/chromeos/drive/drive_resource_metadata.h"
12 #include "chrome/browser/google_apis/gdata_errorcode.h" 12 #include "chrome/browser/google_apis/gdata_errorcode.h"
13 13
14 class FilePath; 14 class FilePath;
15 class GURL; 15 class GURL;
16 16
17 namespace gdata { 17 namespace drive {
18 18
19 class DriveCache; 19 class DriveCache;
20 class DriveEntryProto; 20 class DriveEntryProto;
21 class DriveFileSystem; 21 class DriveFileSystem;
22 class DriveServiceInterface; 22 class DriveServiceInterface;
23 23
24 namespace file_system { 24 namespace file_system {
25 25
26 // This class encapsulates the drive Remove function. It is resposible for 26 // This class encapsulates the drive Remove function. It is resposible for
27 // sending the request to the drive API, then updating the local state and 27 // sending the request to the drive API, then updating the local state and
(...skipping 18 matching lines...) Expand all
46 const FileOperationCallback& callback, 46 const FileOperationCallback& callback,
47 DriveFileError error, 47 DriveFileError error,
48 scoped_ptr<DriveEntryProto> entry_proto); 48 scoped_ptr<DriveEntryProto> entry_proto);
49 49
50 // Callback for DriveServiceInterface::DeleteDocument. Removes the entry with 50 // Callback for DriveServiceInterface::DeleteDocument. Removes the entry with
51 // |resource_id| from the local snapshot of the filesystem and the cache. 51 // |resource_id| from the local snapshot of the filesystem and the cache.
52 // |document_url| is unused. |callback| must not be null. 52 // |document_url| is unused. |callback| must not be null.
53 void RemoveResourceLocally( 53 void RemoveResourceLocally(
54 const FileOperationCallback& callback, 54 const FileOperationCallback& callback,
55 const std::string& resource_id, 55 const std::string& resource_id,
56 GDataErrorCode status, 56 gdata::GDataErrorCode status,
57 const GURL& /* document_url */); 57 const GURL& /* document_url */);
58 58
59 // Sends notification for directory changes. Notifies of directory changes, 59 // Sends notification for directory changes. Notifies of directory changes,
60 // and runs |callback| with |error|. |callback| may be null. 60 // and runs |callback| with |error|. |callback| may be null.
61 void NotifyDirectoryChanged( 61 void NotifyDirectoryChanged(
62 const FileOperationCallback& callback, 62 const FileOperationCallback& callback,
63 DriveFileError error, 63 DriveFileError error,
64 const FilePath& directory_path); 64 const FilePath& directory_path);
65 65
66 DriveServiceInterface* drive_service_; 66 DriveServiceInterface* drive_service_;
67 DriveFileSystem* file_system_; 67 DriveFileSystem* file_system_;
68 DriveCache* cache_; 68 DriveCache* cache_;
69 69
70 // WeakPtrFactory bound to the UI thread. 70 // WeakPtrFactory bound to the UI thread.
71 // Note: This should remain the last member so it'll be destroyed and 71 // Note: This should remain the last member so it'll be destroyed and
72 // invalidate the weak pointers before any other members are destroyed. 72 // invalidate the weak pointers before any other members are destroyed.
73 base::WeakPtrFactory<RemoveOperation> weak_ptr_factory_; 73 base::WeakPtrFactory<RemoveOperation> weak_ptr_factory_;
74 74
75 DISALLOW_COPY_AND_ASSIGN(RemoveOperation); 75 DISALLOW_COPY_AND_ASSIGN(RemoveOperation);
76 }; 76 };
77 77
78 } // namespace file_system 78 } // namespace file_system
79 } // namespace gdata 79 } // namespace drive
80 80
81 #endif // CHROME_BROWSER_CHROMEOS_DRIVE_FILE_SYSTEM_REMOVE_OPERATION_H_ 81 #endif // CHROME_BROWSER_CHROMEOS_DRIVE_FILE_SYSTEM_REMOVE_OPERATION_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698