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

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

Issue 2895953004: Add initial Controller to DownloadService (Closed)
Patch Set: Moved stats out Created 3 years, 7 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 public:
xingliu 2017/05/27 00:25:32 optional nit: public can be removed.
David Trainor- moved to gerrit 2017/05/30 18:55:24 Done.
17 StartupStatus();
18 ~StartupStatus();
19
20 base::Optional<bool> driver_ok;
21 base::Optional<bool> model_ok;
22
23 // Whether or not all components have finished initialization. Note that this
24 // does not mean that all components were initialized successfully.
25 bool Complete() const;
26
27 // Whether or not all components have initialized successfully. Should only
28 // be called if Complete() is true.
29 bool Ok() const;
30
31 private:
32 DISALLOW_COPY_AND_ASSIGN(StartupStatus);
33 };
34
35 } // namespace download
36
37 #endif // COMPONENTS_DOWNLOAD_STARTUP_STATUS_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698