1 | // Copyright (C) 2016 The Qt Company Ltd. |
2 | // SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only |
3 | |
4 | #ifndef QFINALSTATE_H |
5 | #define QFINALSTATE_H |
6 | |
7 | #include <QtStateMachine/qabstractstate.h> |
8 | |
9 | QT_REQUIRE_CONFIG(statemachine); |
10 | |
11 | QT_BEGIN_NAMESPACE |
12 | |
13 | class QFinalStatePrivate; |
14 | class Q_STATEMACHINE_EXPORT QFinalState : public QAbstractState |
15 | { |
16 | Q_OBJECT |
17 | public: |
18 | QFinalState(QState *parent = nullptr); |
19 | ~QFinalState(); |
20 | |
21 | protected: |
22 | void onEntry(QEvent *event) override; |
23 | void onExit(QEvent *event) override; |
24 | |
25 | bool event(QEvent *e) override; |
26 | |
27 | protected: |
28 | explicit QFinalState(QFinalStatePrivate &dd, QState *parent); |
29 | |
30 | private: |
31 | Q_DISABLE_COPY(QFinalState) |
32 | Q_DECLARE_PRIVATE(QFinalState) |
33 | }; |
34 | |
35 | QT_END_NAMESPACE |
36 | |
37 | #endif |
38 | |