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

Side by Side Diff: services/http_server/public/http_server_factory.mojom

Issue 953513002: http_server: accept full NetAddress in CreateHttpServer. (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: Created 5 years, 9 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 unified diff | Download patch
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 module http_server; 5 module http_server;
6 6
7 import "mojo/services/network/public/interfaces/net_address.mojom";
7 import "services/http_server/public/http_server.mojom"; 8 import "services/http_server/public/http_server.mojom";
8 9
9 interface HttpServerFactory { 10 interface HttpServerFactory {
10 // Creates an http server running on the specified TCP port. If |port| is 0, 11 // Creates an http server running on the specified TCP port. If |port| is 0,
11 // the operating system will pick one of available ports. You can use 12 // the operating system will pick one of available ports. You can use
12 // HttpServer::GetPort() to retrieve the allocated port. 13 // HttpServer::GetPort() to retrieve the allocated port.
13 // 14 //
14 // Only one backing server will be created for each port. It will be shared 15 // Only one backing server will be created for each port. It will be shared
15 // among clients, if more than one client requests a server running on a 16 // among clients, if more than one client requests a server running on a
16 // particular port. 17 // particular port.
17 // 18 //
18 // TODO(ppi): would it be better to create a server only for the first caller 19 // TODO(ppi): would it be better to create a server only for the first caller
19 // and require the access to it to be explicitly shared by the party that 20 // and require the access to it to be explicitly shared by the party that
20 // requests it first? 21 // requests it first?
21 CreateHttpServer(HttpServer& server_request, uint16 port); 22 CreateHttpServer(HttpServer& server_request, mojo.NetAddress? local_address);
22 }; 23 };
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698