blob: d319b8cee2a67665b002b0a7cace809cbf6ac2a3 [file] [log] [blame]
Alex Deymobd04b142014-03-18 15:00:05 -07001// Copyright (c) 2014 The Chromium OS 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 CHROMEOS_PLATFORM_UPDATE_ENGINE_POLICY_MANAGER_SYSTEM_PROVIDER_H_
6#define CHROMEOS_PLATFORM_UPDATE_ENGINE_POLICY_MANAGER_SYSTEM_PROVIDER_H_
7
8#include <base/memory/scoped_ptr.h>
9
10#include "update_engine/policy_manager/provider.h"
11#include "update_engine/policy_manager/variable.h"
12
13namespace chromeos_policy_manager {
14
15// Provider for system information, mostly constant, such as the information
16// reported by crossystem, the kernel boot command line and the partition table.
17class SystemProvider : public Provider {
18 public:
David Zeuthen21716e22014-04-23 15:42:05 -070019 virtual ~SystemProvider() {}
20
Alex Deymobd04b142014-03-18 15:00:05 -070021 // Returns true if the boot mode is normal or if it's unable to
22 // determine the boot mode. Returns false if the boot mode is
23 // developer.
David Zeuthen21716e22014-04-23 15:42:05 -070024 virtual Variable<bool>* var_is_normal_boot_mode() = 0;
Alex Deymobd04b142014-03-18 15:00:05 -070025
26 // Returns whether this is an official Chrome OS build.
David Zeuthen21716e22014-04-23 15:42:05 -070027 virtual Variable<bool>* var_is_official_build() = 0;
Alex Deymobd04b142014-03-18 15:00:05 -070028
29 protected:
30 SystemProvider() {}
31
Alex Deymobd04b142014-03-18 15:00:05 -070032 private:
Alex Deymobd04b142014-03-18 15:00:05 -070033 DISALLOW_COPY_AND_ASSIGN(SystemProvider);
34};
35
36} // namespace chromeos_policy_manager
37
38#endif // CHROMEOS_PLATFORM_UPDATE_ENGINE_POLICY_MANAGER_SYSTEM_PROVIDER_H_