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

Side by Side Diff: services/http_server/http_server.cc

Issue 789243002: Restructure public side of network service. (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: Rebase Created 6 years 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 unified diff | Download patch
« no previous file with comments | « services/http_server/BUILD.gn ('k') | services/js/BUILD.gn » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 <stdio.h> 5 #include <stdio.h>
6 6
7 #if defined(OS_WIN) 7 #if defined(OS_WIN)
8 #include <winsock2.h> 8 #include <winsock2.h>
9 #elif defined(OS_POSIX) 9 #elif defined(OS_POSIX)
10 #include <arpa/inet.h> 10 #include <arpa/inet.h>
11 #endif 11 #endif
12 12
13 #include "base/bind.h" 13 #include "base/bind.h"
14 #include "base/format_macros.h" 14 #include "base/format_macros.h"
15 #include "base/memory/scoped_ptr.h" 15 #include "base/memory/scoped_ptr.h"
16 #include "base/memory/weak_ptr.h" 16 #include "base/memory/weak_ptr.h"
17 #include "base/strings/stringprintf.h" 17 #include "base/strings/stringprintf.h"
18 #include "mojo/public/c/system/main.h" 18 #include "mojo/public/c/system/main.h"
19 #include "mojo/public/cpp/application/application_delegate.h" 19 #include "mojo/public/cpp/application/application_delegate.h"
20 #include "mojo/public/cpp/application/application_impl.h" 20 #include "mojo/public/cpp/application/application_impl.h"
21 #include "mojo/public/cpp/application/application_runner.h" 21 #include "mojo/public/cpp/application/application_runner.h"
22 #include "mojo/public/cpp/application/interface_factory.h" 22 #include "mojo/public/cpp/application/interface_factory.h"
23 #include "mojo/public/cpp/environment/async_waiter.h" 23 #include "mojo/public/cpp/environment/async_waiter.h"
24 #include "mojo/public/cpp/system/data_pipe.h" 24 #include "mojo/public/cpp/system/data_pipe.h"
25 #include "mojo/services/public/interfaces/network/network_service.mojom.h" 25 #include "mojo/services/network/public/interfaces/network_service.mojom.h"
26 #include "services/http_server/http_request_parser.h" 26 #include "services/http_server/http_request_parser.h"
27 #include "services/http_server/public/http_request.mojom.h" 27 #include "services/http_server/public/http_request.mojom.h"
28 #include "services/http_server/public/http_response.mojom.h" 28 #include "services/http_server/public/http_response.mojom.h"
29 #include "services/http_server/public/http_server.mojom.h" 29 #include "services/http_server/public/http_server.mojom.h"
30 #include "services/http_server/public/http_server_util.h" 30 #include "services/http_server/public/http_server_util.h"
31 #include "third_party/re2/re2/re2.h" 31 #include "third_party/re2/re2/re2.h"
32 32
33 using mojo::AsyncWaiter; 33 using mojo::AsyncWaiter;
34 using mojo::ScopedDataPipeConsumerHandle; 34 using mojo::ScopedDataPipeConsumerHandle;
35 using mojo::ScopedDataPipeProducerHandle; 35 using mojo::ScopedDataPipeProducerHandle;
(...skipping 447 matching lines...) Expand 10 before | Expand all | Expand 10 after
483 } 483 }
484 } 484 }
485 } 485 }
486 486
487 } // namespace http_server 487 } // namespace http_server
488 488
489 MojoResult MojoMain(MojoHandle shell_handle) { 489 MojoResult MojoMain(MojoHandle shell_handle) {
490 mojo::ApplicationRunner runner(new http_server::HttpServerApp); 490 mojo::ApplicationRunner runner(new http_server::HttpServerApp);
491 return runner.Run(shell_handle); 491 return runner.Run(shell_handle);
492 } 492 }
OLDNEW
« no previous file with comments | « services/http_server/BUILD.gn ('k') | services/js/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698