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
ctkPluginFrameworkEvent.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
22#ifndef CTKPLUGINFRAMEWORKEVENT_H
23#define CTKPLUGINFRAMEWORKEVENT_H
24
25#include <QSharedDataPointer>
26#include <QSharedPointer>
27#include <QMetaType>
28
29#include "ctkPluginFrameworkExport.h"
30
31class ctkException;
32class ctkPlugin;
33class ctkPluginFrameworkEventData;
34
49class CTK_PLUGINFW_EXPORT ctkPluginFrameworkEvent
50{
51
52 QSharedDataPointer<ctkPluginFrameworkEventData> d;
53
54public:
55
56 enum Type {
67
75
83
91
101
111
119 FRAMEWORK_WAIT_TIMEDOUT
120
121 };
122
127
129
137 bool isNull() const;
138
146 ctkPluginFrameworkEvent(Type type, QSharedPointer<ctkPlugin> plugin, const ctkException& fwException);
147
154 ctkPluginFrameworkEvent(Type type, QSharedPointer<ctkPlugin> plugin);
155
157
159
165 QString getErrorString() const;
166
173 QSharedPointer<ctkPlugin> getPlugin() const;
174
191 Type getType() const;
192};
193
195
200CTK_PLUGINFW_EXPORT QDebug operator<<(QDebug dbg, ctkPluginFrameworkEvent::Type type);
201CTK_PLUGINFW_EXPORT QDebug operator<<(QDebug dbg, const ctkPluginFrameworkEvent& event);
204#endif // CTKPLUGINFRAMEWORKEVENT_H
The base class for all exceptions defined in CTK.
Definition: ctkException.h:46
ctkPluginFrameworkEvent & operator=(const ctkPluginFrameworkEvent &other)
QSharedPointer< ctkPlugin > getPlugin() const
ctkPluginFrameworkEvent(Type type, QSharedPointer< ctkPlugin > plugin, const ctkException &fwException)
ctkPluginFrameworkEvent(Type type, QSharedPointer< ctkPlugin > plugin)
QString getErrorString() const
ctkPluginFrameworkEvent(const ctkPluginFrameworkEvent &other)
Q_DECLARE_METATYPE(ctkPluginFrameworkEvent)
CTK_PLUGINFW_EXPORT QDebug operator<<(QDebug dbg, ctkPluginFrameworkEvent::Type type)