ObjectPoseClientWidget.h
Go to the documentation of this file.
1/*
2 * This file is part of ArmarX.
3 *
4 * ArmarX is free software; you can redistribute it and/or modify
5 * it under the terms of the GNU General Public License version 2 as
6 * published by the Free Software Foundation.
7 *
8 * ArmarX is distributed in the hope that it will be useful, but
9 * WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 * GNU General Public License for more details.
12 *
13 * You should have received a copy of the GNU General Public License
14 * along with this program. If not, see <http://www.gnu.org/licenses/>.
15 *
16 * @author Rainer Kartmann ( rainer dot kartmann at kit dot edu )
17 * @date 2021
18 * @copyright http://www.gnu.org/licenses/gpl-2.0.txt
19 * GNU General Public License
20 */
21
22#pragma once
23
24#include <memory>
25#include <optional>
26#include <string>
27#include <vector>
28
29#include <QWidget>
30#include <qobjectdefs.h>
31#include <qwidget.h>
32
33#include <Eigen/Core>
34
37
38
39class QLabel;
40class QPushButton;
41
42namespace IceInternal
43{
44 template <typename T>
46}
47
49{
50 class ObjectPoseStorageInterface;
51}
52
53namespace armarx
54{
55 class ManagedIceObject;
58} // namespace armarx
59
61{
62
64 {
65 public:
66 Connection(ObjectPoseStorageInterfacePrx objectPoseStorageComponent);
68
70 std::string getConnectedName() const;
71
73
75 std::vector<ObjectInfo> getObjectInfo();
76
77 private:
78 std::unique_ptr<ObjectPoseStorageInterfacePrx> _objectPoseStorageComponent;
79 std::unique_ptr<objpose::ObjectPoseClient> _objectPoseClient;
80 };
81
82} // namespace armarx::navigation::qt_plugins::location_graph_editor::objectposes
83
85
86{
87
88 class ObjectPoseClientWidget : public QWidget
89 {
90 Q_OBJECT
91 using This = ObjectPoseClientWidget;
92
93 public:
94 ObjectPoseClientWidget(ManagedIceObject& component, QWidget* parent = nullptr);
95
96
97 bool isConnected() const;
99
100
101 signals:
102
103 void connected();
104
105
106 public slots:
107
109
110
111 private:
112 ManagedIceObject& _component;
113 std::optional<objectposes::Connection> _connection;
114
115 QLabel* _statusLabel = nullptr;
116 QPushButton* _connectButton = nullptr;
117 };
118
119} // namespace armarx::navigation::qt_plugins::location_graph_editor
The ManagedIceObject is the base class for all ArmarX objects.
ObjectPoseClientWidget(ManagedIceObject &component, QWidget *parent=nullptr)
Provides access to the armarx::objpose::ObjectPoseStorageInterface (aka the object memory).
This file is part of ArmarX.
std::map< ObjectID, ObjectPose > ObjectPoseMap
This file offers overloads of toIce() and fromIce() functions for STL container types.
::IceInternal::ProxyHandle<::IceProxy::armarx::objpose::ObjectPoseStorageInterface > ObjectPoseStorageInterfacePrx