CTK 0.1.0
The Common Toolkit is a community effort to provide support code for medical image analysis, surgical navigation, and related projects.
Loading...
Searching...
No Matches
ctkBusEvent.h
Go to the documentation of this file.
1/*=============================================================================
2
3 Library: CTK
4
5 Copyright (c) German Cancer Research Center,
6 Division of Medical and Biological Informatics
7
8 Licensed under the Apache License, Version 2.0 (the "License");
9 you may not use this file except in compliance with the License.
10 You may obtain a copy of the License at
11
12 http://www.apache.org/licenses/LICENSE-2.0
13
14 Unless required by applicable law or agreed to in writing, software
15 distributed under the License is distributed on an "AS IS" BASIS,
16 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
17 See the License for the specific language governing permissions and
18 limitations under the License.
19
20=============================================================================*/
21#ifndef CTKBUSEVENT_H
22#define CTKBUSEVENT_H
23
24#include "org_commontk_eventbus_Export.h"
25#include "ctkPluginFrameworkExport.h"
27
28#include <QMap>
29#include <QVariant>
30#include <QStringList>
31
32class ctkBusEventData;
33
40class org_commontk_eventbus_EXPORT ctkBusEvent : public ctkEvent
41{
42 QSharedDataPointer<ctkBusEventData> d;
43
44public:
45
50
52
60 ctkBusEvent(const QString& topic, const ctkDictionary& properties = ctkDictionary());
61 ctkBusEvent(const ctkBusEvent& event);
62 ctkBusEvent(QString topic, int event_type, int signature_type, QObject *objectPointer, QString signature);
63
65
71 void setEventType(int et);
72 int eventType() const;
73 bool isEventLocal() const;
74
81 void setEventTopic(QString topic);
82
83 QString eventTopic() const;
84
90 QVariant &operator[](QString key);
91};
92
93#endif // CTKBUSEVENT_H
ctkBusEvent & operator=(const ctkBusEvent &event)
ctkBusEvent(QString topic, int event_type, int signature_type, QObject *objectPointer, QString signature)
void setEventTopic(QString topic)
QString eventTopic() const
bool isEventLocal() const
ctkBusEvent(const QString &topic, const ctkDictionary &properties=ctkDictionary())
QVariant & operator[](QString key)
int eventType() const
void setEventType(int et)
ctkBusEvent(const ctkBusEvent &event)
QHash< QString, QVariant > ctkDictionary
Definition: ctkDictionary.h:37