swift
Loading...
Searching...
No Matches
passivemutator.h
Go to the documentation of this file.
1// SPDX-FileCopyrightText: Copyright (C) 2017 swift Project Community / Contributors
2// SPDX-License-Identifier: GPL-3.0-or-later OR LicenseRef-swift-pilot-client-1
3
5
6#ifndef SWIFT_MISC_SHAREDSTATE_PASSIVEMUTATOR_H
7#define SWIFT_MISC_SHAREDSTATE_PASSIVEMUTATOR_H
8
9#include <QObject>
10#include <QSharedPointer>
11
13#include "misc/variant.h"
14
16{
17 class CActiveMutator;
18
23 class SWIFT_MISC_EXPORT CPassiveMutator : public QObject, public QEnableSharedFromThis<CPassiveMutator>
24 {
26 friend CActiveMutator;
28
29 CPassiveMutator(QObject *parent) : QObject(parent) {}
30
31 public:
34
36 void postEvent(const CVariant &param);
37
40
41 signals:
44 };
45} // namespace swift::misc::shared_state
46
47#endif // SWIFT_MISC_SHAREDSTATE_PASSIVEMUTATOR_H
Wrapper around QVariant which provides transparent access to CValueObject methods of the contained ob...
Definition variant.h:69
Extends CPassiveMutator with the ability to respond to requests.
QWeakPointer< const CPassiveMutator > weakRef() const
Get a QWeakPointer pointing to this object.
static auto create(QObject *parent)
Factory method.
void eventPosted(const swift::misc::CVariant &param)
Emitted by postEvent.
Utilities for sharing state between multiple objects.
Definition application.h:48
QObject(QObject *parent)
Q_OBJECTQ_OBJECT
QObject * parent() const const
QSharedPointer< T > create(Args &&... args)
#define SWIFT_MISC_EXPORT
Export a class or function from the library.