@@ -101,6 +101,23 @@ class Waitable
101
101
size_t
102
102
get_number_of_ready_guard_conditions ();
103
103
104
+ #ifdef __GNUC__
105
+ #pragma GCC diagnostic push
106
+ #pragma GCC diagnostic ignored "-Woverloaded-virtual"
107
+ #endif
108
+ // / Deprecated.
109
+ /* *
110
+ * \sa add_to_wait_set(rcl_wait_set_t &)
111
+ */
112
+ [[deprecated(" Use add_to_wait_set(rcl_wait_set_t & wait_set) signature" )]]
113
+ RCLCPP_PUBLIC
114
+ virtual
115
+ void
116
+ add_to_wait_set (rcl_wait_set_t * wait_set);
117
+ #ifdef __GNUC__
118
+ #pragma GCC diagnostic pop
119
+ #endif
120
+
104
121
// / Add the Waitable to a wait set.
105
122
/* *
106
123
* \param[in] wait_set A handle to the wait set to add the Waitable to.
@@ -109,7 +126,24 @@ class Waitable
109
126
RCLCPP_PUBLIC
110
127
virtual
111
128
void
112
- add_to_wait_set (rcl_wait_set_t * wait_set) = 0 ;
129
+ add_to_wait_set (rcl_wait_set_t & wait_set);
130
+
131
+ #ifdef __GNUC__
132
+ #pragma GCC diagnostic push
133
+ #pragma GCC diagnostic ignored "-Woverloaded-virtual"
134
+ #endif
135
+ // / Deprecated.
136
+ /* *
137
+ * \sa is_ready(const rcl_wait_set_t &)
138
+ */
139
+ [[deprecated(" Use is_ready(const rcl_wait_set_t & wait_set) signature" )]]
140
+ RCLCPP_PUBLIC
141
+ virtual
142
+ bool
143
+ is_ready (rcl_wait_set_t * wait_set);
144
+ #ifdef __GNUC__
145
+ #pragma GCC diagnostic pop
146
+ #endif
113
147
114
148
// / Check if the Waitable is ready.
115
149
/* *
@@ -124,7 +158,7 @@ class Waitable
124
158
RCLCPP_PUBLIC
125
159
virtual
126
160
bool
127
- is_ready (rcl_wait_set_t * wait_set) = 0 ;
161
+ is_ready (const rcl_wait_set_t & wait_set);
128
162
129
163
// / Take the data so that it can be consumed with `execute`.
130
164
/* *
@@ -178,6 +212,23 @@ class Waitable
178
212
std::shared_ptr<void >
179
213
take_data_by_entity_id (size_t id);
180
214
215
+ #ifdef __GNUC__
216
+ #pragma GCC diagnostic push
217
+ #pragma GCC diagnostic ignored "-Woverloaded-virtual"
218
+ #endif
219
+ // / Deprecated.
220
+ /* *
221
+ * \sa execute(const std::shared_ptr<void> &)
222
+ */
223
+ [[deprecated(" Use execute(const std::shared_ptr<void> & data) signature" )]]
224
+ RCLCPP_PUBLIC
225
+ virtual
226
+ void
227
+ execute (std::shared_ptr<void > & data);
228
+ #ifdef __GNUC__
229
+ #pragma GCC diagnostic pop
230
+ #endif
231
+
181
232
// / Execute data that is passed in.
182
233
/* *
183
234
* Before calling this method, the Waitable should be added to a wait set,
@@ -203,7 +254,7 @@ class Waitable
203
254
RCLCPP_PUBLIC
204
255
virtual
205
256
void
206
- execute (std::shared_ptr<void > & data) = 0 ;
257
+ execute (const std::shared_ptr<void > & data);
207
258
208
259
// / Exchange the "in use by wait set" state for this timer.
209
260
/* *
0 commit comments