AuboStudio SDK
0.6.3
io_model.h
浏览该文件的文档.
1
#ifndef AUBO_SCOPE_IO_MODEL_H
2
#define AUBO_SCOPE_IO_MODEL_H
3
4
#include <vector>
5
#include <functional>
6
#include <
aubo_caps/class_forward.h
>
7
#include <
aubo_caps/domain/io/io.h
>
8
9
namespace
arcs
{
10
namespace
aubo_scope
{
11
ARCS_CLASS_FORWARD
(
IoModel
);
12
13
/**
14
* @ingroup ApplicationApi
15
* \chinese
16
* IO 模型
17
* 提供从当前机器人安装中获取 I/O 的方法。
18
* \endchinese
19
* \english
20
* IoModel
21
* Provides methods that returns I/Os from the current robot installation.
22
* \endenglish
23
*/
24
class
ARCS_ABI_EXPORT
IoModel
25
{
26
public
:
27
IoModel
(
IoModel
&f);
28
IoModel
(
IoModel
&&f);
29
~IoModel
();
30
31
/**
32
* @ingroup IoModel
33
* \chinese
34
* 获取所有可用的I/O集合
35
* @return 可用I/O的集合。
36
* \endchinese
37
* \english
38
* Returns the collection of available I/Os, including Modbus, EuroMap67 and
39
* named General Purpose Registers.
40
* @return the collection of available I/Os.
41
* \endenglish
42
*/
43
std::vector<IoPtr>
getAll
();
44
45
/**
46
* @ingroup IoModel
47
* @ref Io
48
* \chinese
49
* 根据名称获取I/O
50
* @param name I/O名称。
51
* @return 对应名称的I/O。
52
* \endchinese
53
* \english
54
* Get an I/O by name.
55
* @param name the name of the I/O.
56
* @return the I/O with the given name.
57
* \endenglish
58
*/
59
IoPtr
getIo
(
const
std::string &name);
60
61
/**
62
* @ingroup IoModel
63
* \chinese
64
* 使用过滤器获取I/O子集
65
* @param filter 过滤器。
66
* @return 被过滤器接受的I/O集合。
67
* \endchinese
68
* \english
69
* Get a subset of I/Os using a filter.
70
* @param filter see {@link IOFilterFactory}.
71
* @return the collection of IOs that are accepted by the filter.
72
* \endenglish
73
*/
74
std::vector<IoPtr>
getIos
(std::function<
bool
(IoPtr)> filter);
75
76
private
:
77
friend
class
DataSwitch
;
78
IoModel
();
79
void
*
d_
{
nullptr
};
80
};
81
82
}
// namespace aubo_scope
83
}
// namespace arcs
84
#endif
class_forward.h
ARCS_ABI_EXPORT
#define ARCS_ABI_EXPORT
定义
class_forward.h:16
ARCS_CLASS_FORWARD
#define ARCS_CLASS_FORWARD(C)
Macro that forward declares a class and defines the respective smartpointers through ARCS_DECLARE_PTR...
定义
class_forward.h:68
arcs::aubo_scope::IoModel
\chinese IO 模型 提供从当前机器人安装中获取 I/O 的方法。 \endchinese \english IoModel Provides methods that returns I/Os...
定义
io_model.h:25
arcs::aubo_scope::IoModel::getAll
std::vector< IoPtr > getAll()
\chinese 获取所有可用的I/O集合
arcs::aubo_scope::IoModel::IoModel
IoModel(IoModel &f)
arcs::aubo_scope::IoModel::getIos
std::vector< IoPtr > getIos(std::function< bool(IoPtr)> filter)
\chinese 使用过滤器获取I/O子集
arcs::aubo_scope::IoModel::IoModel
IoModel()
arcs::aubo_scope::IoModel::d_
void * d_
定义
io_model.h:79
arcs::aubo_scope::IoModel::DataSwitch
friend class DataSwitch
定义
io_model.h:77
arcs::aubo_scope::IoModel::~IoModel
~IoModel()
arcs::aubo_scope::IoModel::IoModel
IoModel(IoModel &&f)
arcs::aubo_scope::IoModel::getIo
IoPtr getIo(const std::string &name)
Io \chinese 根据名称获取I/O
io.h
arcs::aubo_scope
定义
contribution_provider.h:8
arcs
定义
contribution_provider.h:7
include
aubo_caps
domain
io
io_model.h
制作者
1.16.1