1 // This file is generated by rust-protobuf 3.2.0. Do not edit
2 // .proto file is parsed by protoc 3.21.12
3 // @generated
4
5 // https://github.com/rust-lang/rust-clippy/issues/702
6 #![allow(unknown_lints)]
7 #![allow(clippy::all)]
8
9 #![allow(unused_attributes)]
10 #![cfg_attr(rustfmt, rustfmt::skip)]
11
12 #![allow(box_pointers)]
13 #![allow(dead_code)]
14 #![allow(missing_docs)]
15 #![allow(non_camel_case_types)]
16 #![allow(non_snake_case)]
17 #![allow(non_upper_case_globals)]
18 #![allow(trivial_casts)]
19 #![allow(unused_results)]
20 #![allow(unused_mut)]
21
22 //! Generated file from `rootcanal/configuration.proto`
23
24 /// Generated files are compatible only with the same version
25 /// of protobuf runtime.
26 const _PROTOBUF_VERSION_CHECK: () = ::protobuf::VERSION_3_2_0;
27
28 #[derive(PartialEq,Clone,Default,Debug)]
29 // @@protoc_insertion_point(message:rootcanal.configuration.ControllerFeatures)
30 pub struct ControllerFeatures {
31 // message fields
32 // @@protoc_insertion_point(field:rootcanal.configuration.ControllerFeatures.le_extended_advertising)
33 pub le_extended_advertising: ::std::option::Option<bool>,
34 // @@protoc_insertion_point(field:rootcanal.configuration.ControllerFeatures.le_periodic_advertising)
35 pub le_periodic_advertising: ::std::option::Option<bool>,
36 // @@protoc_insertion_point(field:rootcanal.configuration.ControllerFeatures.ll_privacy)
37 pub ll_privacy: ::std::option::Option<bool>,
38 // @@protoc_insertion_point(field:rootcanal.configuration.ControllerFeatures.le_2m_phy)
39 pub le_2m_phy: ::std::option::Option<bool>,
40 // @@protoc_insertion_point(field:rootcanal.configuration.ControllerFeatures.le_coded_phy)
41 pub le_coded_phy: ::std::option::Option<bool>,
42 // @@protoc_insertion_point(field:rootcanal.configuration.ControllerFeatures.le_connected_isochronous_stream)
43 pub le_connected_isochronous_stream: ::std::option::Option<bool>,
44 // special fields
45 // @@protoc_insertion_point(special_field:rootcanal.configuration.ControllerFeatures.special_fields)
46 pub special_fields: ::protobuf::SpecialFields,
47 }
48
49 impl<'a> ::std::default::Default for &'a ControllerFeatures {
default() -> &'a ControllerFeatures50 fn default() -> &'a ControllerFeatures {
51 <ControllerFeatures as ::protobuf::Message>::default_instance()
52 }
53 }
54
55 impl ControllerFeatures {
new() -> ControllerFeatures56 pub fn new() -> ControllerFeatures {
57 ::std::default::Default::default()
58 }
59
60 // optional bool le_extended_advertising = 1;
61
le_extended_advertising(&self) -> bool62 pub fn le_extended_advertising(&self) -> bool {
63 self.le_extended_advertising.unwrap_or(false)
64 }
65
clear_le_extended_advertising(&mut self)66 pub fn clear_le_extended_advertising(&mut self) {
67 self.le_extended_advertising = ::std::option::Option::None;
68 }
69
has_le_extended_advertising(&self) -> bool70 pub fn has_le_extended_advertising(&self) -> bool {
71 self.le_extended_advertising.is_some()
72 }
73
74 // Param is passed by value, moved
set_le_extended_advertising(&mut self, v: bool)75 pub fn set_le_extended_advertising(&mut self, v: bool) {
76 self.le_extended_advertising = ::std::option::Option::Some(v);
77 }
78
79 // optional bool le_periodic_advertising = 2;
80
le_periodic_advertising(&self) -> bool81 pub fn le_periodic_advertising(&self) -> bool {
82 self.le_periodic_advertising.unwrap_or(false)
83 }
84
clear_le_periodic_advertising(&mut self)85 pub fn clear_le_periodic_advertising(&mut self) {
86 self.le_periodic_advertising = ::std::option::Option::None;
87 }
88
has_le_periodic_advertising(&self) -> bool89 pub fn has_le_periodic_advertising(&self) -> bool {
90 self.le_periodic_advertising.is_some()
91 }
92
93 // Param is passed by value, moved
set_le_periodic_advertising(&mut self, v: bool)94 pub fn set_le_periodic_advertising(&mut self, v: bool) {
95 self.le_periodic_advertising = ::std::option::Option::Some(v);
96 }
97
98 // optional bool ll_privacy = 3;
99
ll_privacy(&self) -> bool100 pub fn ll_privacy(&self) -> bool {
101 self.ll_privacy.unwrap_or(false)
102 }
103
clear_ll_privacy(&mut self)104 pub fn clear_ll_privacy(&mut self) {
105 self.ll_privacy = ::std::option::Option::None;
106 }
107
has_ll_privacy(&self) -> bool108 pub fn has_ll_privacy(&self) -> bool {
109 self.ll_privacy.is_some()
110 }
111
112 // Param is passed by value, moved
set_ll_privacy(&mut self, v: bool)113 pub fn set_ll_privacy(&mut self, v: bool) {
114 self.ll_privacy = ::std::option::Option::Some(v);
115 }
116
117 // optional bool le_2m_phy = 4;
118
le_2m_phy(&self) -> bool119 pub fn le_2m_phy(&self) -> bool {
120 self.le_2m_phy.unwrap_or(false)
121 }
122
clear_le_2m_phy(&mut self)123 pub fn clear_le_2m_phy(&mut self) {
124 self.le_2m_phy = ::std::option::Option::None;
125 }
126
has_le_2m_phy(&self) -> bool127 pub fn has_le_2m_phy(&self) -> bool {
128 self.le_2m_phy.is_some()
129 }
130
131 // Param is passed by value, moved
set_le_2m_phy(&mut self, v: bool)132 pub fn set_le_2m_phy(&mut self, v: bool) {
133 self.le_2m_phy = ::std::option::Option::Some(v);
134 }
135
136 // optional bool le_coded_phy = 5;
137
le_coded_phy(&self) -> bool138 pub fn le_coded_phy(&self) -> bool {
139 self.le_coded_phy.unwrap_or(false)
140 }
141
clear_le_coded_phy(&mut self)142 pub fn clear_le_coded_phy(&mut self) {
143 self.le_coded_phy = ::std::option::Option::None;
144 }
145
has_le_coded_phy(&self) -> bool146 pub fn has_le_coded_phy(&self) -> bool {
147 self.le_coded_phy.is_some()
148 }
149
150 // Param is passed by value, moved
set_le_coded_phy(&mut self, v: bool)151 pub fn set_le_coded_phy(&mut self, v: bool) {
152 self.le_coded_phy = ::std::option::Option::Some(v);
153 }
154
155 // optional bool le_connected_isochronous_stream = 6;
156
le_connected_isochronous_stream(&self) -> bool157 pub fn le_connected_isochronous_stream(&self) -> bool {
158 self.le_connected_isochronous_stream.unwrap_or(false)
159 }
160
clear_le_connected_isochronous_stream(&mut self)161 pub fn clear_le_connected_isochronous_stream(&mut self) {
162 self.le_connected_isochronous_stream = ::std::option::Option::None;
163 }
164
has_le_connected_isochronous_stream(&self) -> bool165 pub fn has_le_connected_isochronous_stream(&self) -> bool {
166 self.le_connected_isochronous_stream.is_some()
167 }
168
169 // Param is passed by value, moved
set_le_connected_isochronous_stream(&mut self, v: bool)170 pub fn set_le_connected_isochronous_stream(&mut self, v: bool) {
171 self.le_connected_isochronous_stream = ::std::option::Option::Some(v);
172 }
173
generated_message_descriptor_data() -> ::protobuf::reflect::GeneratedMessageDescriptorData174 fn generated_message_descriptor_data() -> ::protobuf::reflect::GeneratedMessageDescriptorData {
175 let mut fields = ::std::vec::Vec::with_capacity(6);
176 let mut oneofs = ::std::vec::Vec::with_capacity(0);
177 fields.push(::protobuf::reflect::rt::v2::make_option_accessor::<_, _>(
178 "le_extended_advertising",
179 |m: &ControllerFeatures| { &m.le_extended_advertising },
180 |m: &mut ControllerFeatures| { &mut m.le_extended_advertising },
181 ));
182 fields.push(::protobuf::reflect::rt::v2::make_option_accessor::<_, _>(
183 "le_periodic_advertising",
184 |m: &ControllerFeatures| { &m.le_periodic_advertising },
185 |m: &mut ControllerFeatures| { &mut m.le_periodic_advertising },
186 ));
187 fields.push(::protobuf::reflect::rt::v2::make_option_accessor::<_, _>(
188 "ll_privacy",
189 |m: &ControllerFeatures| { &m.ll_privacy },
190 |m: &mut ControllerFeatures| { &mut m.ll_privacy },
191 ));
192 fields.push(::protobuf::reflect::rt::v2::make_option_accessor::<_, _>(
193 "le_2m_phy",
194 |m: &ControllerFeatures| { &m.le_2m_phy },
195 |m: &mut ControllerFeatures| { &mut m.le_2m_phy },
196 ));
197 fields.push(::protobuf::reflect::rt::v2::make_option_accessor::<_, _>(
198 "le_coded_phy",
199 |m: &ControllerFeatures| { &m.le_coded_phy },
200 |m: &mut ControllerFeatures| { &mut m.le_coded_phy },
201 ));
202 fields.push(::protobuf::reflect::rt::v2::make_option_accessor::<_, _>(
203 "le_connected_isochronous_stream",
204 |m: &ControllerFeatures| { &m.le_connected_isochronous_stream },
205 |m: &mut ControllerFeatures| { &mut m.le_connected_isochronous_stream },
206 ));
207 ::protobuf::reflect::GeneratedMessageDescriptorData::new_2::<ControllerFeatures>(
208 "ControllerFeatures",
209 fields,
210 oneofs,
211 )
212 }
213 }
214
215 impl ::protobuf::Message for ControllerFeatures {
216 const NAME: &'static str = "ControllerFeatures";
217
is_initialized(&self) -> bool218 fn is_initialized(&self) -> bool {
219 true
220 }
221
merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::Result<()>222 fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::Result<()> {
223 while let Some(tag) = is.read_raw_tag_or_eof()? {
224 match tag {
225 8 => {
226 self.le_extended_advertising = ::std::option::Option::Some(is.read_bool()?);
227 },
228 16 => {
229 self.le_periodic_advertising = ::std::option::Option::Some(is.read_bool()?);
230 },
231 24 => {
232 self.ll_privacy = ::std::option::Option::Some(is.read_bool()?);
233 },
234 32 => {
235 self.le_2m_phy = ::std::option::Option::Some(is.read_bool()?);
236 },
237 40 => {
238 self.le_coded_phy = ::std::option::Option::Some(is.read_bool()?);
239 },
240 48 => {
241 self.le_connected_isochronous_stream = ::std::option::Option::Some(is.read_bool()?);
242 },
243 tag => {
244 ::protobuf::rt::read_unknown_or_skip_group(tag, is, self.special_fields.mut_unknown_fields())?;
245 },
246 };
247 }
248 ::std::result::Result::Ok(())
249 }
250
251 // Compute sizes of nested messages
252 #[allow(unused_variables)]
compute_size(&self) -> u64253 fn compute_size(&self) -> u64 {
254 let mut my_size = 0;
255 if let Some(v) = self.le_extended_advertising {
256 my_size += 1 + 1;
257 }
258 if let Some(v) = self.le_periodic_advertising {
259 my_size += 1 + 1;
260 }
261 if let Some(v) = self.ll_privacy {
262 my_size += 1 + 1;
263 }
264 if let Some(v) = self.le_2m_phy {
265 my_size += 1 + 1;
266 }
267 if let Some(v) = self.le_coded_phy {
268 my_size += 1 + 1;
269 }
270 if let Some(v) = self.le_connected_isochronous_stream {
271 my_size += 1 + 1;
272 }
273 my_size += ::protobuf::rt::unknown_fields_size(self.special_fields.unknown_fields());
274 self.special_fields.cached_size().set(my_size as u32);
275 my_size
276 }
277
write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::Result<()>278 fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::Result<()> {
279 if let Some(v) = self.le_extended_advertising {
280 os.write_bool(1, v)?;
281 }
282 if let Some(v) = self.le_periodic_advertising {
283 os.write_bool(2, v)?;
284 }
285 if let Some(v) = self.ll_privacy {
286 os.write_bool(3, v)?;
287 }
288 if let Some(v) = self.le_2m_phy {
289 os.write_bool(4, v)?;
290 }
291 if let Some(v) = self.le_coded_phy {
292 os.write_bool(5, v)?;
293 }
294 if let Some(v) = self.le_connected_isochronous_stream {
295 os.write_bool(6, v)?;
296 }
297 os.write_unknown_fields(self.special_fields.unknown_fields())?;
298 ::std::result::Result::Ok(())
299 }
300
special_fields(&self) -> &::protobuf::SpecialFields301 fn special_fields(&self) -> &::protobuf::SpecialFields {
302 &self.special_fields
303 }
304
mut_special_fields(&mut self) -> &mut ::protobuf::SpecialFields305 fn mut_special_fields(&mut self) -> &mut ::protobuf::SpecialFields {
306 &mut self.special_fields
307 }
308
new() -> ControllerFeatures309 fn new() -> ControllerFeatures {
310 ControllerFeatures::new()
311 }
312
clear(&mut self)313 fn clear(&mut self) {
314 self.le_extended_advertising = ::std::option::Option::None;
315 self.le_periodic_advertising = ::std::option::Option::None;
316 self.ll_privacy = ::std::option::Option::None;
317 self.le_2m_phy = ::std::option::Option::None;
318 self.le_coded_phy = ::std::option::Option::None;
319 self.le_connected_isochronous_stream = ::std::option::Option::None;
320 self.special_fields.clear();
321 }
322
default_instance() -> &'static ControllerFeatures323 fn default_instance() -> &'static ControllerFeatures {
324 static instance: ControllerFeatures = ControllerFeatures {
325 le_extended_advertising: ::std::option::Option::None,
326 le_periodic_advertising: ::std::option::Option::None,
327 ll_privacy: ::std::option::Option::None,
328 le_2m_phy: ::std::option::Option::None,
329 le_coded_phy: ::std::option::Option::None,
330 le_connected_isochronous_stream: ::std::option::Option::None,
331 special_fields: ::protobuf::SpecialFields::new(),
332 };
333 &instance
334 }
335 }
336
337 impl ::protobuf::MessageFull for ControllerFeatures {
descriptor() -> ::protobuf::reflect::MessageDescriptor338 fn descriptor() -> ::protobuf::reflect::MessageDescriptor {
339 static descriptor: ::protobuf::rt::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::rt::Lazy::new();
340 descriptor.get(|| file_descriptor().message_by_package_relative_name("ControllerFeatures").unwrap()).clone()
341 }
342 }
343
344 impl ::std::fmt::Display for ControllerFeatures {
fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result345 fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
346 ::protobuf::text_format::fmt(self, f)
347 }
348 }
349
350 impl ::protobuf::reflect::ProtobufValue for ControllerFeatures {
351 type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage<Self>;
352 }
353
354 #[derive(PartialEq,Clone,Default,Debug)]
355 // @@protoc_insertion_point(message:rootcanal.configuration.ControllerQuirks)
356 pub struct ControllerQuirks {
357 // message fields
358 // @@protoc_insertion_point(field:rootcanal.configuration.ControllerQuirks.send_acl_data_before_connection_complete)
359 pub send_acl_data_before_connection_complete: ::std::option::Option<bool>,
360 // @@protoc_insertion_point(field:rootcanal.configuration.ControllerQuirks.has_default_random_address)
361 pub has_default_random_address: ::std::option::Option<bool>,
362 // @@protoc_insertion_point(field:rootcanal.configuration.ControllerQuirks.hardware_error_before_reset)
363 pub hardware_error_before_reset: ::std::option::Option<bool>,
364 // special fields
365 // @@protoc_insertion_point(special_field:rootcanal.configuration.ControllerQuirks.special_fields)
366 pub special_fields: ::protobuf::SpecialFields,
367 }
368
369 impl<'a> ::std::default::Default for &'a ControllerQuirks {
default() -> &'a ControllerQuirks370 fn default() -> &'a ControllerQuirks {
371 <ControllerQuirks as ::protobuf::Message>::default_instance()
372 }
373 }
374
375 impl ControllerQuirks {
new() -> ControllerQuirks376 pub fn new() -> ControllerQuirks {
377 ::std::default::Default::default()
378 }
379
380 // optional bool send_acl_data_before_connection_complete = 1;
381
send_acl_data_before_connection_complete(&self) -> bool382 pub fn send_acl_data_before_connection_complete(&self) -> bool {
383 self.send_acl_data_before_connection_complete.unwrap_or(false)
384 }
385
clear_send_acl_data_before_connection_complete(&mut self)386 pub fn clear_send_acl_data_before_connection_complete(&mut self) {
387 self.send_acl_data_before_connection_complete = ::std::option::Option::None;
388 }
389
has_send_acl_data_before_connection_complete(&self) -> bool390 pub fn has_send_acl_data_before_connection_complete(&self) -> bool {
391 self.send_acl_data_before_connection_complete.is_some()
392 }
393
394 // Param is passed by value, moved
set_send_acl_data_before_connection_complete(&mut self, v: bool)395 pub fn set_send_acl_data_before_connection_complete(&mut self, v: bool) {
396 self.send_acl_data_before_connection_complete = ::std::option::Option::Some(v);
397 }
398
399 // optional bool has_default_random_address = 2;
400
has_default_random_address(&self) -> bool401 pub fn has_default_random_address(&self) -> bool {
402 self.has_default_random_address.unwrap_or(false)
403 }
404
clear_has_default_random_address(&mut self)405 pub fn clear_has_default_random_address(&mut self) {
406 self.has_default_random_address = ::std::option::Option::None;
407 }
408
has_has_default_random_address(&self) -> bool409 pub fn has_has_default_random_address(&self) -> bool {
410 self.has_default_random_address.is_some()
411 }
412
413 // Param is passed by value, moved
set_has_default_random_address(&mut self, v: bool)414 pub fn set_has_default_random_address(&mut self, v: bool) {
415 self.has_default_random_address = ::std::option::Option::Some(v);
416 }
417
418 // optional bool hardware_error_before_reset = 3;
419
hardware_error_before_reset(&self) -> bool420 pub fn hardware_error_before_reset(&self) -> bool {
421 self.hardware_error_before_reset.unwrap_or(false)
422 }
423
clear_hardware_error_before_reset(&mut self)424 pub fn clear_hardware_error_before_reset(&mut self) {
425 self.hardware_error_before_reset = ::std::option::Option::None;
426 }
427
has_hardware_error_before_reset(&self) -> bool428 pub fn has_hardware_error_before_reset(&self) -> bool {
429 self.hardware_error_before_reset.is_some()
430 }
431
432 // Param is passed by value, moved
set_hardware_error_before_reset(&mut self, v: bool)433 pub fn set_hardware_error_before_reset(&mut self, v: bool) {
434 self.hardware_error_before_reset = ::std::option::Option::Some(v);
435 }
436
generated_message_descriptor_data() -> ::protobuf::reflect::GeneratedMessageDescriptorData437 fn generated_message_descriptor_data() -> ::protobuf::reflect::GeneratedMessageDescriptorData {
438 let mut fields = ::std::vec::Vec::with_capacity(3);
439 let mut oneofs = ::std::vec::Vec::with_capacity(0);
440 fields.push(::protobuf::reflect::rt::v2::make_option_accessor::<_, _>(
441 "send_acl_data_before_connection_complete",
442 |m: &ControllerQuirks| { &m.send_acl_data_before_connection_complete },
443 |m: &mut ControllerQuirks| { &mut m.send_acl_data_before_connection_complete },
444 ));
445 fields.push(::protobuf::reflect::rt::v2::make_option_accessor::<_, _>(
446 "has_default_random_address",
447 |m: &ControllerQuirks| { &m.has_default_random_address },
448 |m: &mut ControllerQuirks| { &mut m.has_default_random_address },
449 ));
450 fields.push(::protobuf::reflect::rt::v2::make_option_accessor::<_, _>(
451 "hardware_error_before_reset",
452 |m: &ControllerQuirks| { &m.hardware_error_before_reset },
453 |m: &mut ControllerQuirks| { &mut m.hardware_error_before_reset },
454 ));
455 ::protobuf::reflect::GeneratedMessageDescriptorData::new_2::<ControllerQuirks>(
456 "ControllerQuirks",
457 fields,
458 oneofs,
459 )
460 }
461 }
462
463 impl ::protobuf::Message for ControllerQuirks {
464 const NAME: &'static str = "ControllerQuirks";
465
is_initialized(&self) -> bool466 fn is_initialized(&self) -> bool {
467 true
468 }
469
merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::Result<()>470 fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::Result<()> {
471 while let Some(tag) = is.read_raw_tag_or_eof()? {
472 match tag {
473 8 => {
474 self.send_acl_data_before_connection_complete = ::std::option::Option::Some(is.read_bool()?);
475 },
476 16 => {
477 self.has_default_random_address = ::std::option::Option::Some(is.read_bool()?);
478 },
479 24 => {
480 self.hardware_error_before_reset = ::std::option::Option::Some(is.read_bool()?);
481 },
482 tag => {
483 ::protobuf::rt::read_unknown_or_skip_group(tag, is, self.special_fields.mut_unknown_fields())?;
484 },
485 };
486 }
487 ::std::result::Result::Ok(())
488 }
489
490 // Compute sizes of nested messages
491 #[allow(unused_variables)]
compute_size(&self) -> u64492 fn compute_size(&self) -> u64 {
493 let mut my_size = 0;
494 if let Some(v) = self.send_acl_data_before_connection_complete {
495 my_size += 1 + 1;
496 }
497 if let Some(v) = self.has_default_random_address {
498 my_size += 1 + 1;
499 }
500 if let Some(v) = self.hardware_error_before_reset {
501 my_size += 1 + 1;
502 }
503 my_size += ::protobuf::rt::unknown_fields_size(self.special_fields.unknown_fields());
504 self.special_fields.cached_size().set(my_size as u32);
505 my_size
506 }
507
write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::Result<()>508 fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::Result<()> {
509 if let Some(v) = self.send_acl_data_before_connection_complete {
510 os.write_bool(1, v)?;
511 }
512 if let Some(v) = self.has_default_random_address {
513 os.write_bool(2, v)?;
514 }
515 if let Some(v) = self.hardware_error_before_reset {
516 os.write_bool(3, v)?;
517 }
518 os.write_unknown_fields(self.special_fields.unknown_fields())?;
519 ::std::result::Result::Ok(())
520 }
521
special_fields(&self) -> &::protobuf::SpecialFields522 fn special_fields(&self) -> &::protobuf::SpecialFields {
523 &self.special_fields
524 }
525
mut_special_fields(&mut self) -> &mut ::protobuf::SpecialFields526 fn mut_special_fields(&mut self) -> &mut ::protobuf::SpecialFields {
527 &mut self.special_fields
528 }
529
new() -> ControllerQuirks530 fn new() -> ControllerQuirks {
531 ControllerQuirks::new()
532 }
533
clear(&mut self)534 fn clear(&mut self) {
535 self.send_acl_data_before_connection_complete = ::std::option::Option::None;
536 self.has_default_random_address = ::std::option::Option::None;
537 self.hardware_error_before_reset = ::std::option::Option::None;
538 self.special_fields.clear();
539 }
540
default_instance() -> &'static ControllerQuirks541 fn default_instance() -> &'static ControllerQuirks {
542 static instance: ControllerQuirks = ControllerQuirks {
543 send_acl_data_before_connection_complete: ::std::option::Option::None,
544 has_default_random_address: ::std::option::Option::None,
545 hardware_error_before_reset: ::std::option::Option::None,
546 special_fields: ::protobuf::SpecialFields::new(),
547 };
548 &instance
549 }
550 }
551
552 impl ::protobuf::MessageFull for ControllerQuirks {
descriptor() -> ::protobuf::reflect::MessageDescriptor553 fn descriptor() -> ::protobuf::reflect::MessageDescriptor {
554 static descriptor: ::protobuf::rt::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::rt::Lazy::new();
555 descriptor.get(|| file_descriptor().message_by_package_relative_name("ControllerQuirks").unwrap()).clone()
556 }
557 }
558
559 impl ::std::fmt::Display for ControllerQuirks {
fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result560 fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
561 ::protobuf::text_format::fmt(self, f)
562 }
563 }
564
565 impl ::protobuf::reflect::ProtobufValue for ControllerQuirks {
566 type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage<Self>;
567 }
568
569 #[derive(PartialEq,Clone,Default,Debug)]
570 // @@protoc_insertion_point(message:rootcanal.configuration.VendorFeatures)
571 pub struct VendorFeatures {
572 // message fields
573 // @@protoc_insertion_point(field:rootcanal.configuration.VendorFeatures.csr)
574 pub csr: ::std::option::Option<bool>,
575 // @@protoc_insertion_point(field:rootcanal.configuration.VendorFeatures.android)
576 pub android: ::std::option::Option<bool>,
577 // special fields
578 // @@protoc_insertion_point(special_field:rootcanal.configuration.VendorFeatures.special_fields)
579 pub special_fields: ::protobuf::SpecialFields,
580 }
581
582 impl<'a> ::std::default::Default for &'a VendorFeatures {
default() -> &'a VendorFeatures583 fn default() -> &'a VendorFeatures {
584 <VendorFeatures as ::protobuf::Message>::default_instance()
585 }
586 }
587
588 impl VendorFeatures {
new() -> VendorFeatures589 pub fn new() -> VendorFeatures {
590 ::std::default::Default::default()
591 }
592
593 // optional bool csr = 1;
594
csr(&self) -> bool595 pub fn csr(&self) -> bool {
596 self.csr.unwrap_or(false)
597 }
598
clear_csr(&mut self)599 pub fn clear_csr(&mut self) {
600 self.csr = ::std::option::Option::None;
601 }
602
has_csr(&self) -> bool603 pub fn has_csr(&self) -> bool {
604 self.csr.is_some()
605 }
606
607 // Param is passed by value, moved
set_csr(&mut self, v: bool)608 pub fn set_csr(&mut self, v: bool) {
609 self.csr = ::std::option::Option::Some(v);
610 }
611
612 // optional bool android = 2;
613
android(&self) -> bool614 pub fn android(&self) -> bool {
615 self.android.unwrap_or(false)
616 }
617
clear_android(&mut self)618 pub fn clear_android(&mut self) {
619 self.android = ::std::option::Option::None;
620 }
621
has_android(&self) -> bool622 pub fn has_android(&self) -> bool {
623 self.android.is_some()
624 }
625
626 // Param is passed by value, moved
set_android(&mut self, v: bool)627 pub fn set_android(&mut self, v: bool) {
628 self.android = ::std::option::Option::Some(v);
629 }
630
generated_message_descriptor_data() -> ::protobuf::reflect::GeneratedMessageDescriptorData631 fn generated_message_descriptor_data() -> ::protobuf::reflect::GeneratedMessageDescriptorData {
632 let mut fields = ::std::vec::Vec::with_capacity(2);
633 let mut oneofs = ::std::vec::Vec::with_capacity(0);
634 fields.push(::protobuf::reflect::rt::v2::make_option_accessor::<_, _>(
635 "csr",
636 |m: &VendorFeatures| { &m.csr },
637 |m: &mut VendorFeatures| { &mut m.csr },
638 ));
639 fields.push(::protobuf::reflect::rt::v2::make_option_accessor::<_, _>(
640 "android",
641 |m: &VendorFeatures| { &m.android },
642 |m: &mut VendorFeatures| { &mut m.android },
643 ));
644 ::protobuf::reflect::GeneratedMessageDescriptorData::new_2::<VendorFeatures>(
645 "VendorFeatures",
646 fields,
647 oneofs,
648 )
649 }
650 }
651
652 impl ::protobuf::Message for VendorFeatures {
653 const NAME: &'static str = "VendorFeatures";
654
is_initialized(&self) -> bool655 fn is_initialized(&self) -> bool {
656 true
657 }
658
merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::Result<()>659 fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::Result<()> {
660 while let Some(tag) = is.read_raw_tag_or_eof()? {
661 match tag {
662 8 => {
663 self.csr = ::std::option::Option::Some(is.read_bool()?);
664 },
665 16 => {
666 self.android = ::std::option::Option::Some(is.read_bool()?);
667 },
668 tag => {
669 ::protobuf::rt::read_unknown_or_skip_group(tag, is, self.special_fields.mut_unknown_fields())?;
670 },
671 };
672 }
673 ::std::result::Result::Ok(())
674 }
675
676 // Compute sizes of nested messages
677 #[allow(unused_variables)]
compute_size(&self) -> u64678 fn compute_size(&self) -> u64 {
679 let mut my_size = 0;
680 if let Some(v) = self.csr {
681 my_size += 1 + 1;
682 }
683 if let Some(v) = self.android {
684 my_size += 1 + 1;
685 }
686 my_size += ::protobuf::rt::unknown_fields_size(self.special_fields.unknown_fields());
687 self.special_fields.cached_size().set(my_size as u32);
688 my_size
689 }
690
write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::Result<()>691 fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::Result<()> {
692 if let Some(v) = self.csr {
693 os.write_bool(1, v)?;
694 }
695 if let Some(v) = self.android {
696 os.write_bool(2, v)?;
697 }
698 os.write_unknown_fields(self.special_fields.unknown_fields())?;
699 ::std::result::Result::Ok(())
700 }
701
special_fields(&self) -> &::protobuf::SpecialFields702 fn special_fields(&self) -> &::protobuf::SpecialFields {
703 &self.special_fields
704 }
705
mut_special_fields(&mut self) -> &mut ::protobuf::SpecialFields706 fn mut_special_fields(&mut self) -> &mut ::protobuf::SpecialFields {
707 &mut self.special_fields
708 }
709
new() -> VendorFeatures710 fn new() -> VendorFeatures {
711 VendorFeatures::new()
712 }
713
clear(&mut self)714 fn clear(&mut self) {
715 self.csr = ::std::option::Option::None;
716 self.android = ::std::option::Option::None;
717 self.special_fields.clear();
718 }
719
default_instance() -> &'static VendorFeatures720 fn default_instance() -> &'static VendorFeatures {
721 static instance: VendorFeatures = VendorFeatures {
722 csr: ::std::option::Option::None,
723 android: ::std::option::Option::None,
724 special_fields: ::protobuf::SpecialFields::new(),
725 };
726 &instance
727 }
728 }
729
730 impl ::protobuf::MessageFull for VendorFeatures {
descriptor() -> ::protobuf::reflect::MessageDescriptor731 fn descriptor() -> ::protobuf::reflect::MessageDescriptor {
732 static descriptor: ::protobuf::rt::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::rt::Lazy::new();
733 descriptor.get(|| file_descriptor().message_by_package_relative_name("VendorFeatures").unwrap()).clone()
734 }
735 }
736
737 impl ::std::fmt::Display for VendorFeatures {
fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result738 fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
739 ::protobuf::text_format::fmt(self, f)
740 }
741 }
742
743 impl ::protobuf::reflect::ProtobufValue for VendorFeatures {
744 type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage<Self>;
745 }
746
747 #[derive(PartialEq,Clone,Default,Debug)]
748 // @@protoc_insertion_point(message:rootcanal.configuration.Controller)
749 pub struct Controller {
750 // message fields
751 // @@protoc_insertion_point(field:rootcanal.configuration.Controller.preset)
752 pub preset: ::std::option::Option<::protobuf::EnumOrUnknown<ControllerPreset>>,
753 // @@protoc_insertion_point(field:rootcanal.configuration.Controller.features)
754 pub features: ::protobuf::MessageField<ControllerFeatures>,
755 // @@protoc_insertion_point(field:rootcanal.configuration.Controller.quirks)
756 pub quirks: ::protobuf::MessageField<ControllerQuirks>,
757 // @@protoc_insertion_point(field:rootcanal.configuration.Controller.strict)
758 pub strict: ::std::option::Option<bool>,
759 // @@protoc_insertion_point(field:rootcanal.configuration.Controller.vendor)
760 pub vendor: ::protobuf::MessageField<VendorFeatures>,
761 // special fields
762 // @@protoc_insertion_point(special_field:rootcanal.configuration.Controller.special_fields)
763 pub special_fields: ::protobuf::SpecialFields,
764 }
765
766 impl<'a> ::std::default::Default for &'a Controller {
default() -> &'a Controller767 fn default() -> &'a Controller {
768 <Controller as ::protobuf::Message>::default_instance()
769 }
770 }
771
772 impl Controller {
new() -> Controller773 pub fn new() -> Controller {
774 ::std::default::Default::default()
775 }
776
777 // optional .rootcanal.configuration.ControllerPreset preset = 1;
778
preset(&self) -> ControllerPreset779 pub fn preset(&self) -> ControllerPreset {
780 match self.preset {
781 Some(e) => e.enum_value_or(ControllerPreset::DEFAULT),
782 None => ControllerPreset::DEFAULT,
783 }
784 }
785
clear_preset(&mut self)786 pub fn clear_preset(&mut self) {
787 self.preset = ::std::option::Option::None;
788 }
789
has_preset(&self) -> bool790 pub fn has_preset(&self) -> bool {
791 self.preset.is_some()
792 }
793
794 // Param is passed by value, moved
set_preset(&mut self, v: ControllerPreset)795 pub fn set_preset(&mut self, v: ControllerPreset) {
796 self.preset = ::std::option::Option::Some(::protobuf::EnumOrUnknown::new(v));
797 }
798
799 // optional bool strict = 4;
800
strict(&self) -> bool801 pub fn strict(&self) -> bool {
802 self.strict.unwrap_or(false)
803 }
804
clear_strict(&mut self)805 pub fn clear_strict(&mut self) {
806 self.strict = ::std::option::Option::None;
807 }
808
has_strict(&self) -> bool809 pub fn has_strict(&self) -> bool {
810 self.strict.is_some()
811 }
812
813 // Param is passed by value, moved
set_strict(&mut self, v: bool)814 pub fn set_strict(&mut self, v: bool) {
815 self.strict = ::std::option::Option::Some(v);
816 }
817
generated_message_descriptor_data() -> ::protobuf::reflect::GeneratedMessageDescriptorData818 fn generated_message_descriptor_data() -> ::protobuf::reflect::GeneratedMessageDescriptorData {
819 let mut fields = ::std::vec::Vec::with_capacity(5);
820 let mut oneofs = ::std::vec::Vec::with_capacity(0);
821 fields.push(::protobuf::reflect::rt::v2::make_option_accessor::<_, _>(
822 "preset",
823 |m: &Controller| { &m.preset },
824 |m: &mut Controller| { &mut m.preset },
825 ));
826 fields.push(::protobuf::reflect::rt::v2::make_message_field_accessor::<_, ControllerFeatures>(
827 "features",
828 |m: &Controller| { &m.features },
829 |m: &mut Controller| { &mut m.features },
830 ));
831 fields.push(::protobuf::reflect::rt::v2::make_message_field_accessor::<_, ControllerQuirks>(
832 "quirks",
833 |m: &Controller| { &m.quirks },
834 |m: &mut Controller| { &mut m.quirks },
835 ));
836 fields.push(::protobuf::reflect::rt::v2::make_option_accessor::<_, _>(
837 "strict",
838 |m: &Controller| { &m.strict },
839 |m: &mut Controller| { &mut m.strict },
840 ));
841 fields.push(::protobuf::reflect::rt::v2::make_message_field_accessor::<_, VendorFeatures>(
842 "vendor",
843 |m: &Controller| { &m.vendor },
844 |m: &mut Controller| { &mut m.vendor },
845 ));
846 ::protobuf::reflect::GeneratedMessageDescriptorData::new_2::<Controller>(
847 "Controller",
848 fields,
849 oneofs,
850 )
851 }
852 }
853
854 impl ::protobuf::Message for Controller {
855 const NAME: &'static str = "Controller";
856
is_initialized(&self) -> bool857 fn is_initialized(&self) -> bool {
858 true
859 }
860
merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::Result<()>861 fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::Result<()> {
862 while let Some(tag) = is.read_raw_tag_or_eof()? {
863 match tag {
864 8 => {
865 self.preset = ::std::option::Option::Some(is.read_enum_or_unknown()?);
866 },
867 18 => {
868 ::protobuf::rt::read_singular_message_into_field(is, &mut self.features)?;
869 },
870 26 => {
871 ::protobuf::rt::read_singular_message_into_field(is, &mut self.quirks)?;
872 },
873 32 => {
874 self.strict = ::std::option::Option::Some(is.read_bool()?);
875 },
876 42 => {
877 ::protobuf::rt::read_singular_message_into_field(is, &mut self.vendor)?;
878 },
879 tag => {
880 ::protobuf::rt::read_unknown_or_skip_group(tag, is, self.special_fields.mut_unknown_fields())?;
881 },
882 };
883 }
884 ::std::result::Result::Ok(())
885 }
886
887 // Compute sizes of nested messages
888 #[allow(unused_variables)]
compute_size(&self) -> u64889 fn compute_size(&self) -> u64 {
890 let mut my_size = 0;
891 if let Some(v) = self.preset {
892 my_size += ::protobuf::rt::int32_size(1, v.value());
893 }
894 if let Some(v) = self.features.as_ref() {
895 let len = v.compute_size();
896 my_size += 1 + ::protobuf::rt::compute_raw_varint64_size(len) + len;
897 }
898 if let Some(v) = self.quirks.as_ref() {
899 let len = v.compute_size();
900 my_size += 1 + ::protobuf::rt::compute_raw_varint64_size(len) + len;
901 }
902 if let Some(v) = self.strict {
903 my_size += 1 + 1;
904 }
905 if let Some(v) = self.vendor.as_ref() {
906 let len = v.compute_size();
907 my_size += 1 + ::protobuf::rt::compute_raw_varint64_size(len) + len;
908 }
909 my_size += ::protobuf::rt::unknown_fields_size(self.special_fields.unknown_fields());
910 self.special_fields.cached_size().set(my_size as u32);
911 my_size
912 }
913
write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::Result<()>914 fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::Result<()> {
915 if let Some(v) = self.preset {
916 os.write_enum(1, ::protobuf::EnumOrUnknown::value(&v))?;
917 }
918 if let Some(v) = self.features.as_ref() {
919 ::protobuf::rt::write_message_field_with_cached_size(2, v, os)?;
920 }
921 if let Some(v) = self.quirks.as_ref() {
922 ::protobuf::rt::write_message_field_with_cached_size(3, v, os)?;
923 }
924 if let Some(v) = self.strict {
925 os.write_bool(4, v)?;
926 }
927 if let Some(v) = self.vendor.as_ref() {
928 ::protobuf::rt::write_message_field_with_cached_size(5, v, os)?;
929 }
930 os.write_unknown_fields(self.special_fields.unknown_fields())?;
931 ::std::result::Result::Ok(())
932 }
933
special_fields(&self) -> &::protobuf::SpecialFields934 fn special_fields(&self) -> &::protobuf::SpecialFields {
935 &self.special_fields
936 }
937
mut_special_fields(&mut self) -> &mut ::protobuf::SpecialFields938 fn mut_special_fields(&mut self) -> &mut ::protobuf::SpecialFields {
939 &mut self.special_fields
940 }
941
new() -> Controller942 fn new() -> Controller {
943 Controller::new()
944 }
945
clear(&mut self)946 fn clear(&mut self) {
947 self.preset = ::std::option::Option::None;
948 self.features.clear();
949 self.quirks.clear();
950 self.strict = ::std::option::Option::None;
951 self.vendor.clear();
952 self.special_fields.clear();
953 }
954
default_instance() -> &'static Controller955 fn default_instance() -> &'static Controller {
956 static instance: Controller = Controller {
957 preset: ::std::option::Option::None,
958 features: ::protobuf::MessageField::none(),
959 quirks: ::protobuf::MessageField::none(),
960 strict: ::std::option::Option::None,
961 vendor: ::protobuf::MessageField::none(),
962 special_fields: ::protobuf::SpecialFields::new(),
963 };
964 &instance
965 }
966 }
967
968 impl ::protobuf::MessageFull for Controller {
descriptor() -> ::protobuf::reflect::MessageDescriptor969 fn descriptor() -> ::protobuf::reflect::MessageDescriptor {
970 static descriptor: ::protobuf::rt::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::rt::Lazy::new();
971 descriptor.get(|| file_descriptor().message_by_package_relative_name("Controller").unwrap()).clone()
972 }
973 }
974
975 impl ::std::fmt::Display for Controller {
fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result976 fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
977 ::protobuf::text_format::fmt(self, f)
978 }
979 }
980
981 impl ::protobuf::reflect::ProtobufValue for Controller {
982 type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage<Self>;
983 }
984
985 #[derive(PartialEq,Clone,Default,Debug)]
986 // @@protoc_insertion_point(message:rootcanal.configuration.TcpServer)
987 pub struct TcpServer {
988 // message fields
989 // @@protoc_insertion_point(field:rootcanal.configuration.TcpServer.tcp_port)
990 pub tcp_port: ::std::option::Option<i32>,
991 // @@protoc_insertion_point(field:rootcanal.configuration.TcpServer.configuration)
992 pub configuration: ::protobuf::MessageField<Controller>,
993 // special fields
994 // @@protoc_insertion_point(special_field:rootcanal.configuration.TcpServer.special_fields)
995 pub special_fields: ::protobuf::SpecialFields,
996 }
997
998 impl<'a> ::std::default::Default for &'a TcpServer {
default() -> &'a TcpServer999 fn default() -> &'a TcpServer {
1000 <TcpServer as ::protobuf::Message>::default_instance()
1001 }
1002 }
1003
1004 impl TcpServer {
new() -> TcpServer1005 pub fn new() -> TcpServer {
1006 ::std::default::Default::default()
1007 }
1008
1009 // required int32 tcp_port = 1;
1010
tcp_port(&self) -> i321011 pub fn tcp_port(&self) -> i32 {
1012 self.tcp_port.unwrap_or(0)
1013 }
1014
clear_tcp_port(&mut self)1015 pub fn clear_tcp_port(&mut self) {
1016 self.tcp_port = ::std::option::Option::None;
1017 }
1018
has_tcp_port(&self) -> bool1019 pub fn has_tcp_port(&self) -> bool {
1020 self.tcp_port.is_some()
1021 }
1022
1023 // Param is passed by value, moved
set_tcp_port(&mut self, v: i32)1024 pub fn set_tcp_port(&mut self, v: i32) {
1025 self.tcp_port = ::std::option::Option::Some(v);
1026 }
1027
generated_message_descriptor_data() -> ::protobuf::reflect::GeneratedMessageDescriptorData1028 fn generated_message_descriptor_data() -> ::protobuf::reflect::GeneratedMessageDescriptorData {
1029 let mut fields = ::std::vec::Vec::with_capacity(2);
1030 let mut oneofs = ::std::vec::Vec::with_capacity(0);
1031 fields.push(::protobuf::reflect::rt::v2::make_option_accessor::<_, _>(
1032 "tcp_port",
1033 |m: &TcpServer| { &m.tcp_port },
1034 |m: &mut TcpServer| { &mut m.tcp_port },
1035 ));
1036 fields.push(::protobuf::reflect::rt::v2::make_message_field_accessor::<_, Controller>(
1037 "configuration",
1038 |m: &TcpServer| { &m.configuration },
1039 |m: &mut TcpServer| { &mut m.configuration },
1040 ));
1041 ::protobuf::reflect::GeneratedMessageDescriptorData::new_2::<TcpServer>(
1042 "TcpServer",
1043 fields,
1044 oneofs,
1045 )
1046 }
1047 }
1048
1049 impl ::protobuf::Message for TcpServer {
1050 const NAME: &'static str = "TcpServer";
1051
is_initialized(&self) -> bool1052 fn is_initialized(&self) -> bool {
1053 if self.tcp_port.is_none() {
1054 return false;
1055 }
1056 for v in &self.configuration {
1057 if !v.is_initialized() {
1058 return false;
1059 }
1060 };
1061 true
1062 }
1063
merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::Result<()>1064 fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::Result<()> {
1065 while let Some(tag) = is.read_raw_tag_or_eof()? {
1066 match tag {
1067 8 => {
1068 self.tcp_port = ::std::option::Option::Some(is.read_int32()?);
1069 },
1070 18 => {
1071 ::protobuf::rt::read_singular_message_into_field(is, &mut self.configuration)?;
1072 },
1073 tag => {
1074 ::protobuf::rt::read_unknown_or_skip_group(tag, is, self.special_fields.mut_unknown_fields())?;
1075 },
1076 };
1077 }
1078 ::std::result::Result::Ok(())
1079 }
1080
1081 // Compute sizes of nested messages
1082 #[allow(unused_variables)]
compute_size(&self) -> u641083 fn compute_size(&self) -> u64 {
1084 let mut my_size = 0;
1085 if let Some(v) = self.tcp_port {
1086 my_size += ::protobuf::rt::int32_size(1, v);
1087 }
1088 if let Some(v) = self.configuration.as_ref() {
1089 let len = v.compute_size();
1090 my_size += 1 + ::protobuf::rt::compute_raw_varint64_size(len) + len;
1091 }
1092 my_size += ::protobuf::rt::unknown_fields_size(self.special_fields.unknown_fields());
1093 self.special_fields.cached_size().set(my_size as u32);
1094 my_size
1095 }
1096
write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::Result<()>1097 fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::Result<()> {
1098 if let Some(v) = self.tcp_port {
1099 os.write_int32(1, v)?;
1100 }
1101 if let Some(v) = self.configuration.as_ref() {
1102 ::protobuf::rt::write_message_field_with_cached_size(2, v, os)?;
1103 }
1104 os.write_unknown_fields(self.special_fields.unknown_fields())?;
1105 ::std::result::Result::Ok(())
1106 }
1107
special_fields(&self) -> &::protobuf::SpecialFields1108 fn special_fields(&self) -> &::protobuf::SpecialFields {
1109 &self.special_fields
1110 }
1111
mut_special_fields(&mut self) -> &mut ::protobuf::SpecialFields1112 fn mut_special_fields(&mut self) -> &mut ::protobuf::SpecialFields {
1113 &mut self.special_fields
1114 }
1115
new() -> TcpServer1116 fn new() -> TcpServer {
1117 TcpServer::new()
1118 }
1119
clear(&mut self)1120 fn clear(&mut self) {
1121 self.tcp_port = ::std::option::Option::None;
1122 self.configuration.clear();
1123 self.special_fields.clear();
1124 }
1125
default_instance() -> &'static TcpServer1126 fn default_instance() -> &'static TcpServer {
1127 static instance: TcpServer = TcpServer {
1128 tcp_port: ::std::option::Option::None,
1129 configuration: ::protobuf::MessageField::none(),
1130 special_fields: ::protobuf::SpecialFields::new(),
1131 };
1132 &instance
1133 }
1134 }
1135
1136 impl ::protobuf::MessageFull for TcpServer {
descriptor() -> ::protobuf::reflect::MessageDescriptor1137 fn descriptor() -> ::protobuf::reflect::MessageDescriptor {
1138 static descriptor: ::protobuf::rt::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::rt::Lazy::new();
1139 descriptor.get(|| file_descriptor().message_by_package_relative_name("TcpServer").unwrap()).clone()
1140 }
1141 }
1142
1143 impl ::std::fmt::Display for TcpServer {
fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result1144 fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
1145 ::protobuf::text_format::fmt(self, f)
1146 }
1147 }
1148
1149 impl ::protobuf::reflect::ProtobufValue for TcpServer {
1150 type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage<Self>;
1151 }
1152
1153 #[derive(PartialEq,Clone,Default,Debug)]
1154 // @@protoc_insertion_point(message:rootcanal.configuration.Configuration)
1155 pub struct Configuration {
1156 // message fields
1157 // @@protoc_insertion_point(field:rootcanal.configuration.Configuration.tcp_server)
1158 pub tcp_server: ::std::vec::Vec<TcpServer>,
1159 // special fields
1160 // @@protoc_insertion_point(special_field:rootcanal.configuration.Configuration.special_fields)
1161 pub special_fields: ::protobuf::SpecialFields,
1162 }
1163
1164 impl<'a> ::std::default::Default for &'a Configuration {
default() -> &'a Configuration1165 fn default() -> &'a Configuration {
1166 <Configuration as ::protobuf::Message>::default_instance()
1167 }
1168 }
1169
1170 impl Configuration {
new() -> Configuration1171 pub fn new() -> Configuration {
1172 ::std::default::Default::default()
1173 }
1174
generated_message_descriptor_data() -> ::protobuf::reflect::GeneratedMessageDescriptorData1175 fn generated_message_descriptor_data() -> ::protobuf::reflect::GeneratedMessageDescriptorData {
1176 let mut fields = ::std::vec::Vec::with_capacity(1);
1177 let mut oneofs = ::std::vec::Vec::with_capacity(0);
1178 fields.push(::protobuf::reflect::rt::v2::make_vec_simpler_accessor::<_, _>(
1179 "tcp_server",
1180 |m: &Configuration| { &m.tcp_server },
1181 |m: &mut Configuration| { &mut m.tcp_server },
1182 ));
1183 ::protobuf::reflect::GeneratedMessageDescriptorData::new_2::<Configuration>(
1184 "Configuration",
1185 fields,
1186 oneofs,
1187 )
1188 }
1189 }
1190
1191 impl ::protobuf::Message for Configuration {
1192 const NAME: &'static str = "Configuration";
1193
is_initialized(&self) -> bool1194 fn is_initialized(&self) -> bool {
1195 for v in &self.tcp_server {
1196 if !v.is_initialized() {
1197 return false;
1198 }
1199 };
1200 true
1201 }
1202
merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::Result<()>1203 fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::Result<()> {
1204 while let Some(tag) = is.read_raw_tag_or_eof()? {
1205 match tag {
1206 10 => {
1207 self.tcp_server.push(is.read_message()?);
1208 },
1209 tag => {
1210 ::protobuf::rt::read_unknown_or_skip_group(tag, is, self.special_fields.mut_unknown_fields())?;
1211 },
1212 };
1213 }
1214 ::std::result::Result::Ok(())
1215 }
1216
1217 // Compute sizes of nested messages
1218 #[allow(unused_variables)]
compute_size(&self) -> u641219 fn compute_size(&self) -> u64 {
1220 let mut my_size = 0;
1221 for value in &self.tcp_server {
1222 let len = value.compute_size();
1223 my_size += 1 + ::protobuf::rt::compute_raw_varint64_size(len) + len;
1224 };
1225 my_size += ::protobuf::rt::unknown_fields_size(self.special_fields.unknown_fields());
1226 self.special_fields.cached_size().set(my_size as u32);
1227 my_size
1228 }
1229
write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::Result<()>1230 fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::Result<()> {
1231 for v in &self.tcp_server {
1232 ::protobuf::rt::write_message_field_with_cached_size(1, v, os)?;
1233 };
1234 os.write_unknown_fields(self.special_fields.unknown_fields())?;
1235 ::std::result::Result::Ok(())
1236 }
1237
special_fields(&self) -> &::protobuf::SpecialFields1238 fn special_fields(&self) -> &::protobuf::SpecialFields {
1239 &self.special_fields
1240 }
1241
mut_special_fields(&mut self) -> &mut ::protobuf::SpecialFields1242 fn mut_special_fields(&mut self) -> &mut ::protobuf::SpecialFields {
1243 &mut self.special_fields
1244 }
1245
new() -> Configuration1246 fn new() -> Configuration {
1247 Configuration::new()
1248 }
1249
clear(&mut self)1250 fn clear(&mut self) {
1251 self.tcp_server.clear();
1252 self.special_fields.clear();
1253 }
1254
default_instance() -> &'static Configuration1255 fn default_instance() -> &'static Configuration {
1256 static instance: Configuration = Configuration {
1257 tcp_server: ::std::vec::Vec::new(),
1258 special_fields: ::protobuf::SpecialFields::new(),
1259 };
1260 &instance
1261 }
1262 }
1263
1264 impl ::protobuf::MessageFull for Configuration {
descriptor() -> ::protobuf::reflect::MessageDescriptor1265 fn descriptor() -> ::protobuf::reflect::MessageDescriptor {
1266 static descriptor: ::protobuf::rt::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::rt::Lazy::new();
1267 descriptor.get(|| file_descriptor().message_by_package_relative_name("Configuration").unwrap()).clone()
1268 }
1269 }
1270
1271 impl ::std::fmt::Display for Configuration {
fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result1272 fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
1273 ::protobuf::text_format::fmt(self, f)
1274 }
1275 }
1276
1277 impl ::protobuf::reflect::ProtobufValue for Configuration {
1278 type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage<Self>;
1279 }
1280
1281 #[derive(Clone,Copy,PartialEq,Eq,Debug,Hash)]
1282 // @@protoc_insertion_point(enum:rootcanal.configuration.ControllerPreset)
1283 pub enum ControllerPreset {
1284 // @@protoc_insertion_point(enum_value:rootcanal.configuration.ControllerPreset.DEFAULT)
1285 DEFAULT = 0,
1286 // @@protoc_insertion_point(enum_value:rootcanal.configuration.ControllerPreset.LAIRD_BL654)
1287 LAIRD_BL654 = 1,
1288 // @@protoc_insertion_point(enum_value:rootcanal.configuration.ControllerPreset.CSR_RCK_PTS_DONGLE)
1289 CSR_RCK_PTS_DONGLE = 2,
1290 }
1291
1292 impl ::protobuf::Enum for ControllerPreset {
1293 const NAME: &'static str = "ControllerPreset";
1294
value(&self) -> i321295 fn value(&self) -> i32 {
1296 *self as i32
1297 }
1298
from_i32(value: i32) -> ::std::option::Option<ControllerPreset>1299 fn from_i32(value: i32) -> ::std::option::Option<ControllerPreset> {
1300 match value {
1301 0 => ::std::option::Option::Some(ControllerPreset::DEFAULT),
1302 1 => ::std::option::Option::Some(ControllerPreset::LAIRD_BL654),
1303 2 => ::std::option::Option::Some(ControllerPreset::CSR_RCK_PTS_DONGLE),
1304 _ => ::std::option::Option::None
1305 }
1306 }
1307
1308 const VALUES: &'static [ControllerPreset] = &[
1309 ControllerPreset::DEFAULT,
1310 ControllerPreset::LAIRD_BL654,
1311 ControllerPreset::CSR_RCK_PTS_DONGLE,
1312 ];
1313 }
1314
1315 impl ::protobuf::EnumFull for ControllerPreset {
enum_descriptor() -> ::protobuf::reflect::EnumDescriptor1316 fn enum_descriptor() -> ::protobuf::reflect::EnumDescriptor {
1317 static descriptor: ::protobuf::rt::Lazy<::protobuf::reflect::EnumDescriptor> = ::protobuf::rt::Lazy::new();
1318 descriptor.get(|| file_descriptor().enum_by_package_relative_name("ControllerPreset").unwrap()).clone()
1319 }
1320
descriptor(&self) -> ::protobuf::reflect::EnumValueDescriptor1321 fn descriptor(&self) -> ::protobuf::reflect::EnumValueDescriptor {
1322 let index = *self as usize;
1323 Self::enum_descriptor().value_by_index(index)
1324 }
1325 }
1326
1327 impl ::std::default::Default for ControllerPreset {
default() -> Self1328 fn default() -> Self {
1329 ControllerPreset::DEFAULT
1330 }
1331 }
1332
1333 impl ControllerPreset {
generated_enum_descriptor_data() -> ::protobuf::reflect::GeneratedEnumDescriptorData1334 fn generated_enum_descriptor_data() -> ::protobuf::reflect::GeneratedEnumDescriptorData {
1335 ::protobuf::reflect::GeneratedEnumDescriptorData::new::<ControllerPreset>("ControllerPreset")
1336 }
1337 }
1338
1339 static file_descriptor_proto_data: &'static [u8] = b"\
1340 \n\x1drootcanal/configuration.proto\x12\x17rootcanal.configuration\"\xa8\
1341 \x02\n\x12ControllerFeatures\x126\n\x17le_extended_advertising\x18\x01\
1342 \x20\x01(\x08R\x15leExtendedAdvertising\x126\n\x17le_periodic_advertisin\
1343 g\x18\x02\x20\x01(\x08R\x15lePeriodicAdvertising\x12\x1d\n\nll_privacy\
1344 \x18\x03\x20\x01(\x08R\tllPrivacy\x12\x1a\n\tle_2m_phy\x18\x04\x20\x01(\
1345 \x08R\x07le2mPhy\x12\x20\n\x0cle_coded_phy\x18\x05\x20\x01(\x08R\nleCode\
1346 dPhy\x12E\n\x1fle_connected_isochronous_stream\x18\x06\x20\x01(\x08R\x1c\
1347 leConnectedIsochronousStream\"\xe5\x01\n\x10ControllerQuirks\x12U\n(send\
1348 _acl_data_before_connection_complete\x18\x01\x20\x01(\x08R#sendAclDataBe\
1349 foreConnectionComplete\x12;\n\x1ahas_default_random_address\x18\x02\x20\
1350 \x01(\x08R\x17hasDefaultRandomAddress\x12=\n\x1bhardware_error_before_re\
1351 set\x18\x03\x20\x01(\x08R\x18hardwareErrorBeforeReset\"<\n\x0eVendorFeat\
1352 ures\x12\x10\n\x03csr\x18\x01\x20\x01(\x08R\x03csr\x12\x18\n\x07android\
1353 \x18\x02\x20\x01(\x08R\x07android\"\xb4\x02\n\nController\x12A\n\x06pres\
1354 et\x18\x01\x20\x01(\x0e2).rootcanal.configuration.ControllerPresetR\x06p\
1355 reset\x12G\n\x08features\x18\x02\x20\x01(\x0b2+.rootcanal.configuration.\
1356 ControllerFeaturesR\x08features\x12A\n\x06quirks\x18\x03\x20\x01(\x0b2).\
1357 rootcanal.configuration.ControllerQuirksR\x06quirks\x12\x16\n\x06strict\
1358 \x18\x04\x20\x01(\x08R\x06strict\x12?\n\x06vendor\x18\x05\x20\x01(\x0b2'\
1359 .rootcanal.configuration.VendorFeaturesR\x06vendor\"q\n\tTcpServer\x12\
1360 \x19\n\x08tcp_port\x18\x01\x20\x02(\x05R\x07tcpPort\x12I\n\rconfiguratio\
1361 n\x18\x02\x20\x01(\x0b2#.rootcanal.configuration.ControllerR\rconfigurat\
1362 ion\"R\n\rConfiguration\x12A\n\ntcp_server\x18\x01\x20\x03(\x0b2\".rootc\
1363 anal.configuration.TcpServerR\ttcpServer*H\n\x10ControllerPreset\x12\x0b\
1364 \n\x07DEFAULT\x10\0\x12\x0f\n\x0bLAIRD_BL654\x10\x01\x12\x16\n\x12CSR_RC\
1365 K_PTS_DONGLE\x10\x02B\x02H\x02\
1366 ";
1367
1368 /// `FileDescriptorProto` object which was a source for this generated file
file_descriptor_proto() -> &'static ::protobuf::descriptor::FileDescriptorProto1369 fn file_descriptor_proto() -> &'static ::protobuf::descriptor::FileDescriptorProto {
1370 static file_descriptor_proto_lazy: ::protobuf::rt::Lazy<::protobuf::descriptor::FileDescriptorProto> = ::protobuf::rt::Lazy::new();
1371 file_descriptor_proto_lazy.get(|| {
1372 ::protobuf::Message::parse_from_bytes(file_descriptor_proto_data).unwrap()
1373 })
1374 }
1375
1376 /// `FileDescriptor` object which allows dynamic access to files
file_descriptor() -> &'static ::protobuf::reflect::FileDescriptor1377 pub fn file_descriptor() -> &'static ::protobuf::reflect::FileDescriptor {
1378 static generated_file_descriptor_lazy: ::protobuf::rt::Lazy<::protobuf::reflect::GeneratedFileDescriptor> = ::protobuf::rt::Lazy::new();
1379 static file_descriptor: ::protobuf::rt::Lazy<::protobuf::reflect::FileDescriptor> = ::protobuf::rt::Lazy::new();
1380 file_descriptor.get(|| {
1381 let generated_file_descriptor = generated_file_descriptor_lazy.get(|| {
1382 let mut deps = ::std::vec::Vec::with_capacity(0);
1383 let mut messages = ::std::vec::Vec::with_capacity(6);
1384 messages.push(ControllerFeatures::generated_message_descriptor_data());
1385 messages.push(ControllerQuirks::generated_message_descriptor_data());
1386 messages.push(VendorFeatures::generated_message_descriptor_data());
1387 messages.push(Controller::generated_message_descriptor_data());
1388 messages.push(TcpServer::generated_message_descriptor_data());
1389 messages.push(Configuration::generated_message_descriptor_data());
1390 let mut enums = ::std::vec::Vec::with_capacity(1);
1391 enums.push(ControllerPreset::generated_enum_descriptor_data());
1392 ::protobuf::reflect::GeneratedFileDescriptor::new_generated(
1393 file_descriptor_proto(),
1394 deps,
1395 messages,
1396 enums,
1397 )
1398 });
1399 ::protobuf::reflect::FileDescriptor::new_generated_2(generated_file_descriptor)
1400 })
1401 }
1402