Chromium Code Reviews| Index: pkg/analyzer/lib/instrumentation/instrumentation.dart |
| diff --git a/pkg/analyzer/lib/instrumentation/instrumentation.dart b/pkg/analyzer/lib/instrumentation/instrumentation.dart |
| index abc2799315e8927bd90df7a6999f164dedddb0e3..49919fc642a0fbe0b7412452ac9b4d80dac42f37 100644 |
| --- a/pkg/analyzer/lib/instrumentation/instrumentation.dart |
| +++ b/pkg/analyzer/lib/instrumentation/instrumentation.dart |
| @@ -28,6 +28,11 @@ abstract class InstrumentationServer { |
| String get sessionId; |
| /** |
| + * A user-friendly description of this instrumentation server. |
| + */ |
|
skybrian
2017/03/01 02:06:01
Possible security issue here (or maybe just a brok
devoncarew
2017/03/01 02:30:27
Hmm, I think I'll move to escaping the describe re
|
| + String get describe; |
| + |
| + /** |
| * Pass the given [message] to the instrumentation server so that it will be |
| * logged with other messages. |
| * |
| @@ -110,6 +115,8 @@ class InstrumentationService { |
| */ |
| String get _timestamp => new DateTime.now().millisecondsSinceEpoch.toString(); |
| + InstrumentationServer get instrumentationServer => _instrumentationServer; |
| + |
| /** |
| * Log that the given analysis [task] is being performed in the given |
| * [context]. |
| @@ -370,6 +377,13 @@ class MulticastInstrumentationServer implements InstrumentationServer { |
| String get sessionId => _servers[0].sessionId; |
| @override |
| + String get describe { |
| + return _servers |
| + .map((InstrumentationServer server) => server.describe) |
| + .join("\n"); |
|
skybrian
2017/03/01 02:06:01
<br>
skybrian
2017/03/01 02:07:47
(Or maybe surround each item with <div>?)
|
| + } |
| + |
| + @override |
| void log(String message) { |
| for (InstrumentationServer server in _servers) { |
| server.log(message); |