| 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 #include "vm/service.h" | 5 #include "vm/service.h" |
| 6 | 6 |
| 7 #include "include/dart_api.h" | 7 #include "include/dart_api.h" |
| 8 #include "include/dart_native_api.h" | 8 #include "include/dart_native_api.h" |
| 9 #include "platform/globals.h" | 9 #include "platform/globals.h" |
| 10 | 10 |
| (...skipping 104 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 115 | 115 |
| 116 // These are the set of streams known to the core VM. | 116 // These are the set of streams known to the core VM. |
| 117 StreamInfo Service::vm_stream("VM"); | 117 StreamInfo Service::vm_stream("VM"); |
| 118 StreamInfo Service::isolate_stream("Isolate"); | 118 StreamInfo Service::isolate_stream("Isolate"); |
| 119 StreamInfo Service::debug_stream("Debug"); | 119 StreamInfo Service::debug_stream("Debug"); |
| 120 StreamInfo Service::gc_stream("GC"); | 120 StreamInfo Service::gc_stream("GC"); |
| 121 StreamInfo Service::echo_stream("_Echo"); | 121 StreamInfo Service::echo_stream("_Echo"); |
| 122 StreamInfo Service::graph_stream("_Graph"); | 122 StreamInfo Service::graph_stream("_Graph"); |
| 123 StreamInfo Service::logging_stream("_Logging"); | 123 StreamInfo Service::logging_stream("_Logging"); |
| 124 StreamInfo Service::extension_stream("Extension"); | 124 StreamInfo Service::extension_stream("Extension"); |
| 125 StreamInfo Service::timeline_stream("Timeline"); |
| 125 | 126 |
| 126 static StreamInfo* streams_[] = { | 127 static StreamInfo* streams_[] = { |
| 127 &Service::vm_stream, | 128 &Service::vm_stream, |
| 128 &Service::isolate_stream, | 129 &Service::isolate_stream, |
| 129 &Service::debug_stream, | 130 &Service::debug_stream, |
| 130 &Service::gc_stream, | 131 &Service::gc_stream, |
| 131 &Service::echo_stream, | 132 &Service::echo_stream, |
| 132 &Service::graph_stream, | 133 &Service::graph_stream, |
| 133 &Service::logging_stream, | 134 &Service::logging_stream, |
| 134 &Service::extension_stream, | 135 &Service::extension_stream, |
| 136 &Service::timeline_stream, |
| 135 }; | 137 }; |
| 136 | 138 |
| 137 | 139 |
| 138 bool Service::ListenStream(const char* stream_id) { | 140 bool Service::ListenStream(const char* stream_id) { |
| 139 if (FLAG_trace_service) { | 141 if (FLAG_trace_service) { |
| 140 OS::Print("vm-service: starting stream '%s'\n", | 142 OS::Print("vm-service: starting stream '%s'\n", |
| 141 stream_id); | 143 stream_id); |
| 142 } | 144 } |
| 143 intptr_t num_streams = sizeof(streams_) / | 145 intptr_t num_streams = sizeof(streams_) / |
| 144 sizeof(streams_[0]); | 146 sizeof(streams_[0]); |
| (...skipping 3951 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4096 if (strcmp(method_name, method.name) == 0) { | 4098 if (strcmp(method_name, method.name) == 0) { |
| 4097 return &method; | 4099 return &method; |
| 4098 } | 4100 } |
| 4099 } | 4101 } |
| 4100 return NULL; | 4102 return NULL; |
| 4101 } | 4103 } |
| 4102 | 4104 |
| 4103 #endif // !PRODUCT | 4105 #endif // !PRODUCT |
| 4104 | 4106 |
| 4105 } // namespace dart | 4107 } // namespace dart |
| OLD | NEW |