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

Side by Side Diff: components/download/internal/startup_status.h

Issue 2895953004: Add initial Controller to DownloadService (Closed)
Patch Set: Rebased Created 3 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 unified diff | Download patch
OLDNEW
(Empty)
1 // Copyright 2017 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef COMPONENTS_DOWNLOAD_STARTUP_STATUS_H_
6 #define COMPONENTS_DOWNLOAD_STARTUP_STATUS_H_
7
8 #include "base/macros.h"
9 #include "base/optional.h"
10
11 namespace download {
12
13 // Helper struct to track the initialization status of various Controller
14 // internal components.
15 struct StartupStatus {
16 StartupStatus();
17 ~StartupStatus();
18
19 base::Optional<bool> driver_ok;
20 base::Optional<bool> model_ok;
21
22 // Whether or not all components have finished initialization. Note that this
23 // does not mean that all components were initialized successfully.
24 bool Complete() const;
25
26 // Whether or not all components have initialized successfully. Should only
27 // be called if Complete() is true.
28 bool Ok() const;
29
30 private:
31 DISALLOW_COPY_AND_ASSIGN(StartupStatus);
32 };
33
34 } // namespace download
35
36 #endif // COMPONENTS_DOWNLOAD_STARTUP_STATUS_H_
OLDNEW
« no previous file with comments | « components/download/internal/model_impl_unittest.cc ('k') | components/download/internal/startup_status.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698