OLD | NEW |
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 #ifndef VM_JSON_STREAM_H_ | 5 #ifndef VM_JSON_STREAM_H_ |
6 #define VM_JSON_STREAM_H_ | 6 #define VM_JSON_STREAM_H_ |
7 | 7 |
8 #include "include/dart_api.h" // for Dart_Port | 8 #include "include/dart_api.h" // for Dart_Port |
9 #include "platform/json.h" | 9 #include "platform/json.h" |
10 #include "vm/allocation.h" | 10 #include "vm/allocation.h" |
(...skipping 16 matching lines...) Expand all Loading... |
27 class Zone; | 27 class Zone; |
28 | 28 |
29 | 29 |
30 enum JSONRpcErrorCode { | 30 enum JSONRpcErrorCode { |
31 kParseError = -32700, | 31 kParseError = -32700, |
32 kInvalidRequest = -32600, | 32 kInvalidRequest = -32600, |
33 kMethodNotFound = -32601, | 33 kMethodNotFound = -32601, |
34 kInvalidParams = -32602, | 34 kInvalidParams = -32602, |
35 kInternalError = -32603, | 35 kInternalError = -32603, |
36 | 36 |
37 kVMMustBePaused = 100, | 37 // These must be kept in sync with vm/service/vmservice.dart. |
38 kNoBreakAtLine = 101, | 38 kInvalidStream = 100, |
39 kNoBreakAtFunction = 102, | 39 kStreamAlreadySubscribed = 101, |
| 40 kStreamNotSubscribed = 102, |
40 | 41 |
41 kProfilingDisabled = 200, | 42 kVMMustBePaused = 200, |
| 43 kNoBreakAtLine = 201, |
| 44 kNoBreakAtFunction = 202, |
| 45 |
| 46 kProfilingDisabled = 300, |
42 }; | 47 }; |
43 | 48 |
44 | 49 |
45 class JSONStream : ValueObject { | 50 class JSONStream : ValueObject { |
46 public: | 51 public: |
47 explicit JSONStream(intptr_t buf_size = 256); | 52 explicit JSONStream(intptr_t buf_size = 256); |
48 ~JSONStream(); | 53 ~JSONStream(); |
49 | 54 |
50 void Setup(Zone* zone, | 55 void Setup(Zone* zone, |
51 Dart_Port reply_port, | 56 Dart_Port reply_port, |
(...skipping 232 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
284 | 289 |
285 friend class JSONObject; | 290 friend class JSONObject; |
286 | 291 |
287 DISALLOW_ALLOCATION(); | 292 DISALLOW_ALLOCATION(); |
288 DISALLOW_COPY_AND_ASSIGN(JSONArray); | 293 DISALLOW_COPY_AND_ASSIGN(JSONArray); |
289 }; | 294 }; |
290 | 295 |
291 } // namespace dart | 296 } // namespace dart |
292 | 297 |
293 #endif // VM_JSON_STREAM_H_ | 298 #endif // VM_JSON_STREAM_H_ |
OLD | NEW |