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

Unified Diff: net/base/net_log.h

Issue 10539094: NetLogEventParameter to Callback refactoring 1, (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Remove unneeded line Created 8 years, 6 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: net/base/net_log.h
===================================================================
--- net/base/net_log.h (revision 141407)
+++ net/base/net_log.h (working copy)
@@ -296,6 +296,13 @@
// Warning: |name| must remain valid for the life of the callback.
static ParametersCallback IntegerCallback(const char* name, int value);
+ // Creates a ParametersCallback that encapsulates a single UTF8 string. Takes
+ // |value| as a pointer to avoid copying, and emphasize it must be valid for
+ // the life of the callback. |value| may not be NULL.
+ // Warning: |name| and |value| must remain valid for the life of the callback.
+ static ParametersCallback StringCallback(const char* name,
+ const std::string* value);
+
protected:
// Child classes should respond to the new entry here. This includes
// creating the Entry object and alerting their observers.

Powered by Google App Engine
This is Rietveld 408576698