TransitionDialog.h
Go to the documentation of this file.
1 /*
2  * This file is part of ArmarX.
3  *
4  * Copyright (C) 2011-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
19  * @author
20  * @date
21  * @copyright http://www.gnu.org/licenses/gpl-2.0.txt
22  * GNU General Public License
23  */
24 #pragma once
25 
26 
27 #include "../../../StatechartViewerPlugin/model/State.h"
29 #include <QDialog>
30 
31 class QComboBox;
32 
33 namespace armarx::Ui
34 {
35  class TransitionDialog;
36 }
37 
38 namespace armarx
39 {
41  public QDialog
42  {
43  Q_OBJECT
44 
45  public:
46  explicit TransitionDialog(statechartmodel::TransitionCPtr transition, statechartmodel::StatePtr parentState, QStringList profileNames, Ice::CommunicatorPtr ic = NULL, VariantInfoPtr variantInfo = VariantInfoPtr(), QWidget* parent = 0);
47  ~TransitionDialog() override;
48 
52 
53  static size_t LevenshteinEditDistance(const std::string& s1, const std::string& s2);
54 
55  private slots:
56  void on_btnAutoMap_clicked();
57 
58  private:
59  void setup();
60  Ui::TransitionDialog* ui;
62  statechartmodel::StatePtr parentState;
64  VariantInfoPtr variantInfo;
65  QStringList profileNames;
66  QComboBox* getFilteredOutputItems(QString key, statechartmodel::TransitionCPtr transition);
67  QStringList getFilteredParams(const statechartmodel::StateParameterMap& source, const statechartmodel::StateParameter& argumentToMatch) const;
68  };
69 
70 }
71 
armarx::TransitionDialog::getMappingToParentStateLocal
statechartmodel::ParameterMappingList getMappingToParentStateLocal() const
Definition: TransitionDialog.cpp:61
armarx::Ui
Definition: GuiUseCaseSelector.h:33
armarx::TransitionDialog::~TransitionDialog
~TransitionDialog() override
Definition: TransitionDialog.cpp:51
armarx::TransitionDialog::TransitionDialog
TransitionDialog(statechartmodel::TransitionCPtr transition, statechartmodel::StatePtr parentState, QStringList profileNames, Ice::CommunicatorPtr ic=NULL, VariantInfoPtr variantInfo=VariantInfoPtr(), QWidget *parent=0)
Definition: TransitionDialog.cpp:38
IceInternal::Handle< ::Ice::Communicator >
armarx::statechartmodel::StateParameter
Definition: StateParameter.h:49
armarx::TransitionDialog
Definition: TransitionDialog.h:40
armarx::statechartmodel::StateParameterMap
QMap< QString, StateParameterPtr > StateParameterMap
Definition: StateParameter.h:46
boost::source
Vertex source(const detail::edge_base< Directed, Vertex > &e, const PCG &)
Definition: point_cloud_graph.h:681
armarx::TransitionDialog::LevenshteinEditDistance
static size_t LevenshteinEditDistance(const std::string &s1, const std::string &s2)
Definition: TransitionDialog.cpp:71
armarx::TransitionDialog::getMappingToNextStateInput
statechartmodel::ParameterMappingList getMappingToNextStateInput() const
Definition: TransitionDialog.cpp:56
armarx::TransitionDialog::getMappingToParentStateOutput
statechartmodel::ParameterMappingList getMappingToParentStateOutput() const
Definition: TransitionDialog.cpp:66
armarx::VariantInfoPtr
std::shared_ptr< VariantInfo > VariantInfoPtr
Definition: VariantInfo.h:39
armarx::statechartmodel::TransitionCPtr
std::shared_ptr< const Transition > TransitionCPtr
Definition: Transition.h:94
armarx::statechartmodel::ParameterMappingList
QList< ParameterMappingPtr > ParameterMappingList
Definition: XmlWriter.h:49
armarx::statechartmodel::StatePtr
std::shared_ptr< State > StatePtr
Definition: State.h:46
armarx
This file offers overloads of toIce() and fromIce() functions for STL container types.
Definition: ArmarXTimeserver.cpp:28
VariantInfo.h