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

Unified Diff: mojo/edk/system/ports/node.h

Issue 1785843002: [mojo] Implement pipe fusion API (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « mojo/edk/system/node_controller.cc ('k') | mojo/edk/system/ports/node.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: mojo/edk/system/ports/node.h
diff --git a/mojo/edk/system/ports/node.h b/mojo/edk/system/ports/node.h
index cb1d5fd2b1dadf4e1e39e95b062277d8378ef5d1..2dc513c0c5f656cc2ab93a2c3754c43b044b1f87 100644
--- a/mojo/edk/system/ports/node.h
+++ b/mojo/edk/system/ports/node.h
@@ -137,6 +137,12 @@ class Node {
const NodeName& destination_node_name,
const PortName& destination_port_name);
+ // Like above but merges two ports local to this node. Because both ports are
+ // local this can also verify that neither port has been written to before the
+ // merge. If this fails for any reason, both ports are closed. Otherwise OK
+ // is returned and the ports' receiving peers are connected to each other.
+ int MergeLocalPorts(const PortRef& port0_ref, const PortRef& port1_ref);
+
// Called to inform this node that communication with another node is lost
// indefinitely. This triggers cleanup of ports bound to this node.
int LostConnectionToNode(const NodeName& node_name);
@@ -157,6 +163,7 @@ class Node {
scoped_refptr<Port> GetPort(const PortName& port_name);
scoped_refptr<Port> GetPort_Locked(const PortName& port_name);
+ int MergePorts_Locked(const PortRef& port0_ref, const PortRef& port1_ref);
void WillSendPort_Locked(Port* port,
const NodeName& to_node_name,
PortName* port_name,
« no previous file with comments | « mojo/edk/system/node_controller.cc ('k') | mojo/edk/system/ports/node.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698