Simplify IAzureResourceTreeDataProvider (#20591)

This commit is contained in:
Charles Gagnon
2022-09-14 10:07:30 -07:00
committed by GitHub
parent 6c7d4a2f6b
commit 356f793078
19 changed files with 185 additions and 225 deletions

View File

@@ -355,7 +355,22 @@ declare module 'azurecore' {
getTreeDataProvider(): IAzureResourceTreeDataProvider;
}
export interface IAzureResourceTreeDataProvider extends TreeDataProvider<IAzureResourceNode> {
export interface IAzureResourceTreeDataProvider {
/**
* Gets the root tree item nodes for this provider - these will be used as
* direct children of the Account node in the Azure tree view.
*/
getRootChildren(): Promise<azdata.TreeItem[]>;
/**
* Gets the children for a given {@link IAzureResourceNode}
* @param element The parent node to get the children for
*/
getChildren(element: IAzureResourceNode): Promise<IAzureResourceNode[]>;
/**
* Gets the tree item to display for a given {@link IAzureResourceNode}
* @param element The resource node to get the TreeItem for
*/
getResourceTreeItem(element: IAzureResourceNode): Promise<azdata.TreeItem>;
browseConnectionMode: boolean;
}