#![allow(unknown_lints)]
#![allow(clippy::all)]
#![allow(unused_attributes)]
#![cfg_attr(rustfmt, rustfmt::skip)]
#![allow(box_pointers)]
#![allow(dead_code)]
#![allow(missing_docs)]
#![allow(non_camel_case_types)]
#![allow(non_snake_case)]
#![allow(non_upper_case_globals)]
#![allow(trivial_casts)]
#![allow(unused_results)]
#![allow(unused_mut)]
const _PROTOBUF_VERSION_CHECK: () = ::protobuf::VERSION_3_2_0;
#[derive(PartialEq,Clone,Default,Debug)]
pub struct Log {
pub timestamp: ::protobuf::MessageField<::protobuf::well_known_types::timestamp::Timestamp>,
pub level: ::protobuf::EnumOrUnknown<log::Level>,
pub message: ::std::string::String,
pub name: ::std::string::String,
pub file: ::std::string::String,
pub line: u32,
pub special_fields: ::protobuf::SpecialFields,
}
impl<'a> ::std::default::Default for &'a Log {
fn default() -> &'a Log {
<Log as ::protobuf::Message>::default_instance()
}
}
impl Log {
pub fn new() -> Log {
::std::default::Default::default()
}
fn generated_message_descriptor_data() -> ::protobuf::reflect::GeneratedMessageDescriptorData {
let mut fields = ::std::vec::Vec::with_capacity(6);
let mut oneofs = ::std::vec::Vec::with_capacity(0);
fields.push(::protobuf::reflect::rt::v2::make_message_field_accessor::<_, ::protobuf::well_known_types::timestamp::Timestamp>(
"timestamp",
|m: &Log| { &m.timestamp },
|m: &mut Log| { &mut m.timestamp },
));
fields.push(::protobuf::reflect::rt::v2::make_simpler_field_accessor::<_, _>(
"level",
|m: &Log| { &m.level },
|m: &mut Log| { &mut m.level },
));
fields.push(::protobuf::reflect::rt::v2::make_simpler_field_accessor::<_, _>(
"message",
|m: &Log| { &m.message },
|m: &mut Log| { &mut m.message },
));
fields.push(::protobuf::reflect::rt::v2::make_simpler_field_accessor::<_, _>(
"name",
|m: &Log| { &m.name },
|m: &mut Log| { &mut m.name },
));
fields.push(::protobuf::reflect::rt::v2::make_simpler_field_accessor::<_, _>(
"file",
|m: &Log| { &m.file },
|m: &mut Log| { &mut m.file },
));
fields.push(::protobuf::reflect::rt::v2::make_simpler_field_accessor::<_, _>(
"line",
|m: &Log| { &m.line },
|m: &mut Log| { &mut m.line },
));
::protobuf::reflect::GeneratedMessageDescriptorData::new_2::<Log>(
"Log",
fields,
oneofs,
)
}
}
impl ::protobuf::Message for Log {
const NAME: &'static str = "Log";
fn is_initialized(&self) -> bool {
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::Result<()> {
while let Some(tag) = is.read_raw_tag_or_eof()? {
match tag {
10 => {
::protobuf::rt::read_singular_message_into_field(is, &mut self.timestamp)?;
},
16 => {
self.level = is.read_enum_or_unknown()?;
},
26 => {
self.message = is.read_string()?;
},
34 => {
self.name = is.read_string()?;
},
42 => {
self.file = is.read_string()?;
},
53 => {
self.line = is.read_fixed32()?;
},
tag => {
::protobuf::rt::read_unknown_or_skip_group(tag, is, self.special_fields.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u64 {
let mut my_size = 0;
if let Some(v) = self.timestamp.as_ref() {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint64_size(len) + len;
}
if self.level != ::protobuf::EnumOrUnknown::new(log::Level::UNKNOWN) {
my_size += ::protobuf::rt::int32_size(2, self.level.value());
}
if !self.message.is_empty() {
my_size += ::protobuf::rt::string_size(3, &self.message);
}
if !self.name.is_empty() {
my_size += ::protobuf::rt::string_size(4, &self.name);
}
if !self.file.is_empty() {
my_size += ::protobuf::rt::string_size(5, &self.file);
}
if self.line != 0 {
my_size += 1 + 4;
}
my_size += ::protobuf::rt::unknown_fields_size(self.special_fields.unknown_fields());
self.special_fields.cached_size().set(my_size as u32);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::Result<()> {
if let Some(v) = self.timestamp.as_ref() {
::protobuf::rt::write_message_field_with_cached_size(1, v, os)?;
}
if self.level != ::protobuf::EnumOrUnknown::new(log::Level::UNKNOWN) {
os.write_enum(2, ::protobuf::EnumOrUnknown::value(&self.level))?;
}
if !self.message.is_empty() {
os.write_string(3, &self.message)?;
}
if !self.name.is_empty() {
os.write_string(4, &self.name)?;
}
if !self.file.is_empty() {
os.write_string(5, &self.file)?;
}
if self.line != 0 {
os.write_fixed32(6, self.line)?;
}
os.write_unknown_fields(self.special_fields.unknown_fields())?;
::std::result::Result::Ok(())
}
fn special_fields(&self) -> &::protobuf::SpecialFields {
&self.special_fields
}
fn mut_special_fields(&mut self) -> &mut ::protobuf::SpecialFields {
&mut self.special_fields
}
fn new() -> Log {
Log::new()
}
fn clear(&mut self) {
self.timestamp.clear();
self.level = ::protobuf::EnumOrUnknown::new(log::Level::UNKNOWN);
self.message.clear();
self.name.clear();
self.file.clear();
self.line = 0;
self.special_fields.clear();
}
fn default_instance() -> &'static Log {
static instance: Log = Log {
timestamp: ::protobuf::MessageField::none(),
level: ::protobuf::EnumOrUnknown::from_i32(0),
message: ::std::string::String::new(),
name: ::std::string::String::new(),
file: ::std::string::String::new(),
line: 0,
special_fields: ::protobuf::SpecialFields::new(),
};
&instance
}
}
impl ::protobuf::MessageFull for Log {
fn descriptor() -> ::protobuf::reflect::MessageDescriptor {
static descriptor: ::protobuf::rt::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::rt::Lazy::new();
descriptor.get(|| file_descriptor().message_by_package_relative_name("Log").unwrap()).clone()
}
}
impl ::std::fmt::Display for Log {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for Log {
type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage<Self>;
}
pub mod log {
#[derive(Clone,Copy,PartialEq,Eq,Debug,Hash)]
pub enum Level {
UNKNOWN = 0,
DEBUG = 1,
INFO = 2,
WARNING = 3,
ERROR = 4,
FATAL = 5,
}
impl ::protobuf::Enum for Level {
const NAME: &'static str = "Level";
fn value(&self) -> i32 {
*self as i32
}
fn from_i32(value: i32) -> ::std::option::Option<Level> {
match value {
0 => ::std::option::Option::Some(Level::UNKNOWN),
1 => ::std::option::Option::Some(Level::DEBUG),
2 => ::std::option::Option::Some(Level::INFO),
3 => ::std::option::Option::Some(Level::WARNING),
4 => ::std::option::Option::Some(Level::ERROR),
5 => ::std::option::Option::Some(Level::FATAL),
_ => ::std::option::Option::None
}
}
const VALUES: &'static [Level] = &[
Level::UNKNOWN,
Level::DEBUG,
Level::INFO,
Level::WARNING,
Level::ERROR,
Level::FATAL,
];
}
impl ::protobuf::EnumFull for Level {
fn enum_descriptor() -> ::protobuf::reflect::EnumDescriptor {
static descriptor: ::protobuf::rt::Lazy<::protobuf::reflect::EnumDescriptor> = ::protobuf::rt::Lazy::new();
descriptor.get(|| super::file_descriptor().enum_by_package_relative_name("Log.Level").unwrap()).clone()
}
fn descriptor(&self) -> ::protobuf::reflect::EnumValueDescriptor {
let index = *self as usize;
Self::enum_descriptor().value_by_index(index)
}
}
impl ::std::default::Default for Level {
fn default() -> Self {
Level::UNKNOWN
}
}
impl Level {
pub(in super) fn generated_enum_descriptor_data() -> ::protobuf::reflect::GeneratedEnumDescriptorData {
::protobuf::reflect::GeneratedEnumDescriptorData::new::<Level>("Log.Level")
}
}
}
static file_descriptor_proto_data: &'static [u8] = b"\
\n\x12foxglove/Log.proto\x12\x08foxglove\x1a\x1fgoogle/protobuf/timestam\
p.proto\"\x8e\x02\n\x03Log\x128\n\ttimestamp\x18\x01\x20\x01(\x0b2\x1a.g\
oogle.protobuf.TimestampR\ttimestamp\x12)\n\x05level\x18\x02\x20\x01(\
\x0e2\x13.foxglove.Log.LevelR\x05level\x12\x18\n\x07message\x18\x03\x20\
\x01(\tR\x07message\x12\x12\n\x04name\x18\x04\x20\x01(\tR\x04name\x12\
\x12\n\x04file\x18\x05\x20\x01(\tR\x04file\x12\x12\n\x04line\x18\x06\x20\
\x01(\x07R\x04line\"L\n\x05Level\x12\x0b\n\x07UNKNOWN\x10\0\x12\t\n\x05D\
EBUG\x10\x01\x12\x08\n\x04INFO\x10\x02\x12\x0b\n\x07WARNING\x10\x03\x12\
\t\n\x05ERROR\x10\x04\x12\t\n\x05FATAL\x10\x05b\x06proto3\
";
fn file_descriptor_proto() -> &'static ::protobuf::descriptor::FileDescriptorProto {
static file_descriptor_proto_lazy: ::protobuf::rt::Lazy<::protobuf::descriptor::FileDescriptorProto> = ::protobuf::rt::Lazy::new();
file_descriptor_proto_lazy.get(|| {
::protobuf::Message::parse_from_bytes(file_descriptor_proto_data).unwrap()
})
}
pub fn file_descriptor() -> &'static ::protobuf::reflect::FileDescriptor {
static generated_file_descriptor_lazy: ::protobuf::rt::Lazy<::protobuf::reflect::GeneratedFileDescriptor> = ::protobuf::rt::Lazy::new();
static file_descriptor: ::protobuf::rt::Lazy<::protobuf::reflect::FileDescriptor> = ::protobuf::rt::Lazy::new();
file_descriptor.get(|| {
let generated_file_descriptor = generated_file_descriptor_lazy.get(|| {
let mut deps = ::std::vec::Vec::with_capacity(1);
deps.push(::protobuf::well_known_types::timestamp::file_descriptor().clone());
let mut messages = ::std::vec::Vec::with_capacity(1);
messages.push(Log::generated_message_descriptor_data());
let mut enums = ::std::vec::Vec::with_capacity(1);
enums.push(log::Level::generated_enum_descriptor_data());
::protobuf::reflect::GeneratedFileDescriptor::new_generated(
file_descriptor_proto(),
deps,
messages,
enums,
)
});
::protobuf::reflect::FileDescriptor::new_generated_2(generated_file_descriptor)
})
}