OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 library tracing_mojom; | 5 library tracing_mojom; |
6 import 'dart:async'; | 6 import 'dart:async'; |
7 import 'package:mojo/bindings.dart' as bindings; | 7 import 'package:mojo/bindings.dart' as bindings; |
8 import 'package:mojo/core.dart' as core; | 8 import 'package:mojo/core.dart' as core; |
9 import 'package:mojo/mojo/bindings/types/service_describer.mojom.dart' as servic
e_describer; | 9 import 'package:mojo/mojo/bindings/types/service_describer.mojom.dart' as servic
e_describer; |
10 | 10 |
(...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
87 "recorder: $recorder" ")"; | 87 "recorder: $recorder" ")"; |
88 } | 88 } |
89 | 89 |
90 Map toJson() { | 90 Map toJson() { |
91 throw new bindings.MojoCodecError( | 91 throw new bindings.MojoCodecError( |
92 'Object containing handles cannot be encoded to JSON.'); | 92 'Object containing handles cannot be encoded to JSON.'); |
93 } | 93 } |
94 } | 94 } |
95 | 95 |
96 | 96 |
97 | |
98 | |
99 class _TraceProviderStopTracingParams extends bindings.Struct { | 97 class _TraceProviderStopTracingParams extends bindings.Struct { |
100 static const List<bindings.StructDataHeader> kVersions = const [ | 98 static const List<bindings.StructDataHeader> kVersions = const [ |
101 const bindings.StructDataHeader(8, 0) | 99 const bindings.StructDataHeader(8, 0) |
102 ]; | 100 ]; |
103 | 101 |
104 _TraceProviderStopTracingParams() : super(kVersions.last.size); | 102 _TraceProviderStopTracingParams() : super(kVersions.last.size); |
105 | 103 |
106 static _TraceProviderStopTracingParams deserialize(bindings.Message message) { | 104 static _TraceProviderStopTracingParams deserialize(bindings.Message message) { |
107 var decoder = new bindings.Decoder(message); | 105 var decoder = new bindings.Decoder(message); |
108 var result = decode(decoder); | 106 var result = decode(decoder); |
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
147 return "_TraceProviderStopTracingParams("")"; | 145 return "_TraceProviderStopTracingParams("")"; |
148 } | 146 } |
149 | 147 |
150 Map toJson() { | 148 Map toJson() { |
151 Map map = new Map(); | 149 Map map = new Map(); |
152 return map; | 150 return map; |
153 } | 151 } |
154 } | 152 } |
155 | 153 |
156 | 154 |
157 | |
158 | |
159 class _TraceRecorderRecordParams extends bindings.Struct { | 155 class _TraceRecorderRecordParams extends bindings.Struct { |
160 static const List<bindings.StructDataHeader> kVersions = const [ | 156 static const List<bindings.StructDataHeader> kVersions = const [ |
161 const bindings.StructDataHeader(16, 0) | 157 const bindings.StructDataHeader(16, 0) |
162 ]; | 158 ]; |
163 String json = null; | 159 String json = null; |
164 | 160 |
165 _TraceRecorderRecordParams() : super(kVersions.last.size); | 161 _TraceRecorderRecordParams() : super(kVersions.last.size); |
166 | 162 |
167 static _TraceRecorderRecordParams deserialize(bindings.Message message) { | 163 static _TraceRecorderRecordParams deserialize(bindings.Message message) { |
168 var decoder = new bindings.Decoder(message); | 164 var decoder = new bindings.Decoder(message); |
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
221 } | 217 } |
222 | 218 |
223 Map toJson() { | 219 Map toJson() { |
224 Map map = new Map(); | 220 Map map = new Map(); |
225 map["json"] = json; | 221 map["json"] = json; |
226 return map; | 222 return map; |
227 } | 223 } |
228 } | 224 } |
229 | 225 |
230 | 226 |
231 | |
232 | |
233 class _TraceCollectorStartParams extends bindings.Struct { | 227 class _TraceCollectorStartParams extends bindings.Struct { |
234 static const List<bindings.StructDataHeader> kVersions = const [ | 228 static const List<bindings.StructDataHeader> kVersions = const [ |
235 const bindings.StructDataHeader(24, 0) | 229 const bindings.StructDataHeader(24, 0) |
236 ]; | 230 ]; |
237 core.MojoDataPipeProducer stream = null; | 231 core.MojoDataPipeProducer stream = null; |
238 String categories = null; | 232 String categories = null; |
239 | 233 |
240 _TraceCollectorStartParams() : super(kVersions.last.size); | 234 _TraceCollectorStartParams() : super(kVersions.last.size); |
241 | 235 |
242 static _TraceCollectorStartParams deserialize(bindings.Message message) { | 236 static _TraceCollectorStartParams deserialize(bindings.Message message) { |
(...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
307 "categories: $categories" ")"; | 301 "categories: $categories" ")"; |
308 } | 302 } |
309 | 303 |
310 Map toJson() { | 304 Map toJson() { |
311 throw new bindings.MojoCodecError( | 305 throw new bindings.MojoCodecError( |
312 'Object containing handles cannot be encoded to JSON.'); | 306 'Object containing handles cannot be encoded to JSON.'); |
313 } | 307 } |
314 } | 308 } |
315 | 309 |
316 | 310 |
317 | |
318 | |
319 class _TraceCollectorStopAndFlushParams extends bindings.Struct { | 311 class _TraceCollectorStopAndFlushParams extends bindings.Struct { |
320 static const List<bindings.StructDataHeader> kVersions = const [ | 312 static const List<bindings.StructDataHeader> kVersions = const [ |
321 const bindings.StructDataHeader(8, 0) | 313 const bindings.StructDataHeader(8, 0) |
322 ]; | 314 ]; |
323 | 315 |
324 _TraceCollectorStopAndFlushParams() : super(kVersions.last.size); | 316 _TraceCollectorStopAndFlushParams() : super(kVersions.last.size); |
325 | 317 |
326 static _TraceCollectorStopAndFlushParams deserialize(bindings.Message message)
{ | 318 static _TraceCollectorStopAndFlushParams deserialize(bindings.Message message)
{ |
327 var decoder = new bindings.Decoder(message); | 319 var decoder = new bindings.Decoder(message); |
328 var result = decode(decoder); | 320 var result = decode(decoder); |
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
366 String toString() { | 358 String toString() { |
367 return "_TraceCollectorStopAndFlushParams("")"; | 359 return "_TraceCollectorStopAndFlushParams("")"; |
368 } | 360 } |
369 | 361 |
370 Map toJson() { | 362 Map toJson() { |
371 Map map = new Map(); | 363 Map map = new Map(); |
372 return map; | 364 return map; |
373 } | 365 } |
374 } | 366 } |
375 | 367 |
376 | |
377 | |
378 | |
379 const int _TraceProvider_startTracingName = 0; | 368 const int _TraceProvider_startTracingName = 0; |
380 const int _TraceProvider_stopTracingName = 1; | 369 const int _TraceProvider_stopTracingName = 1; |
381 | 370 |
382 | |
383 | |
384 class _TraceProviderServiceDescription implements service_describer.ServiceDescr
iption { | 371 class _TraceProviderServiceDescription implements service_describer.ServiceDescr
iption { |
385 dynamic getTopLevelInterface([Function responseFactory]) => | 372 dynamic getTopLevelInterface([Function responseFactory]) => |
386 responseFactory(null); | 373 responseFactory(null); |
387 | 374 |
388 dynamic getTypeDefinition(String typeKey, [Function responseFactory]) => | 375 dynamic getTypeDefinition(String typeKey, [Function responseFactory]) => |
389 responseFactory(null); | 376 responseFactory(null); |
390 | 377 |
391 dynamic getAllTypeDefinitions([Function responseFactory]) => | 378 dynamic getAllTypeDefinitions([Function responseFactory]) => |
392 responseFactory(null); | 379 responseFactory(null); |
393 } | 380 } |
(...skipping 183 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
577 static service_describer.ServiceDescription get serviceDescription { | 564 static service_describer.ServiceDescription get serviceDescription { |
578 if (_cachedServiceDescription == null) { | 565 if (_cachedServiceDescription == null) { |
579 _cachedServiceDescription = new _TraceProviderServiceDescription(); | 566 _cachedServiceDescription = new _TraceProviderServiceDescription(); |
580 } | 567 } |
581 return _cachedServiceDescription; | 568 return _cachedServiceDescription; |
582 } | 569 } |
583 } | 570 } |
584 | 571 |
585 const int _TraceRecorder_recordName = 0; | 572 const int _TraceRecorder_recordName = 0; |
586 | 573 |
587 | |
588 | |
589 class _TraceRecorderServiceDescription implements service_describer.ServiceDescr
iption { | 574 class _TraceRecorderServiceDescription implements service_describer.ServiceDescr
iption { |
590 dynamic getTopLevelInterface([Function responseFactory]) => | 575 dynamic getTopLevelInterface([Function responseFactory]) => |
591 responseFactory(null); | 576 responseFactory(null); |
592 | 577 |
593 dynamic getTypeDefinition(String typeKey, [Function responseFactory]) => | 578 dynamic getTypeDefinition(String typeKey, [Function responseFactory]) => |
594 responseFactory(null); | 579 responseFactory(null); |
595 | 580 |
596 dynamic getAllTypeDefinitions([Function responseFactory]) => | 581 dynamic getAllTypeDefinitions([Function responseFactory]) => |
597 responseFactory(null); | 582 responseFactory(null); |
598 } | 583 } |
(...skipping 171 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
770 if (_cachedServiceDescription == null) { | 755 if (_cachedServiceDescription == null) { |
771 _cachedServiceDescription = new _TraceRecorderServiceDescription(); | 756 _cachedServiceDescription = new _TraceRecorderServiceDescription(); |
772 } | 757 } |
773 return _cachedServiceDescription; | 758 return _cachedServiceDescription; |
774 } | 759 } |
775 } | 760 } |
776 | 761 |
777 const int _TraceCollector_startName = 0; | 762 const int _TraceCollector_startName = 0; |
778 const int _TraceCollector_stopAndFlushName = 1; | 763 const int _TraceCollector_stopAndFlushName = 1; |
779 | 764 |
780 | |
781 | |
782 class _TraceCollectorServiceDescription implements service_describer.ServiceDesc
ription { | 765 class _TraceCollectorServiceDescription implements service_describer.ServiceDesc
ription { |
783 dynamic getTopLevelInterface([Function responseFactory]) => | 766 dynamic getTopLevelInterface([Function responseFactory]) => |
784 responseFactory(null); | 767 responseFactory(null); |
785 | 768 |
786 dynamic getTypeDefinition(String typeKey, [Function responseFactory]) => | 769 dynamic getTypeDefinition(String typeKey, [Function responseFactory]) => |
787 responseFactory(null); | 770 responseFactory(null); |
788 | 771 |
789 dynamic getAllTypeDefinitions([Function responseFactory]) => | 772 dynamic getAllTypeDefinitions([Function responseFactory]) => |
790 responseFactory(null); | 773 responseFactory(null); |
791 } | 774 } |
(...skipping 183 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
975 static service_describer.ServiceDescription get serviceDescription { | 958 static service_describer.ServiceDescription get serviceDescription { |
976 if (_cachedServiceDescription == null) { | 959 if (_cachedServiceDescription == null) { |
977 _cachedServiceDescription = new _TraceCollectorServiceDescription(); | 960 _cachedServiceDescription = new _TraceCollectorServiceDescription(); |
978 } | 961 } |
979 return _cachedServiceDescription; | 962 return _cachedServiceDescription; |
980 } | 963 } |
981 } | 964 } |
982 | 965 |
983 | 966 |
984 | 967 |
OLD | NEW |