Struct teaclave_proto::teaclave_storage_service_proto::teaclave_storage_client::TeaclaveStorageClient
source · [−]pub struct TeaclaveStorageClient<T> { /* private fields */ }
Implementations
sourceimpl<T> TeaclaveStorageClient<T>where
T: GrpcService<BoxBody>,
T::ResponseBody: Body + Send + 'static,
T::Error: Into<StdError>,
<T::ResponseBody as Body>::Error: Into<StdError> + Send,
impl<T> TeaclaveStorageClient<T>where
T: GrpcService<BoxBody>,
T::ResponseBody: Body + Send + 'static,
T::Error: Into<StdError>,
<T::ResponseBody as Body>::Error: Into<StdError> + Send,
pub fn new(inner: T) -> Self
pub fn with_interceptor<F>(
inner: T,
interceptor: F
) -> TeaclaveStorageClient<InterceptedService<T, F>>where
F: Interceptor,
T: Service<Request<BoxBody>, Response = Response<<T as GrpcService<BoxBody>>::ResponseBody>>,
<T as Service<Request<BoxBody>>>::Error: Into<StdError> + Send + Sync,
sourcepub fn send_gzip(self) -> Self
pub fn send_gzip(self) -> Self
Compress requests with gzip
.
This requires the server to support it otherwise it might respond with an error.
sourcepub fn accept_gzip(self) -> Self
pub fn accept_gzip(self) -> Self
Enable decompressing responses with gzip
.
pub async fn get(
&mut self,
request: impl IntoRequest<GetRequest>
) -> Result<Response<GetResponse>, Status>
pub async fn put(
&mut self,
request: impl IntoRequest<PutRequest>
) -> Result<Response<()>, Status>
pub async fn delete(
&mut self,
request: impl IntoRequest<DeleteRequest>
) -> Result<Response<()>, Status>
pub async fn enqueue(
&mut self,
request: impl IntoRequest<EnqueueRequest>
) -> Result<Response<()>, Status>
pub async fn dequeue(
&mut self,
request: impl IntoRequest<DequeueRequest>
) -> Result<Response<DequeueResponse>, Status>
pub async fn get_keys_by_prefix(
&mut self,
request: impl IntoRequest<GetKeysByPrefixRequest>
) -> Result<Response<GetKeysByPrefixResponse>, Status>
Trait Implementations
sourceimpl<T: Clone> Clone for TeaclaveStorageClient<T>
impl<T: Clone> Clone for TeaclaveStorageClient<T>
sourcefn clone(&self) -> TeaclaveStorageClient<T>
fn clone(&self) -> TeaclaveStorageClient<T>
Returns a copy of the value. Read more
1.0.0const fn clone_from(&mut self, source: &Self)
const fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresourceimpl<T: Debug> Debug for TeaclaveStorageClient<T>
impl<T: Debug> Debug for TeaclaveStorageClient<T>
Auto Trait Implementations
impl<T> RefUnwindSafe for TeaclaveStorageClient<T>where
T: RefUnwindSafe,
impl<T> Send for TeaclaveStorageClient<T>where
T: Send,
impl<T> Sync for TeaclaveStorageClient<T>where
T: Sync,
impl<T> Unpin for TeaclaveStorageClient<T>where
T: Unpin,
impl<T> UnwindSafe for TeaclaveStorageClient<T>where
T: UnwindSafe,
Blanket Implementations
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstablefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> Instrument for T
impl<T> Instrument for T
sourcefn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
sourcefn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
sourceimpl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
sourcefn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T
in a tonic::Request
impl<T> ToOwned for Twhere
T: Clone,
impl<T> ToOwned for Twhere
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
fn clone_into(&self, target: &mut T)
fn clone_into(&self, target: &mut T)
Uses borrowed data to replace owned data, usually by cloning. Read more