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

Side by Side Diff: runtime/vm/service/client.dart

Issue 474633002: Optional binary payloads in VM service events. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 6 years, 4 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 | Annotate | Revision Log
« no previous file with comments | « runtime/vm/service.cc ('k') | runtime/vm/service/vmservice.dart » ('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 (c) 2013, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 part of vmservice; 5 part of vmservice;
6 6
7 // A service client. 7 // A service client.
8 abstract class Client { 8 abstract class Client {
9 /// A port for receipt of asynchronous service events. 9 /// A port for receipt of asynchronous service events.
10 final RawReceivePort eventPort = new RawReceivePort(); 10 final RawReceivePort eventPort = new RawReceivePort();
(...skipping 16 matching lines...) Expand all
27 void onMessage(var seq, Message message) { 27 void onMessage(var seq, Message message) {
28 // Call post when the response arrives. 28 // Call post when the response arrives.
29 message.response.then((response) { 29 message.response.then((response) {
30 post(seq, response); 30 post(seq, response);
31 }); 31 });
32 // Send message to service. 32 // Send message to service.
33 service.route(message); 33 service.route(message);
34 } 34 }
35 35
36 /// When implementing, responsible for sending [response] to the client. 36 /// When implementing, responsible for sending [response] to the client.
37 void post(var seq, String response); 37 void post(var seq, dynamic response);
38 38
39 dynamic toJson() { 39 dynamic toJson() {
40 return { 40 return {
41 }; 41 };
42 } 42 }
43 } 43 }
OLDNEW
« no previous file with comments | « runtime/vm/service.cc ('k') | runtime/vm/service/vmservice.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698