AuboStudio SDK  0.6.3
io.h
浏览该文件的文档.
1#ifndef AUBO_SCOPE_IO_H
2#define AUBO_SCOPE_IO_H
3
4#include <string>
6
7namespace arcs {
8namespace aubo_scope {
10
11/**
12 *
13 * This is the base interface representing all types of I/Os available in
14 * AuboScope.
15 */
17{
18public:
38
39public:
40 Io(Io &f);
41 Io(Io &&f);
42 virtual ~Io();
43
44 /**
45 *
46 * @return the user defined name of the IO in the currently selected
47 * installation.
48 */
49 std::string getDisplayName() const;
50
51 /**
52 *
53 * @return the robot default name of the I/O.
54 */
55 std::string getDefaultName() const;
56
57 /**
58 *
59 * @return get current reading of the I/O as a string.
60 */
61 std::string getValueStr() const;
62
63 /**
64 *
65 * @return the I/O type.
66 */
67 IoType getType() const;
68
69 /**
70 *
71 * @return the interface type this I/O belongs to.
72 */
74
75 /**
76 *
77 * @return the action number of the I/O.
78 */
79 int getAction() const;
80
81 /**
82 *
83 * @return <code>true</code> if I/O supports reading of values and
84 * <code>false</code> otherwise.
85 */
86 bool isInput() const;
87
88 /**
89 * Some I/Os, such as MODBUS I/Os and analog Tool inputs, are in some
90 * situations not present in AuboScope or available for use. This method can
91 * be used to determine if the I/O is available. <br>
92 *
93 * For more details about the specific situations where certain types of
94 * I/Os can be unresolved, see the relevant interfaces extending this base
95 * interface, e.g. {@link ModbusIO#isResolvable()}.
96 *
97 * @return <code>true</code>, if I/O can be resolved.
98 * <code>false</code> otherwise.
99 */
100 bool isResolvable() const;
101
102 size_t hashCode();
103
104protected:
105 Io();
106
107private:
108 friend class DataSwitch;
109 void *d_{ nullptr };
110};
111
112} // namespace aubo_scope
113} // namespace arcs
114
115#endif // AUBO_SCOPE_IO_H
#define ARCS_ABI_EXPORT
#define ARCS_CLASS_FORWARD(C)
Macro that forward declares a class and defines the respective smartpointers through ARCS_DECLARE_PTR...
This is the base interface representing all types of I/Os available in AuboScope.
定义 io.h:17
std::string getDisplayName() const
std::string getValueStr() const
InterfaceType getInterfaceType() const
friend class DataSwitch
定义 io.h:108
bool isResolvable() const
Some I/Os, such as MODBUS I/Os and analog Tool inputs, are in some situations not present in AuboScop...
std::string getDefaultName() const
IoType getType() const
int getAction() const
bool isInput() const