event_map.rs 4.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136
  1. // This file is generated by rust-protobuf 2.25.2. Do not edit
  2. // @generated
  3. // https://github.com/rust-lang/rust-clippy/issues/702
  4. #![allow(unknown_lints)]
  5. #![allow(clippy::all)]
  6. #![allow(unused_attributes)]
  7. #![cfg_attr(rustfmt, rustfmt::skip)]
  8. #![allow(box_pointers)]
  9. #![allow(dead_code)]
  10. #![allow(missing_docs)]
  11. #![allow(non_camel_case_types)]
  12. #![allow(non_snake_case)]
  13. #![allow(non_upper_case_globals)]
  14. #![allow(trivial_casts)]
  15. #![allow(unused_imports)]
  16. #![allow(unused_results)]
  17. //! Generated file from `event_map.proto`
  18. /// Generated files are compatible only with the same version
  19. /// of protobuf runtime.
  20. // const _PROTOBUF_VERSION_CHECK: () = ::protobuf::VERSION_2_25_2;
  21. #[derive(Clone,PartialEq,Eq,Debug,Hash)]
  22. pub enum GridEvent {
  23. GetGridData = 0,
  24. GetGridBlocks = 1,
  25. GetFields = 10,
  26. UpdateField = 11,
  27. CreateField = 12,
  28. DeleteField = 13,
  29. SwitchToField = 14,
  30. DuplicateField = 15,
  31. GetEditFieldContext = 16,
  32. CreateSelectOption = 30,
  33. GetSelectOptions = 31,
  34. CreateRow = 50,
  35. GetRow = 51,
  36. UpdateCell = 70,
  37. InsertSelectOption = 71,
  38. }
  39. impl ::protobuf::ProtobufEnum for GridEvent {
  40. fn value(&self) -> i32 {
  41. *self as i32
  42. }
  43. fn from_i32(value: i32) -> ::std::option::Option<GridEvent> {
  44. match value {
  45. 0 => ::std::option::Option::Some(GridEvent::GetGridData),
  46. 1 => ::std::option::Option::Some(GridEvent::GetGridBlocks),
  47. 10 => ::std::option::Option::Some(GridEvent::GetFields),
  48. 11 => ::std::option::Option::Some(GridEvent::UpdateField),
  49. 12 => ::std::option::Option::Some(GridEvent::CreateField),
  50. 13 => ::std::option::Option::Some(GridEvent::DeleteField),
  51. 14 => ::std::option::Option::Some(GridEvent::SwitchToField),
  52. 15 => ::std::option::Option::Some(GridEvent::DuplicateField),
  53. 16 => ::std::option::Option::Some(GridEvent::GetEditFieldContext),
  54. 30 => ::std::option::Option::Some(GridEvent::CreateSelectOption),
  55. 31 => ::std::option::Option::Some(GridEvent::GetSelectOptions),
  56. 50 => ::std::option::Option::Some(GridEvent::CreateRow),
  57. 51 => ::std::option::Option::Some(GridEvent::GetRow),
  58. 70 => ::std::option::Option::Some(GridEvent::UpdateCell),
  59. 71 => ::std::option::Option::Some(GridEvent::InsertSelectOption),
  60. _ => ::std::option::Option::None
  61. }
  62. }
  63. fn values() -> &'static [Self] {
  64. static values: &'static [GridEvent] = &[
  65. GridEvent::GetGridData,
  66. GridEvent::GetGridBlocks,
  67. GridEvent::GetFields,
  68. GridEvent::UpdateField,
  69. GridEvent::CreateField,
  70. GridEvent::DeleteField,
  71. GridEvent::SwitchToField,
  72. GridEvent::DuplicateField,
  73. GridEvent::GetEditFieldContext,
  74. GridEvent::CreateSelectOption,
  75. GridEvent::GetSelectOptions,
  76. GridEvent::CreateRow,
  77. GridEvent::GetRow,
  78. GridEvent::UpdateCell,
  79. GridEvent::InsertSelectOption,
  80. ];
  81. values
  82. }
  83. fn enum_descriptor_static() -> &'static ::protobuf::reflect::EnumDescriptor {
  84. static descriptor: ::protobuf::rt::LazyV2<::protobuf::reflect::EnumDescriptor> = ::protobuf::rt::LazyV2::INIT;
  85. descriptor.get(|| {
  86. ::protobuf::reflect::EnumDescriptor::new_pb_name::<GridEvent>("GridEvent", file_descriptor_proto())
  87. })
  88. }
  89. }
  90. impl ::std::marker::Copy for GridEvent {
  91. }
  92. impl ::std::default::Default for GridEvent {
  93. fn default() -> Self {
  94. GridEvent::GetGridData
  95. }
  96. }
  97. impl ::protobuf::reflect::ProtobufValue for GridEvent {
  98. fn as_ref(&self) -> ::protobuf::reflect::ReflectValueRef {
  99. ::protobuf::reflect::ReflectValueRef::Enum(::protobuf::ProtobufEnum::descriptor(self))
  100. }
  101. }
  102. static file_descriptor_proto_data: &'static [u8] = b"\
  103. \n\x0fevent_map.proto*\xa2\x02\n\tGridEvent\x12\x0f\n\x0bGetGridData\x10\
  104. \0\x12\x11\n\rGetGridBlocks\x10\x01\x12\r\n\tGetFields\x10\n\x12\x0f\n\
  105. \x0bUpdateField\x10\x0b\x12\x0f\n\x0bCreateField\x10\x0c\x12\x0f\n\x0bDe\
  106. leteField\x10\r\x12\x11\n\rSwitchToField\x10\x0e\x12\x12\n\x0eDuplicateF\
  107. ield\x10\x0f\x12\x17\n\x13GetEditFieldContext\x10\x10\x12\x16\n\x12Creat\
  108. eSelectOption\x10\x1e\x12\x14\n\x10GetSelectOptions\x10\x1f\x12\r\n\tCre\
  109. ateRow\x102\x12\n\n\x06GetRow\x103\x12\x0e\n\nUpdateCell\x10F\x12\x16\n\
  110. \x12InsertSelectOption\x10Gb\x06proto3\
  111. ";
  112. static file_descriptor_proto_lazy: ::protobuf::rt::LazyV2<::protobuf::descriptor::FileDescriptorProto> = ::protobuf::rt::LazyV2::INIT;
  113. fn parse_descriptor_proto() -> ::protobuf::descriptor::FileDescriptorProto {
  114. ::protobuf::Message::parse_from_bytes(file_descriptor_proto_data).unwrap()
  115. }
  116. pub fn file_descriptor_proto() -> &'static ::protobuf::descriptor::FileDescriptorProto {
  117. file_descriptor_proto_lazy.get(|| {
  118. parse_descriptor_proto()
  119. })
  120. }