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

Side by Side Diff: chrome/browser/chromeos/drive/drive_scheduler.h

Issue 14188035: Pass error code for drive::JobListObserver::OnJobDone(). (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 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
« no previous file with comments | « no previous file | chrome/browser/chromeos/drive/drive_scheduler.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_CHROMEOS_DRIVE_DRIVE_SCHEDULER_H_ 5 #ifndef CHROME_BROWSER_CHROMEOS_DRIVE_DRIVE_SCHEDULER_H_
6 #define CHROME_BROWSER_CHROMEOS_DRIVE_DRIVE_SCHEDULER_H_ 6 #define CHROME_BROWSER_CHROMEOS_DRIVE_DRIVE_SCHEDULER_H_
7 7
8 #include <list> 8 #include <list>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 357 matching lines...) Expand 10 before | Expand all | Expand 10 after
368 net::NetworkChangeNotifier::ConnectionType type) OVERRIDE; 368 net::NetworkChangeNotifier::ConnectionType type) OVERRIDE;
369 369
370 // Get the type of queue the specified job should be put in. 370 // Get the type of queue the specified job should be put in.
371 QueueType GetJobQueueType(JobType type); 371 QueueType GetJobQueueType(JobType type);
372 372
373 // For testing only. Disables throttling so that testing is faster. 373 // For testing only. Disables throttling so that testing is faster.
374 void SetDisableThrottling(bool disable) { disable_throttling_ = disable; } 374 void SetDisableThrottling(bool disable) { disable_throttling_ = disable; }
375 375
376 // Notifies updates to observers. 376 // Notifies updates to observers.
377 void NotifyJobAdded(const JobInfo& job_info); 377 void NotifyJobAdded(const JobInfo& job_info);
378 void NotifyJobDone(const JobInfo& job_info); 378 void NotifyJobDone(const JobInfo& job_info, DriveFileError error);
379 void NotifyJobUpdated(const JobInfo& job_info); 379 void NotifyJobUpdated(const JobInfo& job_info);
380 380
381 // Number of jobs in flight for each queue. 381 // Number of jobs in flight for each queue.
382 int jobs_running_[NUM_QUEUES]; 382 int jobs_running_[NUM_QUEUES];
383 383
384 // The number of times operations have failed in a row, capped at 384 // The number of times operations have failed in a row, capped at
385 // kMaxThrottleCount. This is used to calculate the delay before running the 385 // kMaxThrottleCount. This is used to calculate the delay before running the
386 // next task. 386 // next task.
387 int throttle_count_; 387 int throttle_count_;
388 388
(...skipping 17 matching lines...) Expand all
406 406
407 // Note: This should remain the last member so it'll be destroyed and 407 // Note: This should remain the last member so it'll be destroyed and
408 // invalidate its weak pointers before any other members are destroyed. 408 // invalidate its weak pointers before any other members are destroyed.
409 base::WeakPtrFactory<DriveScheduler> weak_ptr_factory_; 409 base::WeakPtrFactory<DriveScheduler> weak_ptr_factory_;
410 DISALLOW_COPY_AND_ASSIGN(DriveScheduler); 410 DISALLOW_COPY_AND_ASSIGN(DriveScheduler);
411 }; 411 };
412 412
413 } // namespace drive 413 } // namespace drive
414 414
415 #endif // CHROME_BROWSER_CHROMEOS_DRIVE_DRIVE_SCHEDULER_H_ 415 #endif // CHROME_BROWSER_CHROMEOS_DRIVE_DRIVE_SCHEDULER_H_
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/chromeos/drive/drive_scheduler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698