|
9 | 9 | #ifndef LLDB_PLUGINS_PROTOCOL_MCP_PROTOCOLSERVERMCP_H |
10 | 10 | #define LLDB_PLUGINS_PROTOCOL_MCP_PROTOCOLSERVERMCP_H |
11 | 11 |
|
12 | | -#include "Resource.h" |
13 | | -#include "Tool.h" |
14 | 12 | #include "lldb/Core/ProtocolServer.h" |
15 | 13 | #include "lldb/Host/MainLoop.h" |
16 | 14 | #include "lldb/Host/Socket.h" |
17 | 15 | #include "lldb/Protocol/MCP/Protocol.h" |
| 16 | +#include "lldb/Protocol/MCP/Resource.h" |
| 17 | +#include "lldb/Protocol/MCP/Tool.h" |
18 | 18 | #include "llvm/ADT/StringMap.h" |
19 | 19 | #include <thread> |
20 | 20 |
|
@@ -47,8 +47,9 @@ class ProtocolServerMCP : public ProtocolServer { |
47 | 47 | using NotificationHandler = |
48 | 48 | std::function<void(const lldb_protocol::mcp::Notification &)>; |
49 | 49 |
|
50 | | - void AddTool(std::unique_ptr<Tool> tool); |
51 | | - void AddResourceProvider(std::unique_ptr<ResourceProvider> resource_provider); |
| 50 | + void AddTool(std::unique_ptr<lldb_protocol::mcp::Tool> tool); |
| 51 | + void AddResourceProvider( |
| 52 | + std::unique_ptr<lldb_protocol::mcp::ResourceProvider> resource_provider); |
52 | 53 |
|
53 | 54 | void AddRequestHandler(llvm::StringRef method, RequestHandler handler); |
54 | 55 | void AddNotificationHandler(llvm::StringRef method, |
@@ -99,8 +100,9 @@ class ProtocolServerMCP : public ProtocolServer { |
99 | 100 | std::vector<std::unique_ptr<Client>> m_clients; |
100 | 101 |
|
101 | 102 | std::mutex m_server_mutex; |
102 | | - llvm::StringMap<std::unique_ptr<Tool>> m_tools; |
103 | | - std::vector<std::unique_ptr<ResourceProvider>> m_resource_providers; |
| 103 | + llvm::StringMap<std::unique_ptr<lldb_protocol::mcp::Tool>> m_tools; |
| 104 | + std::vector<std::unique_ptr<lldb_protocol::mcp::ResourceProvider>> |
| 105 | + m_resource_providers; |
104 | 106 |
|
105 | 107 | llvm::StringMap<RequestHandler> m_request_handlers; |
106 | 108 | llvm::StringMap<NotificationHandler> m_notification_handlers; |
|
0 commit comments