SnapshotControlWidgetController.h
Go to the documentation of this file.
1 /*
2  * This file is part of ArmarX.
3  *
4  * Copyright (C) 2012-2016, High Performance Humanoid Technologies (H2T), Karlsruhe Institute of Technology (KIT), all rights reserved.
5  *
6  * ArmarX is free software; you can redistribute it and/or modify
7  * it under the terms of the GNU General Public License version 2 as
8  * published by the Free Software Foundation.
9  *
10  * ArmarX is distributed in the hope that it will be useful, but
11  * WITHOUT ANY WARRANTY; without even the implied warranty of
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13  * GNU General Public License for more details.
14  *
15  * You should have received a copy of the GNU General Public License
16  * along with this program. If not, see <http://www.gnu.org/licenses/>.
17  *
18  * @package MemoryX::gui-plugins::SnapshotControlWidgetController
19  * @author Manfred Kroehnert ( Manfred dot Kroehnert at kit dot edu )
20  * @date 2014
21  * @copyright http://www.gnu.org/licenses/gpl-2.0.txt
22  * GNU General Public License
23  */
24 
25 #pragma once
26 
27 #include <MemoryX/gui-plugins/SnapshotControl/ui_SnapshotControlWidget.h>
28 
30 
33 
34 #include <MemoryX/interface/components/WorkingMemoryInterface.h>
35 #include <MemoryX/interface/components/LongtermMemoryInterface.h>
36 
37 namespace armarx
38 {
63  public ArmarXComponentWidgetControllerTemplate<SnapshotControlWidgetController>
64  {
65  Q_OBJECT
66 
67  public:
72 
77 
81  void loadSettings(QSettings* settings) override;
82 
86  void saveSettings(QSettings* settings) override;
87 
92  static QString GetWidgetName()
93  {
94  return "MemoryX.SnapshotControl";
95  }
96 
102  void onInitComponent() override;
103 
110  void onConnectComponent() override;
111 
117  void onDisconnectComponent() override;
118 
119  public slots:
120  /* QT slot declarations */
124  void loadSnapshotNames();
125 
129  void loadSnapshot();
133  void removeSnapshot();
137  void saveSnapshot();
138  private slots:
143  void snapshotNameChanged(const QString& snapshotName);
144  signals:
145  /* QT signal declarations */
146 
147  private:
151  void connectSlots();
155  Ui::SnapshotControlWidget widget;
156 
160  memoryx::WorkingMemoryInterfacePrx workingMemoryPrx;
164  memoryx::LongtermMemoryInterfacePrx longtermMemoryPrx;
165 
169  const std::string LONGTERM_SNAPSHOT_PREFIX;
170  };
171 }
172 
armarx::SnapshotControlWidgetController::GetWidgetName
static QString GetWidgetName()
Returns the Widget name displayed in the ArmarXGui to create an instance of this class.
Definition: SnapshotControlWidgetController.h:92
armarx::ArmarXComponentWidgetControllerTemplate
Definition: ArmarXComponentWidgetController.h:69
ArmarXGuiPlugin.h
armarx::SnapshotControlWidgetController
SnapshotControlWidgetController provides a graphical interface for loading, storing,...
Definition: SnapshotControlWidgetController.h:61
ArmarXComponentWidgetController.h
ARMARXCOMPONENT_IMPORT_EXPORT
#define ARMARXCOMPONENT_IMPORT_EXPORT
Definition: ImportExportComponent.h:38
armarx
This file offers overloads of toIce() and fromIce() functions for STL container types.
Definition: ArmarXTimeserver.cpp:28
ImportExportComponent.h