pub trait RankService:
Debug
+ Send
+ Sync {
// Provided methods
fn rank(
&self,
_req: RankRequest,
_options: RequestOptions,
) -> impl Future<Output = Result<Response<RankResponse>>> + Send { ... }
fn list_operations(
&self,
_req: ListOperationsRequest,
_options: RequestOptions,
) -> impl Future<Output = Result<Response<ListOperationsResponse>>> + Send { ... }
fn get_operation(
&self,
_req: GetOperationRequest,
_options: RequestOptions,
) -> impl Future<Output = Result<Response<Operation>>> + Send { ... }
fn cancel_operation(
&self,
_req: CancelOperationRequest,
_options: RequestOptions,
) -> impl Future<Output = Result<Response<()>>> + Send { ... }
}rank-service only.Expand description
Defines the trait used to implement super::client::RankService.
Application developers may need to implement this trait to mock
client::RankService. In other use-cases, application developers only
use client::RankService and need not be concerned with this trait or
its implementations.
Services gain new RPCs routinely. Consequently, this trait gains new methods too. To avoid breaking applications the trait provides a default implementation of each method. Most of these implementations just return an error.
Provided Methods§
Sourcefn rank(
&self,
_req: RankRequest,
_options: RequestOptions,
) -> impl Future<Output = Result<Response<RankResponse>>> + Send
fn rank( &self, _req: RankRequest, _options: RequestOptions, ) -> impl Future<Output = Result<Response<RankResponse>>> + Send
Implements super::client::RankService::rank.
Sourcefn list_operations(
&self,
_req: ListOperationsRequest,
_options: RequestOptions,
) -> impl Future<Output = Result<Response<ListOperationsResponse>>> + Send
fn list_operations( &self, _req: ListOperationsRequest, _options: RequestOptions, ) -> impl Future<Output = Result<Response<ListOperationsResponse>>> + Send
Implements super::client::RankService::list_operations.
Sourcefn get_operation(
&self,
_req: GetOperationRequest,
_options: RequestOptions,
) -> impl Future<Output = Result<Response<Operation>>> + Send
fn get_operation( &self, _req: GetOperationRequest, _options: RequestOptions, ) -> impl Future<Output = Result<Response<Operation>>> + Send
Implements super::client::RankService::get_operation.
Sourcefn cancel_operation(
&self,
_req: CancelOperationRequest,
_options: RequestOptions,
) -> impl Future<Output = Result<Response<()>>> + Send
fn cancel_operation( &self, _req: CancelOperationRequest, _options: RequestOptions, ) -> impl Future<Output = Result<Response<()>>> + Send
Implements super::client::RankService::cancel_operation.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.