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

Unified Diff: extensions/common/alias.h

Issue 2379763003: Extract permission alias info from PermissionsProvider (Closed)
Patch Set: Introduce extension::AliasProvider Created 4 years, 2 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 side-by-side diff with in-line comments
Download patch
Index: extensions/common/alias.h
diff --git a/extensions/common/alias.h b/extensions/common/alias.h
new file mode 100644
index 0000000000000000000000000000000000000000..dfd4a1187049778230690e7ad7a2b4af4badda2b
--- /dev/null
+++ b/extensions/common/alias.h
@@ -0,0 +1,33 @@
+// Copyright 2016 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 EXTENSIONS_COMMON_ALIAS_H_
+#define EXTENSIONS_COMMON_ALIAS_H_
+
+#include <string>
+
+namespace extensions {
+
+// Information about a specific alias.
Devlin 2016/10/07 18:36:21 What is an Alias? Why do we need them/where do we
tbarzic 2016/10/07 20:41:18 Done.
+class Alias {
+ public:
+ // |name|: The alias name.
+ // |real_name|: The real name behind alias.
+ Alias(const char* const name, const char* const real_name)
+ : name_(name), real_name_(real_name) {}
+ ~Alias() {}
+
+ const std::string& name() const { return name_; }
+ const std::string& real_name() const { return real_name_; }
+
+ private:
+ // The alias name.
+ std::string name_;
Devlin 2016/10/07 18:36:21 nit: \n
tbarzic 2016/10/07 20:41:18 Done.
+ // The real name behind the alias.
+ std::string real_name_;
+};
+
+} // namespace extensions
+
+#endif // EXTENSIONS_COMMON_ALIAS_H_

Powered by Google App Engine
This is Rietveld 408576698