ros2_interfaces_rolling/topic_tools_interfaces/srv/
mux_select.rs

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
use serde::{Deserialize, Serialize};


#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
pub struct MuxSelectReq {
    pub topic: ::std::string::String,
}

impl Default for MuxSelectReq {
    fn default() -> Self {
        MuxSelectReq {
            topic: ::std::string::String::new(),
        }
    }
}

impl ros2_client::Message for MuxSelectReq {}



#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
pub struct MuxSelectRes {
    pub prev_topic: ::std::string::String,
    pub success: bool,
}

impl Default for MuxSelectRes {
    fn default() -> Self {
        MuxSelectRes {
            prev_topic: ::std::string::String::new(),
            success: false,
        }
    }
}

impl ros2_client::Message for MuxSelectRes {}


pub struct MuxSelect;
impl ros2_client::Service for MuxSelect {
    type Request = MuxSelectReq;
    type Response = MuxSelectRes;

    fn request_type_name(&self) -> &str { "MuxSelectReq" }
    fn response_type_name(&self) -> &str { "MuxSelectRes" }
}