File tree Expand file tree Collapse file tree 2 files changed +0
-19
lines changed
pkgs/dart_mcp_server/lib/src Expand file tree Collapse file tree 2 files changed +0
-19
lines changed Original file line number Diff line number Diff line change @@ -75,19 +75,6 @@ final class DartMCPServer extends MCPServer
7575 @override
7676 final Analytics ? analytics;
7777
78- /// Only safe to call after [initialize] .
79- @override
80- ClientImplementation get clientInfo => _clientInfo;
81-
82- /// Assigned in [initialize] .
83- late final ClientImplementation _clientInfo;
84-
85- @override
86- FutureOr <InitializeResult > initialize (InitializeRequest request) {
87- _clientInfo = request.clientInfo;
88- return super .initialize (request);
89- }
90-
9178 @override
9279 /// Automatically logs all tool calls via analytics by wrapping the [impl] ,
9380 /// if [analytics] is not `null` .
Original file line number Diff line number Diff line change 22// for details. All rights reserved. Use of this source code is governed by a
33// BSD-style license that can be found in the LICENSE file.
44
5- import 'package:dart_mcp/server.dart' ;
65import 'package:unified_analytics/unified_analytics.dart' ;
76
87/// An interface class that provides a access to an [Analytics] instance, if
98/// enabled.
109///
11- /// Also provides a [clientInfo] getter which is required for analytics
12- /// requests.
13- ///
1410/// The `DartMCPServer` class implements this class so that [Analytics]
1511/// methods can be easily mocked during testing.
1612abstract interface class AnalyticsSupport {
1713 Analytics ? get analytics;
18-
19- ClientImplementation get clientInfo;
2014}
2115
2216enum AnalyticsEvent { callTool, readResource }
You can’t perform that action at this time.
0 commit comments