-
Notifications
You must be signed in to change notification settings - Fork 2
/
codegeex2clientinterface.h
48 lines (35 loc) · 1.12 KB
/
codegeex2clientinterface.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
#ifndef CODEGEEX2_INTERNAL_CODEGEEX2CLIENTINTERFACE_H
#define CODEGEEX2_INTERNAL_CODEGEEX2CLIENTINTERFACE_H
#include <languageclient/languageclientinterface.h>
#include <QNetworkAccessManager>
class QNetworkReply;
namespace CodeGeeX2 {
namespace Internal {
class CodeGeeX2ClientInterface : public LanguageClient::BaseClientInterface
{
public:
CodeGeeX2ClientInterface();
~CodeGeeX2ClientInterface();
Utils::FilePath serverDeviceTemplate() const override;
public slots:
void replyFinished();
protected:
void sendData(const QByteArray &data) override;
private:
QBuffer m_writeBuffer;
QSharedPointer<QNetworkReply> m_reply;
QJsonValue m_id;
int m_pos;
QJsonValue m_position;
int m_row;
int m_col;
int m_braceLevel;
QMap<QString,QString> m_fileLang;
QSharedPointer<QNetworkAccessManager> m_manager;
void clearReply();
bool expandHeader(QString &txt,const QString &includeStr,const QString &path,int &space,int &pos);
static QMap<QString,QString> m_langMap;
};
} // namespace Internal
} // namespace CodeGeeX2
#endif // CODEGEEX2_INTERNAL_CODEGEEX2CLIENTINTERFACE_H