1#[allow(clippy::derive_partial_eq_without_eq)]
3#[derive(Clone, PartialEq, ::prost::Message)]
4pub struct Request {
5 #[prost(oneof="request::RequestType", tags="1, 2")]
6 pub request_type: ::core::option::Option<request::RequestType>,
7}
8pub mod request {
10 #[allow(clippy::derive_partial_eq_without_eq)]
11#[derive(Clone, PartialEq, ::prost::Oneof)]
12 pub enum RequestType {
13 #[prost(bool, tag="1")]
14 ListAllBehaviors(bool),
15 #[prost(message, tag="2")]
16 GetBehaviorDetails(super::GetBehaviorDetailsRequest),
17 }
18}
19#[allow(clippy::derive_partial_eq_without_eq)]
20#[derive(Clone, PartialEq, ::prost::Message)]
21pub struct GetBehaviorDetailsRequest {
22 #[prost(uint32, tag="1")]
23 pub behavior_id: u32,
24}
25#[allow(clippy::derive_partial_eq_without_eq)]
26#[derive(Clone, PartialEq, ::prost::Message)]
27pub struct Response {
28 #[prost(oneof="response::ResponseType", tags="1, 2")]
29 pub response_type: ::core::option::Option<response::ResponseType>,
30}
31pub mod response {
33 #[allow(clippy::derive_partial_eq_without_eq)]
34#[derive(Clone, PartialEq, ::prost::Oneof)]
35 pub enum ResponseType {
36 #[prost(message, tag="1")]
37 ListAllBehaviors(super::ListAllBehaviorsResponse),
38 #[prost(message, tag="2")]
39 GetBehaviorDetails(super::GetBehaviorDetailsResponse),
40 }
41}
42#[allow(clippy::derive_partial_eq_without_eq)]
43#[derive(Clone, PartialEq, ::prost::Message)]
44pub struct ListAllBehaviorsResponse {
45 #[prost(uint32, repeated, tag="1")]
46 pub behaviors: ::prost::alloc::vec::Vec<u32>,
47}
48#[allow(clippy::derive_partial_eq_without_eq)]
49#[derive(Clone, PartialEq, ::prost::Message)]
50pub struct GetBehaviorDetailsResponse {
51 #[prost(uint32, tag="1")]
52 pub id: u32,
53 #[prost(string, tag="2")]
54 pub display_name: ::prost::alloc::string::String,
55 #[prost(message, repeated, tag="3")]
56 pub metadata: ::prost::alloc::vec::Vec<BehaviorBindingParametersSet>,
57}
58#[allow(clippy::derive_partial_eq_without_eq)]
59#[derive(Clone, PartialEq, ::prost::Message)]
60pub struct BehaviorBindingParametersSet {
61 #[prost(message, repeated, tag="1")]
62 pub param1: ::prost::alloc::vec::Vec<BehaviorParameterValueDescription>,
63 #[prost(message, repeated, tag="2")]
64 pub param2: ::prost::alloc::vec::Vec<BehaviorParameterValueDescription>,
65}
66#[allow(clippy::derive_partial_eq_without_eq)]
67#[derive(Clone, PartialEq, ::prost::Message)]
68pub struct BehaviorParameterValueDescriptionRange {
69 #[prost(int32, tag="1")]
70 pub min: i32,
71 #[prost(int32, tag="2")]
72 pub max: i32,
73}
74#[allow(clippy::derive_partial_eq_without_eq)]
75#[derive(Clone, PartialEq, ::prost::Message)]
76pub struct BehaviorParameterNil {
77}
78#[allow(clippy::derive_partial_eq_without_eq)]
79#[derive(Clone, PartialEq, ::prost::Message)]
80pub struct BehaviorParameterLayerIndex {
81}
82#[allow(clippy::derive_partial_eq_without_eq)]
83#[derive(Clone, PartialEq, ::prost::Message)]
84pub struct BehaviorParameterHidUsage {
85 #[prost(uint32, tag="1")]
86 pub keyboard_max: u32,
87 #[prost(uint32, tag="2")]
88 pub consumer_max: u32,
89}
90#[allow(clippy::derive_partial_eq_without_eq)]
91#[derive(Clone, PartialEq, ::prost::Message)]
92pub struct BehaviorParameterValueDescription {
93 #[prost(string, tag="1")]
94 pub name: ::prost::alloc::string::String,
95 #[prost(oneof="behavior_parameter_value_description::ValueType", tags="2, 3, 4, 5, 6")]
96 pub value_type: ::core::option::Option<behavior_parameter_value_description::ValueType>,
97}
98pub mod behavior_parameter_value_description {
100 #[allow(clippy::derive_partial_eq_without_eq)]
101#[derive(Clone, PartialEq, ::prost::Oneof)]
102 pub enum ValueType {
103 #[prost(message, tag="2")]
104 Nil(super::BehaviorParameterNil),
105 #[prost(uint32, tag="3")]
106 Constant(u32),
107 #[prost(message, tag="4")]
108 Range(super::BehaviorParameterValueDescriptionRange),
109 #[prost(message, tag="5")]
110 HidUsage(super::BehaviorParameterHidUsage),
111 #[prost(message, tag="6")]
112 LayerIndex(super::BehaviorParameterLayerIndex),
113 }
114}
115#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
116#[repr(i32)]
117pub enum BehaviorBindingParameterStandardDomain {
118 Nil = 0,
119 HidUsage = 1,
120 LayerIndex = 2,
122}
123impl BehaviorBindingParameterStandardDomain {
124 pub fn as_str_name(&self) -> &'static str {
129 match self {
130 BehaviorBindingParameterStandardDomain::Nil => "NIL",
131 BehaviorBindingParameterStandardDomain::HidUsage => "HID_USAGE",
132 BehaviorBindingParameterStandardDomain::LayerIndex => "LAYER_INDEX",
133 }
134 }
135 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
137 match value {
138 "NIL" => Some(Self::Nil),
139 "HID_USAGE" => Some(Self::HidUsage),
140 "LAYER_INDEX" => Some(Self::LayerIndex),
141 _ => None,
142 }
143 }
144}
145