AuboStudio SDK 0.6.3

screw_driver_parameters.h
浏览该文件的文档.
1 #ifndef AUBO_SCOPE_SCREW_DIRVER_PARAMETERS_H
2 #define AUBO_SCOPE_SCREW_DIRVER_PARAMETERS_H
3
4 #include <string>
5 #include <aubo_caps/class_forward.h>
6
7 namespace arcs {
8 namespace aubo_scope {
9
10 ARCS_CLASS_FORWARD(ScrewdriverProgram);
11 /**
12 * This abstract class represents a screwdriver program, typically defined on an
13 * external control box for the screwdriver.
14 */
15 class ScrewdriverProgram
16 {
17 public:
18 virtual ~ScrewdriverProgram() = 0;
19
20 /**
21 * <p>
22 * This method must return an identifier to uniquely identify this
23 * screwdriver program. The identifier will be used for persistence and
24 * resolving the correct screwdriver program. Therefore the identifier must
25 * remain constant over time and versions of the screwdriver AuboCap.
26 * </p>
27 *
28 * This method must be implemented.
29 *
30 * @return a unique identifier string which will remain constant over time
31 * and versions of the screwdriver AuboCap.
32 */
33 virtual std::string getId() = 0;
34
35 /**
36 * <p>
37 * This method should return the name of the screwdriver program. The name
38 * will be displayed in the UI, e.g. in a combo box. The name returned is
39 * allowed to change over versions of the driver AuboCap as well as be
40 * different depending on the current language selected in AuboScope, in
41 * case translations are supported.
42 * </p>
43 *
44 * This method must be implemented.
45 *
46 * @return the name of the screwdriver program to display in the UI.
47 */
48 virtual std::string getDisplayName() = 0;
49 };
50
51 /**
52 * This interface represents the type of screwing operation performed by the
53 * screwdriver.
54 */
55 enum ScrewdriverOperationType
56 {
57
58 /**
59 * The screwdriver operation will follow the screw in a tightening direction
60 * (in).
61 */
62 TIGHTEN,
63
64 /**
65 * The screwdriver operation will follow the screw in a loosening direction
66 * (out).
67 */
68 LOOSEN
69 };
70
71 ARCS_CLASS_FORWARD(ScrewdriverParameters);
72
73 /**
74 * This interface represents parameters for a screwdriver operation
75 * defined/configured by the end user.
76 */
77 class ScrewdriverParameters
78 {
79 public:
80 virtual ~ScrewdriverParameters() = default;
81
82 /**
83 * <p>
84 * Get the selected screwdriver program to be used for the screwdriver
85 * operation.
86 * </p>
87 *
88 * This is only valid, if the program selection capability has been
89 * registered (using the method
90 * {@link
91 * ScrewdriverCapabilities#registerProgramSelectionCapability(ScrewdriverProgramListProvider,
92 * ScriptCodeGenerator)}).
93 *
94 * @return The selected screwdriver program to use for the operation.
95 * @throws UnsupportedOperationException if the screwdriver has not
96 * registered the program selection capability
97 */
98 virtual ScrewdriverProgram getScrewdriverProgram() = 0;
99
100 /**
101 * <p>
102 * Get the selected screwdriver operation type.
103 * </p>
104 *
105 * This is only valid, if the operation type capability has been registered
106 * (using the method
107 * {@link ScrewdriverCapabilities#registerOperationTypeCapability()}).
108 *
109 * @return The operation type selected by the user.
110 * @throws UnsupportedOperationException if the screwdriver has not
111 * registered the operation type capability
112 */
113 virtual ScrewdriverOperationType getScrewdriverOperationType() = 0;
114 ;
115 };
116 } // namespace aubo_scope
117 } // namespace arcs
118
119 #endif
class_forward.h
arcs::aubo_scope::ScrewdriverParameters
This interface represents parameters for a screwdriver operation defined/configured by the end user.
Definition: screw_driver_parameters.h:78
arcs::aubo_scope::ScrewdriverParameters::~ScrewdriverParameters
virtual ~ScrewdriverParameters()=default
arcs::aubo_scope::ScrewdriverParameters::getScrewdriverOperationType
virtual ScrewdriverOperationType getScrewdriverOperationType()=0
arcs::aubo_scope::ScrewdriverParameters::getScrewdriverProgram
virtual ScrewdriverProgram getScrewdriverProgram()=0
arcs::aubo_scope::ScrewdriverProgram
This abstract class represents a screwdriver program, typically defined on an external control box fo...
Definition: screw_driver_parameters.h:16
arcs::aubo_scope::ScrewdriverProgram::~ScrewdriverProgram
virtual ~ScrewdriverProgram()=0
arcs::aubo_scope::ScrewdriverProgram::getId
virtual std::string getId()=0
arcs::aubo_scope::ScrewdriverProgram::getDisplayName
virtual std::string getDisplayName()=0
arcs::aubo_scope::ARCS_CLASS_FORWARD
ARCS_CLASS_FORWARD(GripForceCapability)
arcs::aubo_scope::ScrewdriverOperationType
ScrewdriverOperationType
This interface represents the type of screwing operation performed by the screwdriver.
Definition: screw_driver_parameters.h:56
arcs::aubo_scope::TIGHTEN
@ TIGHTEN
The screwdriver operation will follow the screw in a tightening direction (in).
Definition: screw_driver_parameters.h:62
arcs::aubo_scope::LOOSEN
@ LOOSEN
The screwdriver operation will follow the screw in a loosening direction (out).
Definition: screw_driver_parameters.h:68
arcs
Definition: contribution_provider.h:7