Struct google_api_proto::google::cloud::retail::v2alpha::project_service_client::ProjectServiceClient
source · pub struct ProjectServiceClient<T> { /* private fields */ }
Expand description
Service for settings at Project level.
Implementations§
source§impl<T> ProjectServiceClient<T>where
T: GrpcService<BoxBody>,
T::Error: Into<StdError>,
T::ResponseBody: Body<Data = Bytes> + Send + 'static,
<T::ResponseBody as Body>::Error: Into<StdError> + Send,
impl<T> ProjectServiceClient<T>where
T: GrpcService<BoxBody>,
T::Error: Into<StdError>,
T::ResponseBody: Body<Data = Bytes> + Send + 'static,
<T::ResponseBody as Body>::Error: Into<StdError> + Send,
pub fn new(inner: T) -> Self
pub fn with_origin(inner: T, origin: Uri) -> Self
pub fn with_interceptor<F>(
inner: T,
interceptor: F,
) -> ProjectServiceClient<InterceptedService<T, F>>where
F: Interceptor,
T::ResponseBody: Default,
T: Service<Request<BoxBody>, Response = Response<<T as GrpcService<BoxBody>>::ResponseBody>>,
<T as Service<Request<BoxBody>>>::Error: Into<StdError> + Send + Sync,
sourcepub fn send_compressed(self, encoding: CompressionEncoding) -> Self
pub fn send_compressed(self, encoding: CompressionEncoding) -> Self
Compress requests with the given encoding.
This requires the server to support it otherwise it might respond with an error.
sourcepub fn accept_compressed(self, encoding: CompressionEncoding) -> Self
pub fn accept_compressed(self, encoding: CompressionEncoding) -> Self
Enable decompressing responses.
sourcepub fn max_decoding_message_size(self, limit: usize) -> Self
pub fn max_decoding_message_size(self, limit: usize) -> Self
Limits the maximum size of a decoded message.
Default: 4MB
sourcepub fn max_encoding_message_size(self, limit: usize) -> Self
pub fn max_encoding_message_size(self, limit: usize) -> Self
Limits the maximum size of an encoded message.
Default: usize::MAX
sourcepub async fn get_project(
&mut self,
request: impl IntoRequest<GetProjectRequest>,
) -> Result<Response<Project>, Status>
pub async fn get_project( &mut self, request: impl IntoRequest<GetProjectRequest>, ) -> Result<Response<Project>, Status>
Gets the project.
Throws NOT_FOUND
if the project wasn’t initialized for the Retail API
service.
sourcepub async fn accept_terms(
&mut self,
request: impl IntoRequest<AcceptTermsRequest>,
) -> Result<Response<Project>, Status>
pub async fn accept_terms( &mut self, request: impl IntoRequest<AcceptTermsRequest>, ) -> Result<Response<Project>, Status>
Accepts service terms for this project. By making requests to this API, you agree to the terms of service linked below. https://cloud.google.com/retail/data-use-terms
sourcepub async fn enroll_solution(
&mut self,
request: impl IntoRequest<EnrollSolutionRequest>,
) -> Result<Response<Operation>, Status>
pub async fn enroll_solution( &mut self, request: impl IntoRequest<EnrollSolutionRequest>, ) -> Result<Response<Operation>, Status>
The method enrolls a solution of type [Retail Search][google.cloud.retail.v2alpha.SolutionType.SOLUTION_TYPE_SEARCH] into a project.
The [Recommendations AI solution type][google.cloud.retail.v2alpha.SolutionType.SOLUTION_TYPE_RECOMMENDATION] is enrolled by default when your project enables Retail API, so you don’t need to call the enrollSolution method for recommendations.
sourcepub async fn list_enrolled_solutions(
&mut self,
request: impl IntoRequest<ListEnrolledSolutionsRequest>,
) -> Result<Response<ListEnrolledSolutionsResponse>, Status>
pub async fn list_enrolled_solutions( &mut self, request: impl IntoRequest<ListEnrolledSolutionsRequest>, ) -> Result<Response<ListEnrolledSolutionsResponse>, Status>
Lists all the retail API solutions the project has enrolled.
sourcepub async fn get_logging_config(
&mut self,
request: impl IntoRequest<GetLoggingConfigRequest>,
) -> Result<Response<LoggingConfig>, Status>
pub async fn get_logging_config( &mut self, request: impl IntoRequest<GetLoggingConfigRequest>, ) -> Result<Response<LoggingConfig>, Status>
Gets the [LoggingConfig][google.cloud.retail.v2alpha.LoggingConfig] of the requested project.
sourcepub async fn update_logging_config(
&mut self,
request: impl IntoRequest<UpdateLoggingConfigRequest>,
) -> Result<Response<LoggingConfig>, Status>
pub async fn update_logging_config( &mut self, request: impl IntoRequest<UpdateLoggingConfigRequest>, ) -> Result<Response<LoggingConfig>, Status>
Updates the [LoggingConfig][google.cloud.retail.v2alpha.LoggingConfig] of the requested project.
sourcepub async fn get_alert_config(
&mut self,
request: impl IntoRequest<GetAlertConfigRequest>,
) -> Result<Response<AlertConfig>, Status>
pub async fn get_alert_config( &mut self, request: impl IntoRequest<GetAlertConfigRequest>, ) -> Result<Response<AlertConfig>, Status>
Get the [AlertConfig][google.cloud.retail.v2alpha.AlertConfig] of the requested project.
sourcepub async fn update_alert_config(
&mut self,
request: impl IntoRequest<UpdateAlertConfigRequest>,
) -> Result<Response<AlertConfig>, Status>
pub async fn update_alert_config( &mut self, request: impl IntoRequest<UpdateAlertConfigRequest>, ) -> Result<Response<AlertConfig>, Status>
Update the alert config of the requested project.
Trait Implementations§
source§impl<T: Clone> Clone for ProjectServiceClient<T>
impl<T: Clone> Clone for ProjectServiceClient<T>
source§fn clone(&self) -> ProjectServiceClient<T>
fn clone(&self) -> ProjectServiceClient<T>
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moreAuto Trait Implementations§
impl<T> !Freeze for ProjectServiceClient<T>
impl<T> RefUnwindSafe for ProjectServiceClient<T>where
T: RefUnwindSafe,
impl<T> Send for ProjectServiceClient<T>where
T: Send,
impl<T> Sync for ProjectServiceClient<T>where
T: Sync,
impl<T> Unpin for ProjectServiceClient<T>where
T: Unpin,
impl<T> UnwindSafe for ProjectServiceClient<T>where
T: UnwindSafe,
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T
in a tonic::Request