deCONZ C++ API v2.6.1
Loading...
Searching...
No Matches
node_interface.h
1#ifndef DECONZ_NODE_INTERFACE_H
2#define DECONZ_NODE_INTERFACE_H
3
4/*
5 * Copyright (c) 2012-2023 dresden elektronik ingenieurtechnik gmbh.
6 * All rights reserved.
7 *
8 * The software in this package is published under the terms of the BSD
9 * style license a copy of which has been included with this distribution in
10 * the LICENSE.txt file.
11 *
12 */
13
14// forward declarations
15class QDialog;
16class QWidget;
17
18namespace deCONZ
19{
20
21class Node;
22
29{
30public:
33 {
34 WidgetFeature,
35 DialogFeature,
36 HttpClientHandlerFeature
37 };
38
40 virtual ~NodeInterface() { }
42 virtual const char *name() = 0;
44 virtual bool hasFeature(Features feature) = 0;
46 virtual QWidget *createWidget() { return 0; }
48 virtual QDialog *createDialog() { return 0; }
49};
50
51} // namespace deCONZ
52
53Q_DECLARE_INTERFACE(deCONZ::NodeInterface, "com.deCONZ.NodeInterface/1.0")
54
55#endif // DECONZ_NODE_INTERFACE_H
Main interface to create a deCONZ plugin.
Definition node_interface.h:29
virtual QWidget * createWidget()
Returns a widget if the plugin supports the WidgetFeature otherwise 0.
Definition node_interface.h:46
virtual QDialog * createDialog()
Returns a dialog if the plugin supports the DialogFeature otherwise 0.
Definition node_interface.h:48
virtual bool hasFeature(Features feature)=0
Returns true if the plugin supports the feature.
virtual ~NodeInterface()
Deconstructor.
Definition node_interface.h:40
virtual const char * name()=0
Plugin name.
Features
Features the plugin might support.
Definition node_interface.h:33
The deCONZ namespace.
Definition aps.cpp:19