Your browser sucks, JavaScript disabled! Gunnar's console needs JavaScript and WebAssembly. Git over SSH on port 2222 does not.

nordisk/holger

holger-cli/src/generated/holger.room.v1.rs

// @generated by `cargo xtask gen-proto` (protox + tonic-build, no protoc).
// DO NOT EDIT BY HAND. Regenerate after changing proto/holger.proto.

// This file is @generated by prost-build.
#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
pub struct PrivateEstateRequest {}
#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
pub struct PrivateEstateReply {
    /// The ONE shop's order page: product, site, account and ticket named.
    #[prost(string, tag = "1")]
    pub shop_url: ::prost::alloc::string::String,
    /// One sentence for the console to show as it is.
    #[prost(string, tag = "2")]
    pub words: ::prost::alloc::string::String,
}
#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
pub struct RoomRequest {
    #[prost(string, tag = "1")]
    pub repository: ::prost::alloc::string::String,
}
#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
pub struct RoomReply {
    #[prost(string, tag = "1")]
    pub repository: ::prost::alloc::string::String,
    /// Where the person buys more room for this repository: the ONE shop, with
    /// the product and the repository named. Empty when this box sells nothing.
    #[prost(string, tag = "2")]
    pub shop_url: ::prost::alloc::string::String,
    /// One sentence for the console to show as it is.
    #[prost(string, tag = "3")]
    pub words: ::prost::alloc::string::String,
}
/// Generated client implementations.
pub mod room_service_client {
    #![allow(
        unused_variables,
        dead_code,
        missing_docs,
        clippy::wildcard_imports,
        clippy::let_unit_value,
    )]
    use tonic::codegen::*;
    use tonic::codegen::http::Uri;
    #[derive(Debug, Clone)]
    pub struct RoomServiceClient<T> {
        inner: tonic::client::Grpc<T>,
    }
    impl RoomServiceClient<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> RoomServiceClient<T>
    where
        T: tonic::client::GrpcService<tonic::body::Body>,
        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,
        ) -> RoomServiceClient<InterceptedService<T, F>>
        where
            F: tonic::service::Interceptor,
            T::ResponseBody: Default,
            T: tonic::codegen::Service<
                http::Request<tonic::body::Body>,
                Response = http::Response<
                    <T as tonic::client::GrpcService<tonic::body::Body>>::ResponseBody,
                >,
            >,
            <T as tonic::codegen::Service<
                http::Request<tonic::body::Body>,
            >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
        {
            RoomServiceClient::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
        }
        /// READER on the repository (the same gate as ReadUsage). NOT_FOUND for a
        /// repository this server does not serve.
        pub async fn room(
            &mut self,
            request: impl tonic::IntoRequest<super::RoomRequest>,
        ) -> std::result::Result<tonic::Response<super::RoomReply>, tonic::Status> {
            self.inner
                .ready()
                .await
                .map_err(|e| {
                    tonic::Status::unknown(
                        format!("Service was not ready: {}", e.into()),
                    )
                })?;
            let codec = tonic_prost::ProstCodec::default();
            let path = http::uri::PathAndQuery::from_static(
                "/holger.room.v1.RoomService/Room",
            );
            let mut req = request.into_request();
            req.extensions_mut()
                .insert(GrpcMethod::new("holger.room.v1.RoomService", "Room"));
            self.inner.unary(req, path, codec).await
        }
        /// **Where a person signed in to this Holger orders a private Holger of
        /// their own** (2026-10-21): the ONE shop's order page for a private estate,
        /// with the person's `estate` actor ticket (this box's fleet key, ten minutes,
        /// one use) — the proof the shop sells the estate to that account and nobody
        /// else. ANY signed-in person (Gunnar's rule, lane SU1); nobody signed in gets
        /// the page without a ticket and is told to sign in first. Empty when this
        /// box sells nothing.
        pub async fn private_estate(
            &mut self,
            request: impl tonic::IntoRequest<super::PrivateEstateRequest>,
        ) -> std::result::Result<
            tonic::Response<super::PrivateEstateReply>,
            tonic::Status,
        > {
            self.inner
                .ready()
                .await
                .map_err(|e| {
                    tonic::Status::unknown(
                        format!("Service was not ready: {}", e.into()),
                    )
                })?;
            let codec = tonic_prost::ProstCodec::default();
            let path = http::uri::PathAndQuery::from_static(
                "/holger.room.v1.RoomService/PrivateEstate",
            );
            let mut req = request.into_request();
            req.extensions_mut()
                .insert(GrpcMethod::new("holger.room.v1.RoomService", "PrivateEstate"));
            self.inner.unary(req, path, codec).await
        }
    }
}