Skip to main content
Table of Contents

TTMSMCPCustomServer.RequestRootsList Method

Asks the connected client for the roots it exposes, typically the workspace folders the user has opened.

API unit family: TMS.MCP.Server Declaring type: TTMSMCPCustomServer

Syntax

TMS.MCP.Server.hppPascalC++
function RequestRootsList: TArray<TTMSMCPRoot>;
System::DynamicArray<TTMSMCPRoot> __fastcall RequestRootsList();

Remarks

Call it after an OnRootsChanged notification, or once after initialization. An empty array is returned when the client answers with no roots or with a response that cannot be read.

Returns

Roots reported by the client.

Exceptions

Exception Description
Exception Raised when no client has initialized.