/* * Copyright (c) 2020, Itamar S. * * SPDX-License-Identifier: BSD-2-Clause */ #pragma once #include "../AutoCompleteResponse.h" #include "CodeComprehensionEngine.h" #include "FileDB.h" #include #include #include #include #include namespace LanguageServers { class ClientConnection : public IPC::ClientConnection { public: explicit ClientConnection(NonnullRefPtr, int client_id); ~ClientConnection() override; virtual void die() override; protected: virtual void greet(String const&) override; virtual void file_opened(String const&, IPC::File const&) override; virtual void file_edit_insert_text(String const&, String const&, i32, i32) override; virtual void file_edit_remove_text(String const&, i32, i32, i32, i32) override; virtual void set_file_content(String const&, String const&) override; virtual void auto_complete_suggestions(GUI::AutocompleteProvider::ProjectLocation const&) override; virtual void find_declaration(GUI::AutocompleteProvider::ProjectLocation const&) override; virtual void get_parameters_hint(GUI::AutocompleteProvider::ProjectLocation const&) override; FileDB m_filedb; OwnPtr m_autocomplete_engine; }; }