mirror of
https://github.com/chirpstack/chirpstack.git
synced 2025-05-03 17:43:11 +00:00
36 lines
1.0 KiB
Rust
Vendored
36 lines
1.0 KiB
Rust
Vendored
tonic::include_proto!("integration/integration");
|
|
include!(concat!(
|
|
env!("OUT_DIR"),
|
|
"/integration/integration.serde.rs"
|
|
));
|
|
|
|
#[allow(clippy::from_over_into)]
|
|
impl Into<String> for LogLevel {
|
|
fn into(self) -> String {
|
|
match self {
|
|
LogLevel::Info => "INFO",
|
|
LogLevel::Warning => "WARNING",
|
|
LogLevel::Error => "ERROR",
|
|
}
|
|
.to_string()
|
|
}
|
|
}
|
|
|
|
#[allow(clippy::from_over_into)]
|
|
impl Into<String> for LogCode {
|
|
fn into(self) -> String {
|
|
match self {
|
|
LogCode::Unknown => "UNKNOWN",
|
|
LogCode::DownlinkPayloadSize => "DOWNLINK_PAYLOAD_SIZE",
|
|
LogCode::UplinkCodec => "UPLINK_CODEC",
|
|
LogCode::DownlinkCodec => "DOWNLINK_CODEC",
|
|
LogCode::Otaa => "OTAA",
|
|
LogCode::UplinkFCntReset => "UPLINK_F_CNT_RESET",
|
|
LogCode::UplinkMic => "UPLINK_MIC",
|
|
LogCode::UplinkFCntRetransmission => "UPLINK_F_CNT_RETRANSMISSION",
|
|
LogCode::DownlinkGateway => "DOWNLINK_GATEWAY",
|
|
}
|
|
.to_string()
|
|
}
|
|
}
|