import Parser, { SyntaxNode } from 'web-tree-sitter';
import { TextRange } from '../../code-search/scope-graph/model/TextRange';
import { ScopeGraph } from '../../code-search/scope-graph/ScopeGraph';
import { BaseStructurerProvider } from "../base/StructurerProvider";
import { LanguageIdentifier } from "../../base/common/languages/languages";
import { LanguageProfile } from "../base/LanguageProfile";
import { CodeFile, CodeVariable } from "../../codemodel/CodeElement";
export declare class GoStructurerProvider extends BaseStructurerProvider {
    protected langId: LanguageIdentifier;
    protected config: LanguageProfile;
    protected parser: Parser | undefined;
    protected language: Parser.Language | undefined;
    constructor();
    isApplicable(lang: string): boolean;
    /**
     * 解析Go代码文件，构建代码结构
     * @param code 源代码字符串
     * @param filepath 文件路径
     * @returns 解析后的代码文件结构
     */
    parseFile(code: string, filepath: string): Promise<CodeFile | undefined>;
    /**
     * 提取Go方法接收者类型
     * 例如从 "(r *Repository)" 中提取 "Repository"
     */
    private extractReceiverType;
    /**
     * 从方法中提取输入输出相关的导入
     */
    retrieveMethodIOImports(graph: ScopeGraph, node: SyntaxNode, range: TextRange, src: string): Promise<string[] | undefined>;
    /**
     * 清理字符串字面量，移除引号
     */
    private cleanStringLiteral;
    /**
     * 初始化结构体对象
     */
    private initStructure;
    /**
     * 提取结构体字段
     */
    extractFields(node: SyntaxNode): Promise<CodeVariable[]>;
}
