Computer Assited Medical Intervention Tool Kit  version 5.0
CamiTKPropertyList.h
Go to the documentation of this file.
1/*****************************************************************************
2 * $CAMITK_LICENCE_BEGIN$
3 *
4 * CamiTK - Computer Assisted Medical Intervention ToolKit
5 * (c) 2001-2021 Univ. Grenoble Alpes, CNRS, Grenoble INP, TIMC, 38000 Grenoble, France
6 *
7 * Visit http://camitk.imag.fr for more information
8 *
9 * This file is part of CamiTK.
10 *
11 * CamiTK is free software: you can redistribute it and/or modify
12 * it under the terms of the GNU Lesser General Public License version 3
13 * only, as published by the Free Software Foundation.
14 *
15 * CamiTK is distributed in the hope that it will be useful,
16 * but WITHOUT ANY WARRANTY; without even the implied warranty of
17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 * GNU Lesser General Public License version 3 for more details.
19 *
20 * You should have received a copy of the GNU Lesser General Public License
21 * version 3 along with CamiTK. If not, see <http://www.gnu.org/licenses/>.
22 *
23 * $CAMITK_LICENCE_END$
24 ****************************************************************************/
25#include <QObject>
26#include <QMap>
27#include <Property.h>
28
29#ifndef PMLITEMPROPERTY_H
30#define PMLITEMPROPERTY_H
31
35class CamiTKPropertyList : public QObject {
36 Q_OBJECT
37
38public:
39
40 // destructor
41 ~CamiTKPropertyList() override;
42
49 Q_INVOKABLE virtual camitk::Property* getProperty(QString name);
50
59 virtual bool addProperty(camitk::Property*);
60
62 virtual unsigned int getNumberOfProperties() const;
63
65 virtual camitk::Property* getProperty(unsigned int);
66
67private:
69 QMap<QString, camitk::Property*> propertyMap;
70
71};
72#endif // PMLITEMPROPERTY_H
This class holds a list of CamiTK Properties and can be used as an editable QObject for the ObjectCon...
Definition: CamiTKPropertyList.h:35
virtual unsigned int getNumberOfProperties() const
get the number of properties
Definition: CamiTKPropertyList.cpp:58
~CamiTKPropertyList() override
Definition: CamiTKPropertyList.cpp:30
virtual Q_INVOKABLE camitk::Property * getProperty(QString name)
Get a Property given its name.
Definition: CamiTKPropertyList.cpp:39
QMap< QString, camitk::Property * > propertyMap
list of CamiTK property decorating the dynamic properties
Definition: CamiTKPropertyList.h:69
virtual bool addProperty(camitk::Property *)
Add a new CamiTK property to the component.
Definition: CamiTKPropertyList.cpp:48
This class describes a property that can be used in components and actions or any class that needs to...
Definition: Property.h:280