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

Unified Diff: net/http/http_stream_factory_impl_job.cc

Issue 2315613002: Extracted NetLog class's inner enum types into their own enum classes and (Closed)
Patch Set: Ran "git cl format" on code. Much formatting ensued. Created 4 years, 3 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 | « net/http/http_proxy_client_socket_wrapper.cc ('k') | net/http/http_stream_factory_impl_job_controller.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/http/http_stream_factory_impl_job.cc
diff --git a/net/http/http_stream_factory_impl_job.cc b/net/http/http_stream_factory_impl_job.cc
index 706ff377a7f5d12feb099bc797a97610984da590..481a740d2a6bd00e9f7767606f4a4020524eca9d 100644
--- a/net/http/http_stream_factory_impl_job.cc
+++ b/net/http/http_stream_factory_impl_job.cc
@@ -37,6 +37,8 @@
#include "net/http/http_stream_factory.h"
#include "net/http/http_stream_factory_impl_request.h"
#include "net/log/net_log.h"
+#include "net/log/net_log_event_type.h"
+#include "net/log/net_log_source_type.h"
#include "net/quic/chromium/quic_http_stream.h"
#include "net/socket/client_socket_handle.h"
#include "net/socket/client_socket_pool.h"
@@ -181,7 +183,7 @@ HttpStreamFactoryImpl::Job::Job(Delegate* delegate,
priority_(priority),
server_ssl_config_(server_ssl_config),
proxy_ssl_config_(proxy_ssl_config),
- net_log_(BoundNetLog::Make(net_log, NetLog::SOURCE_HTTP_STREAM_JOB)),
+ net_log_(BoundNetLog::Make(net_log, NetLogSourceType::HTTP_STREAM_JOB)),
io_callback_(base::Bind(&Job::OnIOComplete, base::Unretained(this))),
connection_(new ClientSocketHandle),
session_(session),
@@ -237,7 +239,7 @@ HttpStreamFactoryImpl::Job::Job(Delegate* delegate,
}
HttpStreamFactoryImpl::Job::~Job() {
- net_log_.EndEvent(NetLog::TYPE_HTTP_STREAM_JOB);
+ net_log_.EndEvent(NetLogEventType::HTTP_STREAM_JOB);
// When we're in a partially constructed state, waiting for the user to
// provide certificate handling information or authentication, we can't reuse
@@ -302,7 +304,7 @@ void HttpStreamFactoryImpl::Job::Resume() {
}
void HttpStreamFactoryImpl::Job::Orphan() {
- net_log_.AddEvent(NetLog::TYPE_HTTP_STREAM_JOB_ORPHANED);
+ net_log_.AddEvent(NetLogEventType::HTTP_STREAM_JOB_ORPHANED);
if (delegate_->for_websockets()) {
// We cancel this job because a WebSocketHandshakeStream can't be created
@@ -694,11 +696,11 @@ int HttpStreamFactoryImpl::Job::DoStart() {
if (net_log) {
net_log_.BeginEvent(
- NetLog::TYPE_HTTP_STREAM_JOB,
+ NetLogEventType::HTTP_STREAM_JOB,
base::Bind(&NetLogHttpStreamJobCallback, net_log->source(),
&request_info_.url, &origin_url_, &alternative_service_,
priority_));
- net_log->AddEvent(NetLog::TYPE_HTTP_STREAM_REQUEST_STARTED_JOB,
+ net_log->AddEvent(NetLogEventType::HTTP_STREAM_REQUEST_STARTED_JOB,
net_log_.source().ToEventParametersCallback());
}
@@ -1024,7 +1026,7 @@ int HttpStreamFactoryImpl::Job::DoInitConnectionComplete(int result) {
was_npn_negotiated_ = true;
negotiated_protocol_ = ssl_socket->GetNegotiatedProtocol();
net_log_.AddEvent(
- NetLog::TYPE_HTTP_STREAM_REQUEST_PROTO,
+ NetLogEventType::HTTP_STREAM_REQUEST_PROTO,
base::Bind(&NetLogHttpStreamProtoCallback, negotiated_protocol_));
if (negotiated_protocol_ == kProtoHTTP2)
SwitchToSpdyMode();
« no previous file with comments | « net/http/http_proxy_client_socket_wrapper.cc ('k') | net/http/http_stream_factory_impl_job_controller.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698