| OLD | NEW |
| 1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2014, 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 // This code was auto-generated, is not intended to be edited, and is subject to | 5 // This code was auto-generated, is not intended to be edited, and is subject to |
| 6 // significant change. Please see the README file for more information. | 6 // significant change. Please see the README file for more information. |
| 7 | 7 |
| 8 library engine.instrumentation; | 8 library engine.instrumentation; |
| 9 | 9 |
| 10 import 'java_core.dart'; | 10 import 'java_core.dart'; |
| (...skipping 266 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 277 InstrumentationBuilder record(Exception exception); | 277 InstrumentationBuilder record(Exception exception); |
| 278 } | 278 } |
| 279 | 279 |
| 280 /** | 280 /** |
| 281 * The instrumentation recording level representing (1) recording [EVERYTHING] r
ecording of | 281 * The instrumentation recording level representing (1) recording [EVERYTHING] r
ecording of |
| 282 * all instrumentation data, (2) recording only [METRICS] information, or (3) re
cording | 282 * all instrumentation data, (2) recording only [METRICS] information, or (3) re
cording |
| 283 * turned [OFF] in which case nothing is recorded. | 283 * turned [OFF] in which case nothing is recorded. |
| 284 */ | 284 */ |
| 285 class InstrumentationLevel extends Enum<InstrumentationLevel> { | 285 class InstrumentationLevel extends Enum<InstrumentationLevel> { |
| 286 /** Recording all instrumented information */ | 286 /** Recording all instrumented information */ |
| 287 static final InstrumentationLevel EVERYTHING = new InstrumentationLevel('EVERY
THING', 0); | 287 static const InstrumentationLevel EVERYTHING = const InstrumentationLevel('EVE
RYTHING', 0); |
| 288 | 288 |
| 289 /** Recording only metrics */ | 289 /** Recording only metrics */ |
| 290 static final InstrumentationLevel METRICS = new InstrumentationLevel('METRICS'
, 1); | 290 static const InstrumentationLevel METRICS = const InstrumentationLevel('METRIC
S', 1); |
| 291 | 291 |
| 292 /** Nothing recorded */ | 292 /** Nothing recorded */ |
| 293 static final InstrumentationLevel OFF = new InstrumentationLevel('OFF', 2); | 293 static const InstrumentationLevel OFF = const InstrumentationLevel('OFF', 2); |
| 294 | 294 |
| 295 static final List<InstrumentationLevel> values = [EVERYTHING, METRICS, OFF]; | 295 static const List<InstrumentationLevel> values = const [EVERYTHING, METRICS, O
FF]; |
| 296 | 296 |
| 297 static InstrumentationLevel fromString(String str) { | 297 static InstrumentationLevel fromString(String str) { |
| 298 if (str == "EVERYTHING") { | 298 if (str == "EVERYTHING") { |
| 299 return InstrumentationLevel.EVERYTHING; | 299 return InstrumentationLevel.EVERYTHING; |
| 300 } | 300 } |
| 301 if (str == "METRICS") { | 301 if (str == "METRICS") { |
| 302 return InstrumentationLevel.METRICS; | 302 return InstrumentationLevel.METRICS; |
| 303 } | 303 } |
| 304 if (str == "OFF") { | 304 if (str == "OFF") { |
| 305 return InstrumentationLevel.OFF; | 305 return InstrumentationLevel.OFF; |
| 306 } | 306 } |
| 307 throw new IllegalArgumentException("Unrecognised InstrumentationLevel"); | 307 throw new IllegalArgumentException("Unrecognised InstrumentationLevel"); |
| 308 } | 308 } |
| 309 | 309 |
| 310 InstrumentationLevel(String name, int ordinal) : super(name, ordinal); | 310 const InstrumentationLevel(String name, int ordinal) : super(name, ordinal); |
| 311 } | 311 } |
| 312 | 312 |
| 313 /** | 313 /** |
| 314 * The interface `InstrumentationLogger` defines the behavior of objects that ar
e used to log | 314 * The interface `InstrumentationLogger` defines the behavior of objects that ar
e used to log |
| 315 * instrumentation data. | 315 * instrumentation data. |
| 316 * | 316 * |
| 317 * For an example of using objects that implement this interface, see [Instrumen
tation]. | 317 * For an example of using objects that implement this interface, see [Instrumen
tation]. |
| 318 */ | 318 */ |
| 319 abstract class InstrumentationLogger { | 319 abstract class InstrumentationLogger { |
| 320 /** | 320 /** |
| 321 * Create a builder that can collect the data associated with an operation ide
ntified by the given | 321 * Create a builder that can collect the data associated with an operation ide
ntified by the given |
| 322 * name. | 322 * name. |
| 323 * | 323 * |
| 324 * @param name the name used to uniquely identify the operation | 324 * @param name the name used to uniquely identify the operation |
| 325 * @return the builder that was created | 325 * @return the builder that was created |
| 326 */ | 326 */ |
| 327 InstrumentationBuilder createBuilder(String name); | 327 InstrumentationBuilder createBuilder(String name); |
| 328 } | 328 } |
| OLD | NEW |