forked from chromium/chromium
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathversion_loader.h
41 lines (30 loc) · 1.11 KB
/
version_loader.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
// Copyright (c) 2011 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#ifndef CHROMEOS_SYSTEM_VERSION_LOADER_H_
#define CHROMEOS_SYSTEM_VERSION_LOADER_H_
#include <string>
#include "chromeos/chromeos_export.h"
namespace chromeos {
namespace version_loader {
enum VersionFormat {
VERSION_SHORT,
VERSION_SHORT_WITH_DATE,
VERSION_FULL,
};
// Gets the version.
// If |full_version| is true version string with extra info is extracted,
// otherwise it's in short format x.x.xx.x.
// Must be run on a blocking thread pool.
CHROMEOS_EXPORT std::string GetVersion(VersionFormat format);
// Gets the ARC version.
// Must be run on a blocking thread pool.
CHROMEOS_EXPORT std::string GetARCVersion();
// Gets the firmware info.
// Must be run on a blocking thread pool.
CHROMEOS_EXPORT std::string GetFirmware();
// Extracts the firmware from the file.
CHROMEOS_EXPORT std::string ParseFirmware(const std::string& contents);
} // namespace version_loader
} // namespace chromeos
#endif // CHROMEOS_SYSTEM_VERSION_LOADER_H_