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

Unified Diff: extensions/common/features/simple_feature.cc

Issue 2172353002: [Extensions] Use rvalue references for SimpleFeature setters (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rvalue Created 4 years, 5 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
« no previous file with comments | « extensions/common/features/simple_feature.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: extensions/common/features/simple_feature.cc
diff --git a/extensions/common/features/simple_feature.cc b/extensions/common/features/simple_feature.cc
index 9da2b991a4c8a1e912d8641cb9f6a5583e0ca345..28c429b470ab50c6f84726d7388f460e6c296b08 100644
--- a/extensions/common/features/simple_feature.cc
+++ b/extensions/common/features/simple_feature.cc
@@ -667,10 +667,38 @@ bool SimpleFeature::IsValidExtensionId(const std::string& extension_id) {
return (extension_id.length() == 32);
}
+void SimpleFeature::set_blacklist(std::vector<std::string>&& blacklist) {
+ blacklist_ = blacklist;
+}
+
+void SimpleFeature::set_command_line_switch(std::string&& command_line_switch) {
+ command_line_switch_ = command_line_switch;
+}
+
+void SimpleFeature::set_contexts(std::vector<Context>&& contexts) {
+ contexts_ = contexts;
+}
+
+void SimpleFeature::set_dependencies(std::vector<std::string>&& dependencies) {
+ dependencies_ = dependencies;
+}
+
+void SimpleFeature::set_extension_types(std::vector<Manifest::Type>&& types) {
+ extension_types_ = types;
+}
+
void SimpleFeature::set_matches(const std::vector<std::string>& matches) {
matches_.ClearPatterns();
for (const std::string& pattern : matches)
matches_.AddPattern(URLPattern(URLPattern::SCHEME_ALL, pattern));
}
+void SimpleFeature::set_platforms(std::vector<Platform>&& platforms) {
+ platforms_ = platforms;
+}
+
+void SimpleFeature::set_whitelist(std::vector<std::string>&& whitelist) {
+ whitelist_ = whitelist;
+}
+
} // namespace extensions
« no previous file with comments | « extensions/common/features/simple_feature.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698