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

Unified Diff: net/udp/udp_net_log_parameters.cc

Issue 2508593002: net: move udp directory into socket (Closed)
Patch Set: revert sys/socket.h change Created 4 years, 1 month 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/udp/udp_net_log_parameters.h ('k') | net/udp/udp_server_socket.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/udp/udp_net_log_parameters.cc
diff --git a/net/udp/udp_net_log_parameters.cc b/net/udp/udp_net_log_parameters.cc
deleted file mode 100644
index 471f4e475f6adba88c23fd6bb330fa65836803d0..0000000000000000000000000000000000000000
--- a/net/udp/udp_net_log_parameters.cc
+++ /dev/null
@@ -1,60 +0,0 @@
-// Copyright (c) 2012 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#include "net/udp/udp_net_log_parameters.h"
-
-#include <utility>
-
-#include "base/bind.h"
-#include "base/strings/string_number_conversions.h"
-#include "base/values.h"
-#include "net/base/ip_endpoint.h"
-
-namespace net {
-
-namespace {
-
-std::unique_ptr<base::Value> NetLogUDPDataTranferCallback(
- int byte_count,
- const char* bytes,
- const IPEndPoint* address,
- NetLogCaptureMode capture_mode) {
- std::unique_ptr<base::DictionaryValue> dict(new base::DictionaryValue());
- dict->SetInteger("byte_count", byte_count);
- if (capture_mode.include_socket_bytes())
- dict->SetString("hex_encoded_bytes", base::HexEncode(bytes, byte_count));
- if (address)
- dict->SetString("address", address->ToString());
- return std::move(dict);
-}
-
-std::unique_ptr<base::Value> NetLogUDPConnectCallback(
- const IPEndPoint* address,
- NetworkChangeNotifier::NetworkHandle network,
- NetLogCaptureMode /* capture_mode */) {
- std::unique_ptr<base::DictionaryValue> dict(new base::DictionaryValue());
- dict->SetString("address", address->ToString());
- if (network != NetworkChangeNotifier::kInvalidNetworkHandle)
- dict->SetInteger("bound_to_network", network);
- return std::move(dict);
-}
-
-} // namespace
-
-NetLogParametersCallback CreateNetLogUDPDataTranferCallback(
- int byte_count,
- const char* bytes,
- const IPEndPoint* address) {
- DCHECK(bytes);
- return base::Bind(&NetLogUDPDataTranferCallback, byte_count, bytes, address);
-}
-
-NetLogParametersCallback CreateNetLogUDPConnectCallback(
- const IPEndPoint* address,
- NetworkChangeNotifier::NetworkHandle network) {
- DCHECK(address);
- return base::Bind(&NetLogUDPConnectCallback, address, network);
-}
-
-} // namespace net
« no previous file with comments | « net/udp/udp_net_log_parameters.h ('k') | net/udp/udp_server_socket.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698