-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
6ae4fa2
commit 3eb86e0
Showing
8 changed files
with
222 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
// Copyright (c) 2020 Stefan Fabian. All rights reserved. | ||
// Licensed under the MIT license. See LICENSE file in the project root for full license information. | ||
|
||
#ifndef QML_ROS_PLUGIN_TOPIC_INFO_H | ||
#define QML_ROS_PLUGIN_TOPIC_INFO_H | ||
|
||
#include <QArgument> | ||
#include <QMetaType> | ||
#include <QString> | ||
|
||
namespace qml_ros_plugin | ||
{ | ||
|
||
class TopicInfo | ||
{ | ||
Q_GADGET | ||
// @formatter:off | ||
//! The name of the topic, e.g., /front_camera/image_raw | ||
Q_PROPERTY( QString name READ name ) | ||
//! The datatype of the topic, e.g., sensor_msgs/Image | ||
Q_PROPERTY( QString datatype READ datatype ) | ||
// @formatter:on | ||
public: | ||
TopicInfo() = default; | ||
|
||
TopicInfo( QString name, QString datatype ) : name_( std::move( name )), datatype_( std::move( datatype )) { } | ||
|
||
const QString &name() const { return name_; } | ||
|
||
const QString &datatype() const { return datatype_; } | ||
|
||
private: | ||
QString name_; | ||
QString datatype_; | ||
}; | ||
} | ||
|
||
Q_DECLARE_METATYPE( qml_ros_plugin::TopicInfo ); | ||
|
||
#endif //QML_ROS_PLUGIN_TOPIC_INFO_H |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters