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

Unified Diff: chrome/browser/extensions/blocked_actions.h

Issue 12262025: Alter the ActivityLog db table schemas. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 10 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 | « chrome/browser/extensions/api_actions.cc ('k') | chrome/browser/extensions/blocked_actions.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/extensions/blocked_actions.h
diff --git a/chrome/browser/extensions/blocked_actions.h b/chrome/browser/extensions/blocked_actions.h
index 57d20bf6d5fa8e34d1e89c0f9d1917164b40bdf6..6492f5c22453876cd539fd5e2807c3a14c8ae3da 100644
--- a/chrome/browser/extensions/blocked_actions.h
+++ b/chrome/browser/extensions/blocked_actions.h
@@ -16,11 +16,18 @@ namespace extensions {
class BlockedAction : public Action {
public:
static const char* kTableName;
- static const char* kTableStructure;
+ static const char* kTableBasicFields;
+ static const char* kTableContentFields[];
+ // Create a new database table for storing BlockedActions, or update the
+ // schema if it is out of date. Any existing data is preserved.
+ static bool InitializeTable(sql::Connection* db);
+
+ // You must supply the id, time, api_call, and reason.
BlockedAction(const std::string& extension_id,
const base::Time& time,
- const std::string& blocked_action, // the blocked API call
+ const std::string& api_call, // the blocked API call
+ const std::string& args, // the arguments
const std::string& reason, // the reason it's blocked
const std::string& extra); // any extra logging info
@@ -37,7 +44,8 @@ class BlockedAction : public Action {
const std::string& extension_id() const { return extension_id_; }
const base::Time& time() const { return time_; }
const std::string& reason() const { return reason_; }
- const std::string& blocked_action() const { return blocked_action_; }
+ const std::string& api_call() const { return api_call_; }
+ const std::string& args() const { return args_; }
const std::string& extra() const { return extra_; }
protected:
@@ -46,7 +54,8 @@ class BlockedAction : public Action {
private:
std::string extension_id_;
base::Time time_;
- std::string blocked_action_;
+ std::string api_call_;
+ std::string args_;
std::string reason_;
std::string extra_;
« no previous file with comments | « chrome/browser/extensions/api_actions.cc ('k') | chrome/browser/extensions/blocked_actions.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698