OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "mojo/services/network/network_service_impl.h" | 5 #include "mojo/services/network/network_service_impl.h" |
6 | 6 |
7 #include "mojo/services/network/cookie_store_impl.h" | 7 #include "mojo/services/network/cookie_store_impl.h" |
| 8 #include "mojo/services/network/http_server_impl.h" |
8 #include "mojo/services/network/net_adapters.h" | 9 #include "mojo/services/network/net_adapters.h" |
9 #include "mojo/services/network/tcp_bound_socket_impl.h" | 10 #include "mojo/services/network/tcp_bound_socket_impl.h" |
10 #include "mojo/services/network/udp_socket_impl.h" | 11 #include "mojo/services/network/udp_socket_impl.h" |
11 #include "mojo/services/network/url_loader_impl.h" | 12 #include "mojo/services/network/url_loader_impl.h" |
12 #include "mojo/services/network/web_socket_impl.h" | 13 #include "mojo/services/network/web_socket_impl.h" |
13 #include "third_party/mojo/src/mojo/public/cpp/application/application_connectio
n.h" | 14 #include "third_party/mojo/src/mojo/public/cpp/application/application_connectio
n.h" |
14 | 15 |
15 namespace mojo { | 16 namespace mojo { |
16 | 17 |
17 NetworkServiceImpl::NetworkServiceImpl(ApplicationConnection* connection, | 18 NetworkServiceImpl::NetworkServiceImpl(ApplicationConnection* connection, |
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
68 | 69 |
69 void NetworkServiceImpl::CreateUDPSocket(InterfaceRequest<UDPSocket> request) { | 70 void NetworkServiceImpl::CreateUDPSocket(InterfaceRequest<UDPSocket> request) { |
70 // The lifetime of this UDPSocketImpl is bound to that of the underlying pipe. | 71 // The lifetime of this UDPSocketImpl is bound to that of the underlying pipe. |
71 new UDPSocketImpl(request.Pass()); | 72 new UDPSocketImpl(request.Pass()); |
72 } | 73 } |
73 | 74 |
74 void NetworkServiceImpl::CreateHttpServer( | 75 void NetworkServiceImpl::CreateHttpServer( |
75 NetAddressPtr local_address, | 76 NetAddressPtr local_address, |
76 HttpServerDelegatePtr delegate, | 77 HttpServerDelegatePtr delegate, |
77 const CreateHttpServerCallback& callback) { | 78 const CreateHttpServerCallback& callback) { |
78 // TODO(yzshen): implement this. | 79 HttpServerImpl::Create(local_address.Pass(), delegate.Pass(), callback); |
79 callback.Run(MakeNetworkError(net::ERR_NOT_IMPLEMENTED), nullptr); | |
80 } | 80 } |
81 | 81 |
82 } // namespace mojo | 82 } // namespace mojo |
OLD | NEW |