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 import 'dart:async'; | 5 import 'dart:async'; |
6 import 'dart:collection'; | 6 import 'dart:collection'; |
7 import 'dart:core'; | 7 import 'dart:core'; |
8 import 'dart:io' as io; | 8 import 'dart:io' as io; |
9 import 'dart:math' show max; | 9 import 'dart:math' show max; |
10 | 10 |
(...skipping 1446 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1457 final AnalysisServer analysisServer; | 1457 final AnalysisServer analysisServer; |
1458 | 1458 |
1459 /** | 1459 /** |
1460 * The [ResourceProvider] by which paths are converted into [Resource]s. | 1460 * The [ResourceProvider] by which paths are converted into [Resource]s. |
1461 */ | 1461 */ |
1462 final ResourceProvider resourceProvider; | 1462 final ResourceProvider resourceProvider; |
1463 | 1463 |
1464 ServerContextManagerCallbacks(this.analysisServer, this.resourceProvider); | 1464 ServerContextManagerCallbacks(this.analysisServer, this.resourceProvider); |
1465 | 1465 |
1466 @override | 1466 @override |
| 1467 NotificationManager get notificationManager => |
| 1468 analysisServer.notificationManager; |
| 1469 |
| 1470 @override |
1467 nd.AnalysisDriver addAnalysisDriver( | 1471 nd.AnalysisDriver addAnalysisDriver( |
1468 Folder folder, ContextRoot contextRoot, AnalysisOptions options) { | 1472 Folder folder, ContextRoot contextRoot, AnalysisOptions options) { |
1469 ContextBuilder builder = createContextBuilder(folder, options); | 1473 ContextBuilder builder = createContextBuilder(folder, options); |
1470 nd.AnalysisDriver analysisDriver = builder.buildDriver(contextRoot); | 1474 nd.AnalysisDriver analysisDriver = builder.buildDriver(contextRoot); |
1471 analysisDriver.results.listen((result) { | 1475 analysisDriver.results.listen((result) { |
1472 NotificationManager notificationManager = | 1476 NotificationManager notificationManager = |
1473 analysisServer.notificationManager; | 1477 analysisServer.notificationManager; |
1474 String path = result.path; | 1478 String path = result.path; |
1475 if (analysisServer.shouldSendErrorsNotificationFor(path)) { | 1479 if (analysisServer.shouldSendErrorsNotificationFor(path)) { |
1476 if (notificationManager != null) { | 1480 if (notificationManager != null) { |
(...skipping 393 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1870 /** | 1874 /** |
1871 * The [PerformanceTag] for time spent in server request handlers. | 1875 * The [PerformanceTag] for time spent in server request handlers. |
1872 */ | 1876 */ |
1873 static PerformanceTag serverRequests = server.createChild('requests'); | 1877 static PerformanceTag serverRequests = server.createChild('requests'); |
1874 | 1878 |
1875 /** | 1879 /** |
1876 * The [PerformanceTag] for time spent in split store microtasks. | 1880 * The [PerformanceTag] for time spent in split store microtasks. |
1877 */ | 1881 */ |
1878 static PerformanceTag splitStore = new PerformanceTag('splitStore'); | 1882 static PerformanceTag splitStore = new PerformanceTag('splitStore'); |
1879 } | 1883 } |
OLD | NEW |