forked from qt-creator/qt-creator
Clang: Clean up some IPC names
This is long overdue since some names were simply wrong and/or misleading. Also, some of the old names were long enough to almost get crazy. The renaming starts from ClangCodeModelServerInterface and ClangCodeModelClientInterface and affects usages and related functions. For the ClangCodeModelServerInterface, categorize the messages in - messages that require a response (request*) - notification messages (the remaining ones) Change-Id: I5342ed8e0d87404ee72f3c3766fd8ef7505defb1 Reviewed-by: Christian Stenger <christian.stenger@qt.io> Reviewed-by: Ivan Donchevskii <ivan.donchevskii@qt.io>
This commit is contained in:
@@ -63,14 +63,40 @@ public:
|
||||
BackendCommunicator();
|
||||
~BackendCommunicator();
|
||||
|
||||
void registerTranslationUnitsForEditor(const FileContainers &fileContainers);
|
||||
void updateTranslationUnitsForEditor(const FileContainers &fileContainers);
|
||||
void unregisterTranslationUnitsForEditor(const FileContainers &fileContainers);
|
||||
void registerProjectPartsForEditor(const ProjectPartContainers &projectPartContainers);
|
||||
void unregisterProjectPartsForEditor(const QStringList &projectPartIds);
|
||||
void registerUnsavedFilesForEditor(const FileContainers &fileContainers);
|
||||
void unregisterUnsavedFilesForEditor(const FileContainers &fileContainers);
|
||||
void requestDocumentAnnotations(const ClangBackEnd::FileContainer &fileContainer);
|
||||
void documentsOpened(const FileContainers &fileContainers);
|
||||
void documentsChanged(Core::IDocument *document);
|
||||
void documentsChanged(const QString &filePath,
|
||||
const QByteArray &contents,
|
||||
uint documentRevision);
|
||||
void documentsChanged(const FileContainers &fileContainers);
|
||||
void documentsChangedFromCppEditorDocument(const QString &filePath);
|
||||
void documentsChangedIfNotCurrentDocument(Core::IDocument *document);
|
||||
void documentsChangedWithRevisionCheck(const ClangBackEnd::FileContainer &fileContainer);
|
||||
void documentsChangedWithRevisionCheck(Core::IDocument *document);
|
||||
void documentsClosed(const FileContainers &fileContainers);
|
||||
void documentVisibilityChanged();
|
||||
|
||||
void projectPartsUpdated(const QVector<CppTools::ProjectPart::Ptr> projectParts);
|
||||
void projectPartsUpdated(const ProjectPartContainers &projectPartContainers);
|
||||
void projectPartsUpdatedForFallback();
|
||||
void projectPartsRemoved(const QStringList &projectPartIds);
|
||||
|
||||
void unsavedFilesUpdated(Core::IDocument *document);
|
||||
void unsavedFilesUpdated(const QString &filePath,
|
||||
const QByteArray &contents,
|
||||
uint documentRevision);
|
||||
void unsavedFilesUpdated(const FileContainers &fileContainers);
|
||||
void unsavedFielsUpdatedFromCppEditorDocument(const QString &filePath);
|
||||
void unsavedFilesRemoved(const FileContainers &fileContainers);
|
||||
|
||||
void requestCompletions(ClangCompletionAssistProcessor *assistProcessor,
|
||||
const QString &filePath,
|
||||
quint32 line,
|
||||
quint32 column,
|
||||
const QString &projectFilePath,
|
||||
qint32 funcNameStartLine = -1,
|
||||
qint32 funcNameStartColumn = -1);
|
||||
void requestAnnotations(const ClangBackEnd::FileContainer &fileContainer);
|
||||
QFuture<CppTools::CursorInfo> requestReferences(
|
||||
const FileContainer &fileContainer,
|
||||
quint32 line,
|
||||
@@ -86,39 +112,17 @@ public:
|
||||
QFuture<CppTools::SymbolInfo> requestFollowSymbol(const FileContainer &curFileContainer,
|
||||
quint32 line,
|
||||
quint32 column);
|
||||
void completeCode(ClangCompletionAssistProcessor *assistProcessor, const QString &filePath,
|
||||
quint32 line,
|
||||
quint32 column,
|
||||
const QString &projectFilePath,
|
||||
qint32 funcNameStartLine = -1,
|
||||
qint32 funcNameStartColumn = -1);
|
||||
|
||||
void registerProjectsParts(const QVector<CppTools::ProjectPart::Ptr> projectParts);
|
||||
|
||||
void updateTranslationUnitIfNotCurrentDocument(Core::IDocument *document);
|
||||
void updateTranslationUnit(Core::IDocument *document);
|
||||
void updateUnsavedFile(Core::IDocument *document);
|
||||
void updateTranslationUnitFromCppEditorDocument(const QString &filePath);
|
||||
void updateUnsavedFileFromCppEditorDocument(const QString &filePath);
|
||||
void updateTranslationUnit(const QString &filePath, const QByteArray &contents, uint documentRevision);
|
||||
void updateUnsavedFile(const QString &filePath, const QByteArray &contents, uint documentRevision);
|
||||
void updateTranslationUnitWithRevisionCheck(const ClangBackEnd::FileContainer &fileContainer);
|
||||
void updateTranslationUnitWithRevisionCheck(Core::IDocument *document);
|
||||
void updateChangeContentStartPosition(const QString &filePath, int position);
|
||||
|
||||
void registerFallbackProjectPart();
|
||||
void updateTranslationUnitVisiblity();
|
||||
|
||||
bool isNotWaitingForCompletion() const;
|
||||
|
||||
private:
|
||||
void initializeBackend();
|
||||
void initializeBackendWithCurrentData();
|
||||
void registerCurrentProjectParts();
|
||||
void projectPartsUpdatedForCurrentProjects();
|
||||
void restoreCppEditorDocuments();
|
||||
void resetCppEditorDocumentProcessors();
|
||||
void registerVisibleCppEditorDocumentAndMarkInvisibleDirty();
|
||||
void registerCurrentCodeModelUiHeaders();
|
||||
void unsavedFilesUpdatedForUiHeaders();
|
||||
|
||||
void setupDummySender();
|
||||
|
||||
@@ -131,8 +135,8 @@ private:
|
||||
void logStartTimeOut();
|
||||
void logError(const QString &text);
|
||||
|
||||
void updateTranslationUnitVisiblity(const Utf8String ¤tEditorFilePath,
|
||||
const Utf8StringVector &visibleEditorsFilePaths);
|
||||
void documentVisibilityChanged(const Utf8String ¤tEditorFilePath,
|
||||
const Utf8StringVector &visibleEditorsFilePaths);
|
||||
|
||||
private:
|
||||
BackendReceiver m_receiver;
|
||||
|
||||
Reference in New Issue
Block a user