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

Unified Diff: runtime/bin/websocket.dart

Issue 10377124: Add a hash code to client and server web socket connections (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Addressed review comments from ager@ Created 8 years, 7 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 | « no previous file | runtime/bin/websocket_impl.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/bin/websocket.dart
diff --git a/runtime/bin/websocket.dart b/runtime/bin/websocket.dart
index 93ac92c3010fac8096b4c473c98b15c6f3266910..80c8d877f4b25d6b2d7ae6165c81858ddc8355a5 100644
--- a/runtime/bin/websocket.dart
+++ b/runtime/bin/websocket.dart
@@ -36,7 +36,7 @@ interface WebSocketHandler default _WebSocketHandler {
/**
* Server web socket connection.
*/
-interface WebSocketConnection {
+interface WebSocketConnection extends Hashable {
/**
* Sets the callback to be called when a message have been
* received. The type on [message] is either [:String:] or
@@ -68,13 +68,19 @@ interface WebSocketConnection {
* and [reason] are [:null:].
*/
close([int status, String reason]);
+
+ /**
+ * WebSocketConnection is hashable.
+ */
+ int hashCode();
}
/**
* Client web socket connection.
*/
-interface WebSocketClientConnection default _WebSocketClientConnection {
+interface WebSocketClientConnection
+ extends Hashable default _WebSocketClientConnection {
/**
* Creates a new web socket client connection based on a HTTP client
* connection. The HTTP client connection must be freshly opened.
@@ -138,6 +144,11 @@ interface WebSocketClientConnection default _WebSocketClientConnection {
* and [reason] are [:null:].
*/
close([int status, String reason]);
+
+ /**
+ * WebSocketClientConnection is hashable.
+ */
+ int hashCode();
}
« no previous file with comments | « no previous file | runtime/bin/websocket_impl.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698