QueryWidget.h
Go to the documentation of this file.
1 #pragma once
2 
3 #include <mutex>
4 
7 
9 
10 class QWidget;
11 class QTabWidget;
12 class QPushButton;
13 class QGroupBox;
14 class QLineEdit;
15 class QString;
16 
17 namespace armarx::armem::gui
18 {
19 
20  class QueryWidget : public QWidget
21  {
22  Q_OBJECT
23  using This = QueryWidget;
24 
25  public:
26  enum class ActiveMemoryState
27  {
30  NotFound
31  };
32 
33  QueryWidget();
34 
36 
37  bool dropRemovedMemories() const;
38  bool dropDisabledMemories() const;
39 
40  int queryLinkRecursionDepth() const;
41 
42  std::map<std::string, ActiveMemoryState> getAvailableMemoryStates() const;
43 
44  std::vector<std::string> getEnabledMemories() const;
45 
46  void update(const std::vector<std::string>& memoryNames);
47 
48 
49  public slots:
50 
51  signals:
52  void storeInLTM();
53  void startRecording();
54  void stopRecording();
55  //void confirmExportPath(std::string path);
56 
57  // ToDo:
58  // void queryChanged(armem::query::data::Input query);
59 
60 
61  private slots:
62  void setRecursionDepthSpinnerEnabled(int state);
63 
64  void deSelectMemoryServers();
65 
66  signals:
67 
68 
69  private:
70  QCheckBox* _dataCheckBox;
71 
72  QCheckBox* _dropRemovedCheckBox;
73  QCheckBox* _dropDisabledCheckBox;
74 
75  QLabel* _recursionDepthLabel;
76  QSpinBox* _recursionDepthSpinner;
77 
78  QLabel* _exportPathLabel;
79  QLineEdit* _exportPathLineEdit;
80  QPushButton* _exportPathConfirmButton;
81 
82  QLabel* _exportNameLabel;
83  QLineEdit* _exportNameLineEdit;
84  QPushButton* _exportNameConfirmButton;
85 
86  QPushButton* _storeInLTMButton;
87  QPushButton* _startLTMRecordingButton;
88  QPushButton* _stopLTMRecordingButton;
89 
90  QGroupBox* _additionalSettingsGroupBox;
91  QGroupBox* _availableMemoriesGroupBox;
92 
93  QPushButton* _de_selectMemoryServers;
94  bool allMemoryServersSelected = false;
95  QString selectText = "Select all Memory Servers";
96  QString deselectText = "Deselect all Memory Servers";
97 
98  mutable std::mutex enabledMemoriesMutex;
99  };
100 
101 } // namespace armarx::armem::gui
armarx::armem::gui::QueryWidget
Definition: QueryWidget.h:20
armarx::armem::gui::QueryWidget::storeInLTM
void storeInLTM()
armarx::armem::gui::QueryWidget::QueryWidget
QueryWidget()
Definition: QueryWidget.cpp:23
armarx::armem::gui::QueryWidget::stopRecording
void stopRecording()
SnapshotSelectorWidget.h
armarx::armem::gui::QueryWidget::ActiveMemoryState::NotFound
@ NotFound
armarx::armem::gui::QueryWidget::ActiveMemoryState::FoundAndNotChecked
@ FoundAndNotChecked
armarx::armem::query::DataMode
DataMode
Definition: DataMode.h:7
armarx::armem::gui::QueryWidget::update
void update(const std::vector< std::string > &memoryNames)
Definition: QueryWidget.cpp:150
armarx::armem::gui::QueryWidget::getAvailableMemoryStates
std::map< std::string, ActiveMemoryState > getAvailableMemoryStates() const
Definition: QueryWidget.cpp:220
armarx::armem::gui::QueryWidget::startRecording
void startRecording()
armarx::armem::gui::QueryWidget::dropRemovedMemories
bool dropRemovedMemories() const
Definition: QueryWidget.cpp:208
armarx::armem::gui::QueryWidget::ActiveMemoryState
ActiveMemoryState
Definition: QueryWidget.h:26
armarx::armem::gui::QueryWidget::getEnabledMemories
std::vector< std::string > getEnabledMemories() const
Definition: QueryWidget.cpp:248
armarx::armem::gui::QueryWidget::ActiveMemoryState::FoundAndChecked
@ FoundAndChecked
armarx::armem::gui
Definition: ActionsMenuBuilder.cpp:6
Builder.h
armarx::armem::gui::QueryWidget::queryLinkRecursionDepth
int queryLinkRecursionDepth() const
Definition: QueryWidget.cpp:269
armarx::armem::gui::QueryWidget::dropDisabledMemories
bool dropDisabledMemories() const
Definition: QueryWidget.cpp:214
DataMode.h
armarx::armem::gui::QueryWidget::dataMode
armem::query::DataMode dataMode() const
Definition: QueryWidget.cpp:201