aboutsummaryrefslogtreecommitdiffstats
path: root/src/plugins/qmlls/quick/qqmllsquickplugin_p.h
blob: da6bc6f82721b4cae79827013499a7f692d55c21 (plain)
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
// Copyright (C) 2024 The Qt Company Ltd.
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0

#ifndef QMLLSQUICKPLUGIN_H
#define QMLLSQUICKPLUGIN_H

//
//  W A R N I N G
//  -------------
//
// This file is not part of the Qt API.  It exists purely as an
// implementation detail.  This header file may change from version to
// version without notice, or even be removed.
//
// We mean it.
//

#include <QtCore/qplugin.h>

#include <QtQmlLS/private/qqmllsplugin_p.h>
#include <QtQmlDom/private/qqmldomitem_p.h>

QT_BEGIN_NAMESPACE

class QQmlLSQuickCompletionPlugin : public QQmlLSCompletionPlugin
{
public:
    void suggestSnippetsForLeftHandSideOfBinding(const QQmlJS::Dom::DomItem &items,
                                                 BackInsertIterator result) const override;

    void suggestSnippetsForRightHandSideOfBinding(const QQmlJS::Dom::DomItem &items,
                                                  BackInsertIterator result) const override;
};


class QQmlLSQuickPlugin : public QObject, QQmlLSPlugin
{
    Q_OBJECT
    Q_PLUGIN_METADATA(IID QmlLSPluginInterface_iid FILE "plugin.json")
    Q_INTERFACES(QQmlLSPlugin)
public:
    std::unique_ptr<QQmlLSCompletionPlugin> createCompletionPlugin() const override;
};

QT_END_NAMESPACE

#endif // QMLLSQUICKPLUGIN_H