// This file is @generated by prost-build.
#[derive(Clone, Copy, PartialEq, ::prost::Message)]
pub struct GetStateRequest {}
#[derive(Clone, Copy, PartialEq, ::prost::Message)]
pub struct WatchStateRequest {}
#[derive(Clone, Copy, PartialEq, ::prost::Message)]
pub struct SetEnabledRequest {
    #[prost(bool, tag = "1")]
    pub enabled: bool,
}
#[derive(Clone, Copy, PartialEq, ::prost::Message)]
pub struct AdjustBandRequest {
    /// Band index 0..9 (0 = 32 Hz low shelf … 9 = 16 kHz high shelf).
    #[prost(uint32, tag = "1")]
    pub band: u32,
    #[prost(int32, tag = "2")]
    pub delta_tenths_db: i32,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct SetBandGainsRequest {
    /// Exactly 10 values, tenths of dB, clamped to ±240.
    #[prost(int32, repeated, tag = "1")]
    pub gains_tenths_db: ::prost::alloc::vec::Vec<i32>,
}
#[derive(Clone, Copy, PartialEq, ::prost::Message)]
pub struct AdjustToneRequest {
    #[prost(int32, tag = "1")]
    pub bass_delta_db: i32,
    #[prost(int32, tag = "2")]
    pub treble_delta_db: i32,
}
#[derive(Clone, Copy, PartialEq, ::prost::Message)]
pub struct ResetGainsRequest {}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct ApplyPresetRequest {
    #[prost(string, tag = "1")]
    pub name: ::prost::alloc::string::String,
}
#[derive(Clone, Copy, PartialEq, ::prost::Message)]
pub struct ListPresetsRequest {}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct ListPresetsResponse {
    #[prost(message, repeated, tag = "1")]
    pub presets: ::prost::alloc::vec::Vec<Preset>,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct Preset {
    #[prost(string, tag = "1")]
    pub name: ::prost::alloc::string::String,
    /// 10 gains in whole dB.
    #[prost(int32, repeated, tag = "2")]
    pub gains_db: ::prost::alloc::vec::Vec<i32>,
}
#[derive(Clone, Copy, PartialEq, ::prost::Message)]
pub struct SaveRequest {}
#[derive(Clone, Copy, PartialEq, ::prost::Message)]
pub struct SaveResponse {}
/// One EQ band in Rockbox units.
#[derive(Clone, Copy, PartialEq, ::prost::Message)]
pub struct Band {
    #[prost(int32, tag = "1")]
    pub cutoff_hz: i32,
    /// Q × 10 (7 = Q 0.7).
    #[prost(int32, tag = "2")]
    pub q_tenths: i32,
    /// Gain × 10 in dB.
    #[prost(int32, tag = "3")]
    pub gain_tenths_db: i32,
}
/// Static facts about the server's audio pipeline.
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct StreamInfo {
    #[prost(string, tag = "1")]
    pub input: ::prost::alloc::string::String,
    /// e.g. "s16le 2ch".
    #[prost(string, tag = "2")]
    pub format: ::prost::alloc::string::String,
    #[prost(uint32, tag = "3")]
    pub in_rate: u32,
    #[prost(uint32, tag = "4")]
    pub out_rate: u32,
    #[prost(string, tag = "5")]
    pub device: ::prost::alloc::string::String,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct State {
    #[prost(bool, tag = "1")]
    pub enabled: bool,
    #[prost(message, repeated, tag = "2")]
    pub bands: ::prost::alloc::vec::Vec<Band>,
    #[prost(int32, tag = "3")]
    pub bass_db: i32,
    #[prost(int32, tag = "4")]
    pub treble_db: i32,
    /// Bumped on every change; lets watchers cheaply detect edits.
    #[prost(uint64, tag = "5")]
    pub version: u64,
    #[prost(enumeration = "PlaybackState", tag = "6")]
    pub playback: i32,
    /// Pipeline error message; empty when healthy.
    #[prost(string, tag = "7")]
    pub error: ::prost::alloc::string::String,
    #[prost(uint64, tag = "8")]
    pub frames_played: u64,
    /// Latest post-DSP chunk peak per channel, i16 full-scale units.
    #[prost(int32, tag = "9")]
    pub peak_l: i32,
    #[prost(int32, tag = "10")]
    pub peak_r: i32,
    #[prost(message, optional, tag = "11")]
    pub stream: ::core::option::Option<StreamInfo>,
}
#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
#[repr(i32)]
pub enum PlaybackState {
    Waiting = 0,
    Streaming = 1,
    Ended = 2,
}
impl PlaybackState {
    /// String value of the enum field names used in the ProtoBuf definition.
    ///
    /// The values are not transformed in any way and thus are considered stable
    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
    pub fn as_str_name(&self) -> &'static str {
        match self {
            Self::Waiting => "PLAYBACK_STATE_WAITING",
            Self::Streaming => "PLAYBACK_STATE_STREAMING",
            Self::Ended => "PLAYBACK_STATE_ENDED",
        }
    }
    /// Creates an enum from field names used in the ProtoBuf definition.
    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
        match value {
            "PLAYBACK_STATE_WAITING" => Some(Self::Waiting),
            "PLAYBACK_STATE_STREAMING" => Some(Self::Streaming),
            "PLAYBACK_STATE_ENDED" => Some(Self::Ended),
            _ => None,
        }
    }
}
/// Generated client implementations.
pub mod equalizer_service_client {
    #![allow(
        unused_variables,
        dead_code,
        missing_docs,
        clippy::wildcard_imports,
        clippy::let_unit_value,
    )]
    use tonic::codegen::*;
    use tonic::codegen::http::Uri;
    /// Remote control for a running `equalizer` process: the same 10-band
    /// Rockbox EQ + bass/treble shelves the TUI drives, plus pipeline telemetry
    /// for a remote status line / level meter.
    #[derive(Debug, Clone)]
    pub struct EqualizerServiceClient<T> {
        inner: tonic::client::Grpc<T>,
    }
    impl EqualizerServiceClient<tonic::transport::Channel> {
        /// Attempt to create a new client by connecting to a given endpoint.
        pub async fn connect<D>(dst: D) -> Result<Self, tonic::transport::Error>
        where
            D: TryInto<tonic::transport::Endpoint>,
            D::Error: Into<StdError>,
        {
            let conn = tonic::transport::Endpoint::new(dst)?.connect().await?;
            Ok(Self::new(conn))
        }
    }
    impl<T> EqualizerServiceClient<T>
    where
        T: tonic::client::GrpcService<tonic::body::BoxBody>,
        T::Error: Into<StdError>,
        T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
        <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
    {
        pub fn new(inner: T) -> Self {
            let inner = tonic::client::Grpc::new(inner);
            Self { inner }
        }
        pub fn with_origin(inner: T, origin: Uri) -> Self {
            let inner = tonic::client::Grpc::with_origin(inner, origin);
            Self { inner }
        }
        pub fn with_interceptor<F>(
            inner: T,
            interceptor: F,
        ) -> EqualizerServiceClient<InterceptedService<T, F>>
        where
            F: tonic::service::Interceptor,
            T::ResponseBody: Default,
            T: tonic::codegen::Service<
                http::Request<tonic::body::BoxBody>,
                Response = http::Response<
                    <T as tonic::client::GrpcService<tonic::body::BoxBody>>::ResponseBody,
                >,
            >,
            <T as tonic::codegen::Service<
                http::Request<tonic::body::BoxBody>,
            >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
        {
            EqualizerServiceClient::new(InterceptedService::new(inner, interceptor))
        }
        /// Compress requests with the given encoding.
        ///
        /// This requires the server to support it otherwise it might respond with an
        /// error.
        #[must_use]
        pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
            self.inner = self.inner.send_compressed(encoding);
            self
        }
        /// Enable decompressing responses.
        #[must_use]
        pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
            self.inner = self.inner.accept_compressed(encoding);
            self
        }
        /// Limits the maximum size of a decoded message.
        ///
        /// Default: `4MB`
        #[must_use]
        pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
            self.inner = self.inner.max_decoding_message_size(limit);
            self
        }
        /// Limits the maximum size of an encoded message.
        ///
        /// Default: `usize::MAX`
        #[must_use]
        pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
            self.inner = self.inner.max_encoding_message_size(limit);
            self
        }
        /// One-shot snapshot (also carries the stream info a client needs once).
        pub async fn get_state(
            &mut self,
            request: impl tonic::IntoRequest<super::GetStateRequest>,
        ) -> std::result::Result<tonic::Response<super::State>, tonic::Status> {
            self.inner
                .ready()
                .await
                .map_err(|e| {
                    tonic::Status::unknown(
                        format!("Service was not ready: {}", e.into()),
                    )
                })?;
            let codec = tonic::codec::ProstCodec::default();
            let path = http::uri::PathAndQuery::from_static(
                "/equalizer.v1.EqualizerService/GetState",
            );
            let mut req = request.into_request();
            req.extensions_mut()
                .insert(GrpcMethod::new("equalizer.v1.EqualizerService", "GetState"));
            self.inner.unary(req, path, codec).await
        }
        /// Snapshots streamed at ~10 Hz: EQ state, playback state and level peaks.
        pub async fn watch_state(
            &mut self,
            request: impl tonic::IntoRequest<super::WatchStateRequest>,
        ) -> std::result::Result<
            tonic::Response<tonic::codec::Streaming<super::State>>,
            tonic::Status,
        > {
            self.inner
                .ready()
                .await
                .map_err(|e| {
                    tonic::Status::unknown(
                        format!("Service was not ready: {}", e.into()),
                    )
                })?;
            let codec = tonic::codec::ProstCodec::default();
            let path = http::uri::PathAndQuery::from_static(
                "/equalizer.v1.EqualizerService/WatchState",
            );
            let mut req = request.into_request();
            req.extensions_mut()
                .insert(GrpcMethod::new("equalizer.v1.EqualizerService", "WatchState"));
            self.inner.server_streaming(req, path, codec).await
        }
        pub async fn set_enabled(
            &mut self,
            request: impl tonic::IntoRequest<super::SetEnabledRequest>,
        ) -> std::result::Result<tonic::Response<super::State>, tonic::Status> {
            self.inner
                .ready()
                .await
                .map_err(|e| {
                    tonic::Status::unknown(
                        format!("Service was not ready: {}", e.into()),
                    )
                })?;
            let codec = tonic::codec::ProstCodec::default();
            let path = http::uri::PathAndQuery::from_static(
                "/equalizer.v1.EqualizerService/SetEnabled",
            );
            let mut req = request.into_request();
            req.extensions_mut()
                .insert(GrpcMethod::new("equalizer.v1.EqualizerService", "SetEnabled"));
            self.inner.unary(req, path, codec).await
        }
        /// Relative band gain change in tenths of dB (matches the TUI keys).
        pub async fn adjust_band(
            &mut self,
            request: impl tonic::IntoRequest<super::AdjustBandRequest>,
        ) -> std::result::Result<tonic::Response<super::State>, tonic::Status> {
            self.inner
                .ready()
                .await
                .map_err(|e| {
                    tonic::Status::unknown(
                        format!("Service was not ready: {}", e.into()),
                    )
                })?;
            let codec = tonic::codec::ProstCodec::default();
            let path = http::uri::PathAndQuery::from_static(
                "/equalizer.v1.EqualizerService/AdjustBand",
            );
            let mut req = request.into_request();
            req.extensions_mut()
                .insert(GrpcMethod::new("equalizer.v1.EqualizerService", "AdjustBand"));
            self.inner.unary(req, path, codec).await
        }
        /// Absolute gains for all 10 bands in tenths of dB (cutoffs/Q are kept).
        pub async fn set_band_gains(
            &mut self,
            request: impl tonic::IntoRequest<super::SetBandGainsRequest>,
        ) -> std::result::Result<tonic::Response<super::State>, tonic::Status> {
            self.inner
                .ready()
                .await
                .map_err(|e| {
                    tonic::Status::unknown(
                        format!("Service was not ready: {}", e.into()),
                    )
                })?;
            let codec = tonic::codec::ProstCodec::default();
            let path = http::uri::PathAndQuery::from_static(
                "/equalizer.v1.EqualizerService/SetBandGains",
            );
            let mut req = request.into_request();
            req.extensions_mut()
                .insert(
                    GrpcMethod::new("equalizer.v1.EqualizerService", "SetBandGains"),
                );
            self.inner.unary(req, path, codec).await
        }
        /// Relative bass/treble shelf change in whole dB.
        pub async fn adjust_tone(
            &mut self,
            request: impl tonic::IntoRequest<super::AdjustToneRequest>,
        ) -> std::result::Result<tonic::Response<super::State>, tonic::Status> {
            self.inner
                .ready()
                .await
                .map_err(|e| {
                    tonic::Status::unknown(
                        format!("Service was not ready: {}", e.into()),
                    )
                })?;
            let codec = tonic::codec::ProstCodec::default();
            let path = http::uri::PathAndQuery::from_static(
                "/equalizer.v1.EqualizerService/AdjustTone",
            );
            let mut req = request.into_request();
            req.extensions_mut()
                .insert(GrpcMethod::new("equalizer.v1.EqualizerService", "AdjustTone"));
            self.inner.unary(req, path, codec).await
        }
        /// All band gains and both tone shelves back to 0 dB.
        pub async fn reset_gains(
            &mut self,
            request: impl tonic::IntoRequest<super::ResetGainsRequest>,
        ) -> std::result::Result<tonic::Response<super::State>, tonic::Status> {
            self.inner
                .ready()
                .await
                .map_err(|e| {
                    tonic::Status::unknown(
                        format!("Service was not ready: {}", e.into()),
                    )
                })?;
            let codec = tonic::codec::ProstCodec::default();
            let path = http::uri::PathAndQuery::from_static(
                "/equalizer.v1.EqualizerService/ResetGains",
            );
            let mut req = request.into_request();
            req.extensions_mut()
                .insert(GrpcMethod::new("equalizer.v1.EqualizerService", "ResetGains"));
            self.inner.unary(req, path, codec).await
        }
        /// Apply a built-in preset by name (see ListPresets) and enable the EQ.
        pub async fn apply_preset(
            &mut self,
            request: impl tonic::IntoRequest<super::ApplyPresetRequest>,
        ) -> std::result::Result<tonic::Response<super::State>, tonic::Status> {
            self.inner
                .ready()
                .await
                .map_err(|e| {
                    tonic::Status::unknown(
                        format!("Service was not ready: {}", e.into()),
                    )
                })?;
            let codec = tonic::codec::ProstCodec::default();
            let path = http::uri::PathAndQuery::from_static(
                "/equalizer.v1.EqualizerService/ApplyPreset",
            );
            let mut req = request.into_request();
            req.extensions_mut()
                .insert(GrpcMethod::new("equalizer.v1.EqualizerService", "ApplyPreset"));
            self.inner.unary(req, path, codec).await
        }
        pub async fn list_presets(
            &mut self,
            request: impl tonic::IntoRequest<super::ListPresetsRequest>,
        ) -> std::result::Result<
            tonic::Response<super::ListPresetsResponse>,
            tonic::Status,
        > {
            self.inner
                .ready()
                .await
                .map_err(|e| {
                    tonic::Status::unknown(
                        format!("Service was not ready: {}", e.into()),
                    )
                })?;
            let codec = tonic::codec::ProstCodec::default();
            let path = http::uri::PathAndQuery::from_static(
                "/equalizer.v1.EqualizerService/ListPresets",
            );
            let mut req = request.into_request();
            req.extensions_mut()
                .insert(GrpcMethod::new("equalizer.v1.EqualizerService", "ListPresets"));
            self.inner.unary(req, path, codec).await
        }
        /// Persist the current state to the server's settings file.
        pub async fn save(
            &mut self,
            request: impl tonic::IntoRequest<super::SaveRequest>,
        ) -> std::result::Result<tonic::Response<super::SaveResponse>, tonic::Status> {
            self.inner
                .ready()
                .await
                .map_err(|e| {
                    tonic::Status::unknown(
                        format!("Service was not ready: {}", e.into()),
                    )
                })?;
            let codec = tonic::codec::ProstCodec::default();
            let path = http::uri::PathAndQuery::from_static(
                "/equalizer.v1.EqualizerService/Save",
            );
            let mut req = request.into_request();
            req.extensions_mut()
                .insert(GrpcMethod::new("equalizer.v1.EqualizerService", "Save"));
            self.inner.unary(req, path, codec).await
        }
    }
}
/// Generated server implementations.
pub mod equalizer_service_server {
    #![allow(
        unused_variables,
        dead_code,
        missing_docs,
        clippy::wildcard_imports,
        clippy::let_unit_value,
    )]
    use tonic::codegen::*;
    /// Generated trait containing gRPC methods that should be implemented for use with EqualizerServiceServer.
    #[async_trait]
    pub trait EqualizerService: std::marker::Send + std::marker::Sync + 'static {
        /// One-shot snapshot (also carries the stream info a client needs once).
        async fn get_state(
            &self,
            request: tonic::Request<super::GetStateRequest>,
        ) -> std::result::Result<tonic::Response<super::State>, tonic::Status>;
        /// Server streaming response type for the WatchState method.
        type WatchStateStream: tonic::codegen::tokio_stream::Stream<
                Item = std::result::Result<super::State, tonic::Status>,
            >
            + std::marker::Send
            + 'static;
        /// Snapshots streamed at ~10 Hz: EQ state, playback state and level peaks.
        async fn watch_state(
            &self,
            request: tonic::Request<super::WatchStateRequest>,
        ) -> std::result::Result<tonic::Response<Self::WatchStateStream>, tonic::Status>;
        async fn set_enabled(
            &self,
            request: tonic::Request<super::SetEnabledRequest>,
        ) -> std::result::Result<tonic::Response<super::State>, tonic::Status>;
        /// Relative band gain change in tenths of dB (matches the TUI keys).
        async fn adjust_band(
            &self,
            request: tonic::Request<super::AdjustBandRequest>,
        ) -> std::result::Result<tonic::Response<super::State>, tonic::Status>;
        /// Absolute gains for all 10 bands in tenths of dB (cutoffs/Q are kept).
        async fn set_band_gains(
            &self,
            request: tonic::Request<super::SetBandGainsRequest>,
        ) -> std::result::Result<tonic::Response<super::State>, tonic::Status>;
        /// Relative bass/treble shelf change in whole dB.
        async fn adjust_tone(
            &self,
            request: tonic::Request<super::AdjustToneRequest>,
        ) -> std::result::Result<tonic::Response<super::State>, tonic::Status>;
        /// All band gains and both tone shelves back to 0 dB.
        async fn reset_gains(
            &self,
            request: tonic::Request<super::ResetGainsRequest>,
        ) -> std::result::Result<tonic::Response<super::State>, tonic::Status>;
        /// Apply a built-in preset by name (see ListPresets) and enable the EQ.
        async fn apply_preset(
            &self,
            request: tonic::Request<super::ApplyPresetRequest>,
        ) -> std::result::Result<tonic::Response<super::State>, tonic::Status>;
        async fn list_presets(
            &self,
            request: tonic::Request<super::ListPresetsRequest>,
        ) -> std::result::Result<
            tonic::Response<super::ListPresetsResponse>,
            tonic::Status,
        >;
        /// Persist the current state to the server's settings file.
        async fn save(
            &self,
            request: tonic::Request<super::SaveRequest>,
        ) -> std::result::Result<tonic::Response<super::SaveResponse>, tonic::Status>;
    }
    /// Remote control for a running `equalizer` process: the same 10-band
    /// Rockbox EQ + bass/treble shelves the TUI drives, plus pipeline telemetry
    /// for a remote status line / level meter.
    #[derive(Debug)]
    pub struct EqualizerServiceServer<T> {
        inner: Arc<T>,
        accept_compression_encodings: EnabledCompressionEncodings,
        send_compression_encodings: EnabledCompressionEncodings,
        max_decoding_message_size: Option<usize>,
        max_encoding_message_size: Option<usize>,
    }
    impl<T> EqualizerServiceServer<T> {
        pub fn new(inner: T) -> Self {
            Self::from_arc(Arc::new(inner))
        }
        pub fn from_arc(inner: Arc<T>) -> Self {
            Self {
                inner,
                accept_compression_encodings: Default::default(),
                send_compression_encodings: Default::default(),
                max_decoding_message_size: None,
                max_encoding_message_size: None,
            }
        }
        pub fn with_interceptor<F>(
            inner: T,
            interceptor: F,
        ) -> InterceptedService<Self, F>
        where
            F: tonic::service::Interceptor,
        {
            InterceptedService::new(Self::new(inner), interceptor)
        }
        /// Enable decompressing requests with the given encoding.
        #[must_use]
        pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
            self.accept_compression_encodings.enable(encoding);
            self
        }
        /// Compress responses with the given encoding, if the client supports it.
        #[must_use]
        pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
            self.send_compression_encodings.enable(encoding);
            self
        }
        /// Limits the maximum size of a decoded message.
        ///
        /// Default: `4MB`
        #[must_use]
        pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
            self.max_decoding_message_size = Some(limit);
            self
        }
        /// Limits the maximum size of an encoded message.
        ///
        /// Default: `usize::MAX`
        #[must_use]
        pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
            self.max_encoding_message_size = Some(limit);
            self
        }
    }
    impl<T, B> tonic::codegen::Service<http::Request<B>> for EqualizerServiceServer<T>
    where
        T: EqualizerService,
        B: Body + std::marker::Send + 'static,
        B::Error: Into<StdError> + std::marker::Send + 'static,
    {
        type Response = http::Response<tonic::body::BoxBody>;
        type Error = std::convert::Infallible;
        type Future = BoxFuture<Self::Response, Self::Error>;
        fn poll_ready(
            &mut self,
            _cx: &mut Context<'_>,
        ) -> Poll<std::result::Result<(), Self::Error>> {
            Poll::Ready(Ok(()))
        }
        fn call(&mut self, req: http::Request<B>) -> Self::Future {
            match req.uri().path() {
                "/equalizer.v1.EqualizerService/GetState" => {
                    #[allow(non_camel_case_types)]
                    struct GetStateSvc<T: EqualizerService>(pub Arc<T>);
                    impl<
                        T: EqualizerService,
                    > tonic::server::UnaryService<super::GetStateRequest>
                    for GetStateSvc<T> {
                        type Response = super::State;
                        type Future = BoxFuture<
                            tonic::Response<Self::Response>,
                            tonic::Status,
                        >;
                        fn call(
                            &mut self,
                            request: tonic::Request<super::GetStateRequest>,
                        ) -> Self::Future {
                            let inner = Arc::clone(&self.0);
                            let fut = async move {
                                <T as EqualizerService>::get_state(&inner, request).await
                            };
                            Box::pin(fut)
                        }
                    }
                    let accept_compression_encodings = self.accept_compression_encodings;
                    let send_compression_encodings = self.send_compression_encodings;
                    let max_decoding_message_size = self.max_decoding_message_size;
                    let max_encoding_message_size = self.max_encoding_message_size;
                    let inner = self.inner.clone();
                    let fut = async move {
                        let method = GetStateSvc(inner);
                        let codec = tonic::codec::ProstCodec::default();
                        let mut grpc = tonic::server::Grpc::new(codec)
                            .apply_compression_config(
                                accept_compression_encodings,
                                send_compression_encodings,
                            )
                            .apply_max_message_size_config(
                                max_decoding_message_size,
                                max_encoding_message_size,
                            );
                        let res = grpc.unary(method, req).await;
                        Ok(res)
                    };
                    Box::pin(fut)
                }
                "/equalizer.v1.EqualizerService/WatchState" => {
                    #[allow(non_camel_case_types)]
                    struct WatchStateSvc<T: EqualizerService>(pub Arc<T>);
                    impl<
                        T: EqualizerService,
                    > tonic::server::ServerStreamingService<super::WatchStateRequest>
                    for WatchStateSvc<T> {
                        type Response = super::State;
                        type ResponseStream = T::WatchStateStream;
                        type Future = BoxFuture<
                            tonic::Response<Self::ResponseStream>,
                            tonic::Status,
                        >;
                        fn call(
                            &mut self,
                            request: tonic::Request<super::WatchStateRequest>,
                        ) -> Self::Future {
                            let inner = Arc::clone(&self.0);
                            let fut = async move {
                                <T as EqualizerService>::watch_state(&inner, request).await
                            };
                            Box::pin(fut)
                        }
                    }
                    let accept_compression_encodings = self.accept_compression_encodings;
                    let send_compression_encodings = self.send_compression_encodings;
                    let max_decoding_message_size = self.max_decoding_message_size;
                    let max_encoding_message_size = self.max_encoding_message_size;
                    let inner = self.inner.clone();
                    let fut = async move {
                        let method = WatchStateSvc(inner);
                        let codec = tonic::codec::ProstCodec::default();
                        let mut grpc = tonic::server::Grpc::new(codec)
                            .apply_compression_config(
                                accept_compression_encodings,
                                send_compression_encodings,
                            )
                            .apply_max_message_size_config(
                                max_decoding_message_size,
                                max_encoding_message_size,
                            );
                        let res = grpc.server_streaming(method, req).await;
                        Ok(res)
                    };
                    Box::pin(fut)
                }
                "/equalizer.v1.EqualizerService/SetEnabled" => {
                    #[allow(non_camel_case_types)]
                    struct SetEnabledSvc<T: EqualizerService>(pub Arc<T>);
                    impl<
                        T: EqualizerService,
                    > tonic::server::UnaryService<super::SetEnabledRequest>
                    for SetEnabledSvc<T> {
                        type Response = super::State;
                        type Future = BoxFuture<
                            tonic::Response<Self::Response>,
                            tonic::Status,
                        >;
                        fn call(
                            &mut self,
                            request: tonic::Request<super::SetEnabledRequest>,
                        ) -> Self::Future {
                            let inner = Arc::clone(&self.0);
                            let fut = async move {
                                <T as EqualizerService>::set_enabled(&inner, request).await
                            };
                            Box::pin(fut)
                        }
                    }
                    let accept_compression_encodings = self.accept_compression_encodings;
                    let send_compression_encodings = self.send_compression_encodings;
                    let max_decoding_message_size = self.max_decoding_message_size;
                    let max_encoding_message_size = self.max_encoding_message_size;
                    let inner = self.inner.clone();
                    let fut = async move {
                        let method = SetEnabledSvc(inner);
                        let codec = tonic::codec::ProstCodec::default();
                        let mut grpc = tonic::server::Grpc::new(codec)
                            .apply_compression_config(
                                accept_compression_encodings,
                                send_compression_encodings,
                            )
                            .apply_max_message_size_config(
                                max_decoding_message_size,
                                max_encoding_message_size,
                            );
                        let res = grpc.unary(method, req).await;
                        Ok(res)
                    };
                    Box::pin(fut)
                }
                "/equalizer.v1.EqualizerService/AdjustBand" => {
                    #[allow(non_camel_case_types)]
                    struct AdjustBandSvc<T: EqualizerService>(pub Arc<T>);
                    impl<
                        T: EqualizerService,
                    > tonic::server::UnaryService<super::AdjustBandRequest>
                    for AdjustBandSvc<T> {
                        type Response = super::State;
                        type Future = BoxFuture<
                            tonic::Response<Self::Response>,
                            tonic::Status,
                        >;
                        fn call(
                            &mut self,
                            request: tonic::Request<super::AdjustBandRequest>,
                        ) -> Self::Future {
                            let inner = Arc::clone(&self.0);
                            let fut = async move {
                                <T as EqualizerService>::adjust_band(&inner, request).await
                            };
                            Box::pin(fut)
                        }
                    }
                    let accept_compression_encodings = self.accept_compression_encodings;
                    let send_compression_encodings = self.send_compression_encodings;
                    let max_decoding_message_size = self.max_decoding_message_size;
                    let max_encoding_message_size = self.max_encoding_message_size;
                    let inner = self.inner.clone();
                    let fut = async move {
                        let method = AdjustBandSvc(inner);
                        let codec = tonic::codec::ProstCodec::default();
                        let mut grpc = tonic::server::Grpc::new(codec)
                            .apply_compression_config(
                                accept_compression_encodings,
                                send_compression_encodings,
                            )
                            .apply_max_message_size_config(
                                max_decoding_message_size,
                                max_encoding_message_size,
                            );
                        let res = grpc.unary(method, req).await;
                        Ok(res)
                    };
                    Box::pin(fut)
                }
                "/equalizer.v1.EqualizerService/SetBandGains" => {
                    #[allow(non_camel_case_types)]
                    struct SetBandGainsSvc<T: EqualizerService>(pub Arc<T>);
                    impl<
                        T: EqualizerService,
                    > tonic::server::UnaryService<super::SetBandGainsRequest>
                    for SetBandGainsSvc<T> {
                        type Response = super::State;
                        type Future = BoxFuture<
                            tonic::Response<Self::Response>,
                            tonic::Status,
                        >;
                        fn call(
                            &mut self,
                            request: tonic::Request<super::SetBandGainsRequest>,
                        ) -> Self::Future {
                            let inner = Arc::clone(&self.0);
                            let fut = async move {
                                <T as EqualizerService>::set_band_gains(&inner, request)
                                    .await
                            };
                            Box::pin(fut)
                        }
                    }
                    let accept_compression_encodings = self.accept_compression_encodings;
                    let send_compression_encodings = self.send_compression_encodings;
                    let max_decoding_message_size = self.max_decoding_message_size;
                    let max_encoding_message_size = self.max_encoding_message_size;
                    let inner = self.inner.clone();
                    let fut = async move {
                        let method = SetBandGainsSvc(inner);
                        let codec = tonic::codec::ProstCodec::default();
                        let mut grpc = tonic::server::Grpc::new(codec)
                            .apply_compression_config(
                                accept_compression_encodings,
                                send_compression_encodings,
                            )
                            .apply_max_message_size_config(
                                max_decoding_message_size,
                                max_encoding_message_size,
                            );
                        let res = grpc.unary(method, req).await;
                        Ok(res)
                    };
                    Box::pin(fut)
                }
                "/equalizer.v1.EqualizerService/AdjustTone" => {
                    #[allow(non_camel_case_types)]
                    struct AdjustToneSvc<T: EqualizerService>(pub Arc<T>);
                    impl<
                        T: EqualizerService,
                    > tonic::server::UnaryService<super::AdjustToneRequest>
                    for AdjustToneSvc<T> {
                        type Response = super::State;
                        type Future = BoxFuture<
                            tonic::Response<Self::Response>,
                            tonic::Status,
                        >;
                        fn call(
                            &mut self,
                            request: tonic::Request<super::AdjustToneRequest>,
                        ) -> Self::Future {
                            let inner = Arc::clone(&self.0);
                            let fut = async move {
                                <T as EqualizerService>::adjust_tone(&inner, request).await
                            };
                            Box::pin(fut)
                        }
                    }
                    let accept_compression_encodings = self.accept_compression_encodings;
                    let send_compression_encodings = self.send_compression_encodings;
                    let max_decoding_message_size = self.max_decoding_message_size;
                    let max_encoding_message_size = self.max_encoding_message_size;
                    let inner = self.inner.clone();
                    let fut = async move {
                        let method = AdjustToneSvc(inner);
                        let codec = tonic::codec::ProstCodec::default();
                        let mut grpc = tonic::server::Grpc::new(codec)
                            .apply_compression_config(
                                accept_compression_encodings,
                                send_compression_encodings,
                            )
                            .apply_max_message_size_config(
                                max_decoding_message_size,
                                max_encoding_message_size,
                            );
                        let res = grpc.unary(method, req).await;
                        Ok(res)
                    };
                    Box::pin(fut)
                }
                "/equalizer.v1.EqualizerService/ResetGains" => {
                    #[allow(non_camel_case_types)]
                    struct ResetGainsSvc<T: EqualizerService>(pub Arc<T>);
                    impl<
                        T: EqualizerService,
                    > tonic::server::UnaryService<super::ResetGainsRequest>
                    for ResetGainsSvc<T> {
                        type Response = super::State;
                        type Future = BoxFuture<
                            tonic::Response<Self::Response>,
                            tonic::Status,
                        >;
                        fn call(
                            &mut self,
                            request: tonic::Request<super::ResetGainsRequest>,
                        ) -> Self::Future {
                            let inner = Arc::clone(&self.0);
                            let fut = async move {
                                <T as EqualizerService>::reset_gains(&inner, request).await
                            };
                            Box::pin(fut)
                        }
                    }
                    let accept_compression_encodings = self.accept_compression_encodings;
                    let send_compression_encodings = self.send_compression_encodings;
                    let max_decoding_message_size = self.max_decoding_message_size;
                    let max_encoding_message_size = self.max_encoding_message_size;
                    let inner = self.inner.clone();
                    let fut = async move {
                        let method = ResetGainsSvc(inner);
                        let codec = tonic::codec::ProstCodec::default();
                        let mut grpc = tonic::server::Grpc::new(codec)
                            .apply_compression_config(
                                accept_compression_encodings,
                                send_compression_encodings,
                            )
                            .apply_max_message_size_config(
                                max_decoding_message_size,
                                max_encoding_message_size,
                            );
                        let res = grpc.unary(method, req).await;
                        Ok(res)
                    };
                    Box::pin(fut)
                }
                "/equalizer.v1.EqualizerService/ApplyPreset" => {
                    #[allow(non_camel_case_types)]
                    struct ApplyPresetSvc<T: EqualizerService>(pub Arc<T>);
                    impl<
                        T: EqualizerService,
                    > tonic::server::UnaryService<super::ApplyPresetRequest>
                    for ApplyPresetSvc<T> {
                        type Response = super::State;
                        type Future = BoxFuture<
                            tonic::Response<Self::Response>,
                            tonic::Status,
                        >;
                        fn call(
                            &mut self,
                            request: tonic::Request<super::ApplyPresetRequest>,
                        ) -> Self::Future {
                            let inner = Arc::clone(&self.0);
                            let fut = async move {
                                <T as EqualizerService>::apply_preset(&inner, request).await
                            };
                            Box::pin(fut)
                        }
                    }
                    let accept_compression_encodings = self.accept_compression_encodings;
                    let send_compression_encodings = self.send_compression_encodings;
                    let max_decoding_message_size = self.max_decoding_message_size;
                    let max_encoding_message_size = self.max_encoding_message_size;
                    let inner = self.inner.clone();
                    let fut = async move {
                        let method = ApplyPresetSvc(inner);
                        let codec = tonic::codec::ProstCodec::default();
                        let mut grpc = tonic::server::Grpc::new(codec)
                            .apply_compression_config(
                                accept_compression_encodings,
                                send_compression_encodings,
                            )
                            .apply_max_message_size_config(
                                max_decoding_message_size,
                                max_encoding_message_size,
                            );
                        let res = grpc.unary(method, req).await;
                        Ok(res)
                    };
                    Box::pin(fut)
                }
                "/equalizer.v1.EqualizerService/ListPresets" => {
                    #[allow(non_camel_case_types)]
                    struct ListPresetsSvc<T: EqualizerService>(pub Arc<T>);
                    impl<
                        T: EqualizerService,
                    > tonic::server::UnaryService<super::ListPresetsRequest>
                    for ListPresetsSvc<T> {
                        type Response = super::ListPresetsResponse;
                        type Future = BoxFuture<
                            tonic::Response<Self::Response>,
                            tonic::Status,
                        >;
                        fn call(
                            &mut self,
                            request: tonic::Request<super::ListPresetsRequest>,
                        ) -> Self::Future {
                            let inner = Arc::clone(&self.0);
                            let fut = async move {
                                <T as EqualizerService>::list_presets(&inner, request).await
                            };
                            Box::pin(fut)
                        }
                    }
                    let accept_compression_encodings = self.accept_compression_encodings;
                    let send_compression_encodings = self.send_compression_encodings;
                    let max_decoding_message_size = self.max_decoding_message_size;
                    let max_encoding_message_size = self.max_encoding_message_size;
                    let inner = self.inner.clone();
                    let fut = async move {
                        let method = ListPresetsSvc(inner);
                        let codec = tonic::codec::ProstCodec::default();
                        let mut grpc = tonic::server::Grpc::new(codec)
                            .apply_compression_config(
                                accept_compression_encodings,
                                send_compression_encodings,
                            )
                            .apply_max_message_size_config(
                                max_decoding_message_size,
                                max_encoding_message_size,
                            );
                        let res = grpc.unary(method, req).await;
                        Ok(res)
                    };
                    Box::pin(fut)
                }
                "/equalizer.v1.EqualizerService/Save" => {
                    #[allow(non_camel_case_types)]
                    struct SaveSvc<T: EqualizerService>(pub Arc<T>);
                    impl<
                        T: EqualizerService,
                    > tonic::server::UnaryService<super::SaveRequest> for SaveSvc<T> {
                        type Response = super::SaveResponse;
                        type Future = BoxFuture<
                            tonic::Response<Self::Response>,
                            tonic::Status,
                        >;
                        fn call(
                            &mut self,
                            request: tonic::Request<super::SaveRequest>,
                        ) -> Self::Future {
                            let inner = Arc::clone(&self.0);
                            let fut = async move {
                                <T as EqualizerService>::save(&inner, request).await
                            };
                            Box::pin(fut)
                        }
                    }
                    let accept_compression_encodings = self.accept_compression_encodings;
                    let send_compression_encodings = self.send_compression_encodings;
                    let max_decoding_message_size = self.max_decoding_message_size;
                    let max_encoding_message_size = self.max_encoding_message_size;
                    let inner = self.inner.clone();
                    let fut = async move {
                        let method = SaveSvc(inner);
                        let codec = tonic::codec::ProstCodec::default();
                        let mut grpc = tonic::server::Grpc::new(codec)
                            .apply_compression_config(
                                accept_compression_encodings,
                                send_compression_encodings,
                            )
                            .apply_max_message_size_config(
                                max_decoding_message_size,
                                max_encoding_message_size,
                            );
                        let res = grpc.unary(method, req).await;
                        Ok(res)
                    };
                    Box::pin(fut)
                }
                _ => {
                    Box::pin(async move {
                        let mut response = http::Response::new(empty_body());
                        let headers = response.headers_mut();
                        headers
                            .insert(
                                tonic::Status::GRPC_STATUS,
                                (tonic::Code::Unimplemented as i32).into(),
                            );
                        headers
                            .insert(
                                http::header::CONTENT_TYPE,
                                tonic::metadata::GRPC_CONTENT_TYPE,
                            );
                        Ok(response)
                    })
                }
            }
        }
    }
    impl<T> Clone for EqualizerServiceServer<T> {
        fn clone(&self) -> Self {
            let inner = self.inner.clone();
            Self {
                inner,
                accept_compression_encodings: self.accept_compression_encodings,
                send_compression_encodings: self.send_compression_encodings,
                max_decoding_message_size: self.max_decoding_message_size,
                max_encoding_message_size: self.max_encoding_message_size,
            }
        }
    }
    /// Generated gRPC service name
    pub const SERVICE_NAME: &str = "equalizer.v1.EqualizerService";
    impl<T> tonic::server::NamedService for EqualizerServiceServer<T> {
        const NAME: &'static str = SERVICE_NAME;
    }
}
