aboutsummaryrefslogtreecommitdiffstats
path: root/VsQml/vsqmldebugclient.h
blob: c66096459288cde945e7c2fc43d94f019237c914 (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
// Copyright (C) 2025 The Qt Company Ltd.
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0

#pragma once

#include <QObject>

class VsQmlDebugClientPrivate;

class VsQmlDebugClient : public QObject
{
    Q_OBJECT

public:
    VsQmlDebugClient(QObject *parent = nullptr);
    ~VsQmlDebugClient() override;

public slots:
    void connectToHost(const QString &hostName, quint16 port);
    void startLocalServer(const QString &fileName);
    void disconnectFromHost();
    void sendMessage(const QByteArray &messageType, const QByteArray &messageParams);

signals:
    void connected();
    void disconnected();
    void messageReceived(const QByteArray &messageType, const QByteArray &messageParams);

private:
    VsQmlDebugClientPrivate *d;
    friend class VsQmlDebugClientPrivate;
};