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

Unified Diff: mojo/services/public/interfaces/network/tcp_socket.mojom

Issue 613683006: Add TCP socket mojo interfaces (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 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
Index: mojo/services/public/interfaces/network/tcp_socket.mojom
diff --git a/mojo/services/public/interfaces/network/tcp_socket.mojom b/mojo/services/public/interfaces/network/tcp_socket.mojom
new file mode 100644
index 0000000000000000000000000000000000000000..691c039847e7f0ebc1c91fa182cea0b5fe779f9b
--- /dev/null
+++ b/mojo/services/public/interfaces/network/tcp_socket.mojom
@@ -0,0 +1,28 @@
+// Copyright 2014 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.
+
+import "mojo/services/public/interfaces/network/net_address.mojom"
+import "mojo/services/public/interfaces/network/network_error.mojom"
+
+module mojo {
+
+interface TCPSocket {
yzshen1 2014/09/30 00:21:52 Do we need a Bind() function here?
+ Connect(NetAddress addr,
+ handle<data_pipe_consumer> send_stream,
+ handle<data_pipe_producer> receive_stream) =>
+ (NetworkError result,
+ NetAddress local_address,
yzshen1 2014/09/30 00:21:52 you might want to use NetAddress? here, so that it
+ NetAddress remote_address);
+
+ // Closes the connection. If Close() is not called, the connection will be
+ // implicitly closes when the TCPSocket has been deleted.
viettrungluu 2014/09/29 23:50:14 "deleted"?
+ Close();
viettrungluu 2014/09/29 23:50:14 Is this really necessary at all? In general, this
+
+ // Controls whether small writes are coalesced to make TCP segments, and
+ // instead delivers data immediately. The default value is true (coalescing
+ // enabled).
+ SetCoaleseWrites(bool coalesce);
+};
+
+}

Powered by Google App Engine
This is Rietveld 408576698