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

Side by Side Diff: pkg/analyzer/lib/instrumentation/instrumentation.dart

Issue 751063005: Instrumentation support (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Bump version number Created 6 years 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 | « no previous file | pkg/analyzer/pubspec.yaml » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
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
3 // BSD-style license that can be found in the LICENSE file.
4
5 library instrumentation;
6
7 /**
8 * The interface used by client code to communicate with an instrumentation
9 * server.
10 */
11 abstract class InstrumentationServer {
12 /**
13 * Pass the given [message] to the instrumentation server so that it will be
14 * logged with other messages.
15 */
16 void log(String message);
17
18 /**
19 * Signal that the client is done communicating with the instrumentation
20 * server. This method should be invoked exactly one time and no other methods
21 * should be invoked on this instance after this method has been invoked.
22 */
23 void shutdown();
24 }
25
26 /**
27 * An [InstrumentationServer] that ignores all instrumentation requests sent to
28 * it. It can be used when no instrumentation data is to be collected as a way
29 * to avoid needing to check for null values.
30 */
31 class NullInstrumentationServer implements InstrumentationServer {
32 /**
33 * Initialize a newly created instance of this class.
34 */
35 const NullInstrumentationServer();
36
37 @override
38 void log(String message) {
39 }
40
41 @override
42 void shutdown() {
43 }
44 }
OLDNEW
« no previous file with comments | « no previous file | pkg/analyzer/pubspec.yaml » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698