| OLD | NEW |
| (Empty) |
| 1 // Copyright 2013 The Chromium 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 CHROME_BROWSER_EXTENSIONS_ACTIVITY_LOG_STREAM_NOARGS_UI_POLICY_H_ | |
| 6 #define CHROME_BROWSER_EXTENSIONS_ACTIVITY_LOG_STREAM_NOARGS_UI_POLICY_H_ | |
| 7 | |
| 8 #include <string> | |
| 9 | |
| 10 #include "base/containers/hash_tables.h" | |
| 11 #include "chrome/browser/extensions/activity_log/fullstream_ui_policy.h" | |
| 12 | |
| 13 namespace extensions { | |
| 14 | |
| 15 // A policy for logging the stream of actions, but without arguments. | |
| 16 class StreamWithoutArgsUIPolicy : public FullStreamUIPolicy { | |
| 17 public: | |
| 18 explicit StreamWithoutArgsUIPolicy(Profile* profile); | |
| 19 virtual ~StreamWithoutArgsUIPolicy(); | |
| 20 | |
| 21 protected: | |
| 22 // Clears the args field of the action (except for some DOM events and a | |
| 23 // small whitelisted set of api_names). For WEB_REQUEST actions, keeps keys | |
| 24 // but removes values from the "web_request" dictionary in other. | |
| 25 virtual scoped_refptr<Action> ProcessArguments( | |
| 26 scoped_refptr<Action> action) const OVERRIDE; | |
| 27 | |
| 28 private: | |
| 29 base::hash_set<std::string> arg_whitelist_api_; | |
| 30 }; | |
| 31 | |
| 32 } // namespace extensions | |
| 33 | |
| 34 #endif // CHROME_BROWSER_EXTENSIONS_ACTIVITY_LOG_STREAM_NOARGS_UI_POLICY_H_ | |
| OLD | NEW |