Skip to content

Commit

Permalink
Update proto
Browse files Browse the repository at this point in the history
  • Loading branch information
kurotych committed Nov 19, 2024
1 parent 28743dd commit 6cc2aa9
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 12 deletions.
4 changes: 2 additions & 2 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

21 changes: 11 additions & 10 deletions mobile_config/src/gateway_info.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,10 @@ use futures::stream::BoxStream;
use helium_crypto::PublicKeyBinary;
use helium_proto::services::mobile_config::{
gateway_metadata::DeploymentInfo as DeploymentInfoProto,
CbrsDeploymentInfo as CbrsDeploymentInfoProto, DeviceType as DeviceTypeProto,
CbrsDeploymentInfo as CbrsDeploymentInfoProto,
CbrsRadioDeploymentInfo as CbrsRadioDeploymentInfoProto, DeviceType as DeviceTypeProto,
GatewayInfo as GatewayInfoProto, GatewayMetadata as GatewayMetadataProto,
RadioDeploymentInfo as RadioDeploymentInfoProto, WifiDeploymentInfo as WifiDeploymentInfoProto,
WifiDeploymentInfo as WifiDeploymentInfoProto,
};
use serde::Deserialize;

Expand Down Expand Up @@ -37,23 +38,23 @@ impl From<WifiDeploymentInfoProto> for WifiDeploymentInfo {

#[derive(Clone, Debug, Deserialize)]
pub struct CbrsDeploymentInfo {
pub radio_deployment_info: Vec<RadioDeploymentInfo>,
pub cbrs_radios_deployment_info: Vec<RadioDeploymentInfo>,
}

impl From<CbrsDeploymentInfoProto> for CbrsDeploymentInfo {
fn from(v: CbrsDeploymentInfoProto) -> Self {
Self {
radio_deployment_info: v
.radio_deployment_info
cbrs_radios_deployment_info: v
.cbrs_radios_deployment_info
.into_iter()
.map(|v| v.into())
.collect(),
}
}
}

impl From<RadioDeploymentInfoProto> for RadioDeploymentInfo {
fn from(v: RadioDeploymentInfoProto) -> Self {
impl From<CbrsRadioDeploymentInfoProto> for RadioDeploymentInfo {
fn from(v: CbrsRadioDeploymentInfoProto) -> Self {
Self {
radio_id: v.radio_id,
elevation: v.elevation,
Expand Down Expand Up @@ -177,7 +178,7 @@ impl From<WifiDeploymentInfo> for WifiDeploymentInfoProto {
}
}

impl From<RadioDeploymentInfo> for RadioDeploymentInfoProto {
impl From<RadioDeploymentInfo> for CbrsRadioDeploymentInfoProto {
fn from(v: RadioDeploymentInfo) -> Self {
Self {
radio_id: v.radio_id,
Expand All @@ -189,8 +190,8 @@ impl From<RadioDeploymentInfo> for RadioDeploymentInfoProto {
impl From<CbrsDeploymentInfo> for CbrsDeploymentInfoProto {
fn from(v: CbrsDeploymentInfo) -> Self {
Self {
radio_deployment_info: v
.radio_deployment_info
cbrs_radios_deployment_info: v
.cbrs_radios_deployment_info
.into_iter()
.map(|v| v.into())
.collect(),
Expand Down

0 comments on commit 6cc2aa9

Please sign in to comment.