| Index: chrome/browser/extensions/extension_permissions_api_helpers.h
|
| diff --git a/chrome/browser/extensions/extension_permissions_api_helpers.h b/chrome/browser/extensions/extension_permissions_api_helpers.h
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..563f99e69afef7790484bd31213d81c46734dd6a
|
| --- /dev/null
|
| +++ b/chrome/browser/extensions/extension_permissions_api_helpers.h
|
| @@ -0,0 +1,36 @@
|
| +// Copyright (c) 2012 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 CHROME_BROWSER_EXTENSIONS_EXTENSION_PERMISSIONS_API_HELPERS_H_
|
| +#define CHROME_BROWSER_EXTENSIONS_EXTENSION_PERMISSIONS_API_HELPERS_H_
|
| +#pragma once
|
| +
|
| +#include <string>
|
| +
|
| +#include "base/memory/ref_counted.h"
|
| +
|
| +namespace base {
|
| +class DictionaryValue;
|
| +}
|
| +class ExtensionPermissionSet;
|
| +
|
| +namespace extensions {
|
| +
|
| +namespace permissions_api {
|
| +
|
| +// Converts the permission |set| to a dictionary value.
|
| +base::DictionaryValue* PackPermissionsToValue(
|
| + const ExtensionPermissionSet* set);
|
| +
|
| +// Converts the |value| to a permission set.
|
| +bool UnpackPermissionsFromValue(base::DictionaryValue* value,
|
| + scoped_refptr<ExtensionPermissionSet>* ptr,
|
| + bool* bad_message,
|
| + std::string* error);
|
| +
|
| +} // namespace permissions_api
|
| +
|
| +} // namespace extensions
|
| +
|
| +#endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_PERMISSIONS_API_HELPERS_H__
|
|
|