blob: d18955bbf169e03ea1af586f59eba62a508a27f8 [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
Alex Deymobd04b142014-03-18 15:00:05 -07008#include "update_engine/policy_manager/provider.h"
9#include "update_engine/policy_manager/variable.h"
10
11namespace chromeos_policy_manager {
12
13// Provider for system information, mostly constant, such as the information
14// reported by crossystem, the kernel boot command line and the partition table.
15class SystemProvider : public Provider {
16 public:
David Zeuthen21716e22014-04-23 15:42:05 -070017 virtual ~SystemProvider() {}
18
Alex Deymobd04b142014-03-18 15:00:05 -070019 // Returns true if the boot mode is normal or if it's unable to
20 // determine the boot mode. Returns false if the boot mode is
21 // developer.
David Zeuthen21716e22014-04-23 15:42:05 -070022 virtual Variable<bool>* var_is_normal_boot_mode() = 0;
Alex Deymobd04b142014-03-18 15:00:05 -070023
24 // Returns whether this is an official Chrome OS build.
David Zeuthen21716e22014-04-23 15:42:05 -070025 virtual Variable<bool>* var_is_official_build() = 0;
Alex Deymobd04b142014-03-18 15:00:05 -070026
27 protected:
28 SystemProvider() {}
29
Alex Deymobd04b142014-03-18 15:00:05 -070030 private:
Alex Deymobd04b142014-03-18 15:00:05 -070031 DISALLOW_COPY_AND_ASSIGN(SystemProvider);
32};
33
34} // namespace chromeos_policy_manager
35
36#endif // CHROMEOS_PLATFORM_UPDATE_ENGINE_POLICY_MANAGER_SYSTEM_PROVIDER_H_