| Index: net/base/capturing_net_log.h
|
| ===================================================================
|
| --- net/base/capturing_net_log.h (revision 137673)
|
| +++ net/base/capturing_net_log.h (working copy)
|
| @@ -17,29 +17,31 @@
|
| #include "net/base/net_export.h"
|
| #include "net/base/net_log.h"
|
|
|
| +namespace base {
|
| +class Value;
|
| +}
|
| +
|
| namespace net {
|
|
|
| // CapturingNetLog is an implementation of NetLog that saves messages to a
|
| // bounded buffer.
|
| class NET_EXPORT CapturingNetLog : public NetLog {
|
| public:
|
| - struct NET_EXPORT Entry {
|
| - Entry(EventType type,
|
| - const base::TimeTicks& time,
|
| - Source source,
|
| - EventPhase phase,
|
| - EventParameters* extra_parameters);
|
| - ~Entry();
|
| + struct NET_EXPORT CapturedEntry {
|
| + CapturedEntry(EventType type,
|
| + const base::TimeTicks& time,
|
| + Source source,
|
| + EventPhase phase);
|
| + ~CapturedEntry();
|
|
|
| EventType type;
|
| base::TimeTicks time;
|
| Source source;
|
| EventPhase phase;
|
| - scoped_refptr<EventParameters> extra_parameters;
|
| };
|
|
|
| // Ordered set of entries that were logged.
|
| - typedef std::vector<Entry> EntryList;
|
| + typedef std::vector<CapturedEntry> CapturedEntryList;
|
|
|
| enum { kUnbounded = -1 };
|
|
|
| @@ -49,18 +51,14 @@
|
| virtual ~CapturingNetLog();
|
|
|
| // Returns the list of all entries in the log.
|
| - void GetEntries(EntryList* entry_list) const;
|
| + void GetEntries(CapturedEntryList* entry_list) const;
|
|
|
| void Clear();
|
|
|
| void SetLogLevel(NetLog::LogLevel log_level);
|
|
|
| // NetLog implementation:
|
| - virtual void AddEntry(
|
| - EventType type,
|
| - const Source& source,
|
| - EventPhase phase,
|
| - const scoped_refptr<EventParameters>& extra_parameters) OVERRIDE;
|
| + virtual void OnAddEntry(const net::NetLog::Entry& entry) OVERRIDE;
|
| virtual uint32 NextID() OVERRIDE;
|
| virtual LogLevel GetLogLevel() const OVERRIDE;
|
| virtual void AddThreadSafeObserver(ThreadSafeObserver* observer,
|
| @@ -77,7 +75,7 @@
|
| base::subtle::Atomic32 last_id_;
|
|
|
| size_t max_num_entries_;
|
| - EntryList entries_;
|
| + CapturedEntryList captured_entries_;
|
|
|
| NetLog::LogLevel log_level_;
|
|
|
| @@ -99,7 +97,7 @@
|
| BoundNetLog bound() const { return net_log_; }
|
|
|
| // Fills |entry_list| with all entries in the log.
|
| - void GetEntries(CapturingNetLog::EntryList* entry_list) const;
|
| + void GetEntries(CapturingNetLog::CapturedEntryList* entry_list) const;
|
|
|
| void Clear();
|
|
|
|
|