#[cfg(feature = "agents")]
#[async_trait::async_trait]
pub trait Agents: std::fmt::Debug + Send + Sync {
async fn get_agent(
&self,
req: crate::model::GetAgentRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Agent>>;
async fn set_agent(
&self,
req: crate::model::SetAgentRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Agent>>;
async fn delete_agent(
&self,
req: crate::model::DeleteAgentRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>>;
async fn search_agents(
&self,
req: crate::model::SearchAgentsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::SearchAgentsResponse>>;
async fn train_agent(
&self,
req: crate::model::TrainAgentRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>;
async fn export_agent(
&self,
req: crate::model::ExportAgentRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>;
async fn import_agent(
&self,
req: crate::model::ImportAgentRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>;
async fn restore_agent(
&self,
req: crate::model::RestoreAgentRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>;
async fn get_validation_result(
&self,
req: crate::model::GetValidationResultRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::ValidationResult>>;
async fn list_locations(
&self,
req: google_cloud_location::model::ListLocationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::ListLocationsResponse>>;
async fn get_location(
&self,
req: google_cloud_location::model::GetLocationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::Location>>;
async fn list_operations(
&self,
req: google_cloud_longrunning::model::ListOperationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::ListOperationsResponse>>;
async fn get_operation(
&self,
req: google_cloud_longrunning::model::GetOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>;
async fn cancel_operation(
&self,
req: google_cloud_longrunning::model::CancelOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>>;
fn get_polling_error_policy(
&self,
options: &crate::RequestOptions,
) -> std::sync::Arc<dyn google_cloud_gax::polling_error_policy::PollingErrorPolicy>;
fn get_polling_backoff_policy(
&self,
options: &crate::RequestOptions,
) -> std::sync::Arc<dyn google_cloud_gax::polling_backoff_policy::PollingBackoffPolicy>;
}
#[cfg(feature = "agents")]
#[async_trait::async_trait]
impl<T: super::Agents> Agents for T {
async fn get_agent(
&self,
req: crate::model::GetAgentRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Agent>> {
T::get_agent(self, req, options).await
}
async fn set_agent(
&self,
req: crate::model::SetAgentRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Agent>> {
T::set_agent(self, req, options).await
}
async fn delete_agent(
&self,
req: crate::model::DeleteAgentRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>> {
T::delete_agent(self, req, options).await
}
async fn search_agents(
&self,
req: crate::model::SearchAgentsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::SearchAgentsResponse>> {
T::search_agents(self, req, options).await
}
async fn train_agent(
&self,
req: crate::model::TrainAgentRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>> {
T::train_agent(self, req, options).await
}
async fn export_agent(
&self,
req: crate::model::ExportAgentRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>> {
T::export_agent(self, req, options).await
}
async fn import_agent(
&self,
req: crate::model::ImportAgentRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>> {
T::import_agent(self, req, options).await
}
async fn restore_agent(
&self,
req: crate::model::RestoreAgentRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>> {
T::restore_agent(self, req, options).await
}
async fn get_validation_result(
&self,
req: crate::model::GetValidationResultRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::ValidationResult>> {
T::get_validation_result(self, req, options).await
}
async fn list_locations(
&self,
req: google_cloud_location::model::ListLocationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::ListLocationsResponse>> {
T::list_locations(self, req, options).await
}
async fn get_location(
&self,
req: google_cloud_location::model::GetLocationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::Location>> {
T::get_location(self, req, options).await
}
async fn list_operations(
&self,
req: google_cloud_longrunning::model::ListOperationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::ListOperationsResponse>>
{
T::list_operations(self, req, options).await
}
async fn get_operation(
&self,
req: google_cloud_longrunning::model::GetOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>> {
T::get_operation(self, req, options).await
}
async fn cancel_operation(
&self,
req: google_cloud_longrunning::model::CancelOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>> {
T::cancel_operation(self, req, options).await
}
fn get_polling_error_policy(
&self,
options: &crate::RequestOptions,
) -> std::sync::Arc<dyn google_cloud_gax::polling_error_policy::PollingErrorPolicy> {
T::get_polling_error_policy(self, options)
}
fn get_polling_backoff_policy(
&self,
options: &crate::RequestOptions,
) -> std::sync::Arc<dyn google_cloud_gax::polling_backoff_policy::PollingBackoffPolicy> {
T::get_polling_backoff_policy(self, options)
}
}
#[cfg(feature = "answer-records")]
#[async_trait::async_trait]
pub trait AnswerRecords: std::fmt::Debug + Send + Sync {
async fn list_answer_records(
&self,
req: crate::model::ListAnswerRecordsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::ListAnswerRecordsResponse>>;
async fn update_answer_record(
&self,
req: crate::model::UpdateAnswerRecordRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::AnswerRecord>>;
async fn list_locations(
&self,
req: google_cloud_location::model::ListLocationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::ListLocationsResponse>>;
async fn get_location(
&self,
req: google_cloud_location::model::GetLocationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::Location>>;
async fn list_operations(
&self,
req: google_cloud_longrunning::model::ListOperationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::ListOperationsResponse>>;
async fn get_operation(
&self,
req: google_cloud_longrunning::model::GetOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>;
async fn cancel_operation(
&self,
req: google_cloud_longrunning::model::CancelOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>>;
}
#[cfg(feature = "answer-records")]
#[async_trait::async_trait]
impl<T: super::AnswerRecords> AnswerRecords for T {
async fn list_answer_records(
&self,
req: crate::model::ListAnswerRecordsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::ListAnswerRecordsResponse>> {
T::list_answer_records(self, req, options).await
}
async fn update_answer_record(
&self,
req: crate::model::UpdateAnswerRecordRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::AnswerRecord>> {
T::update_answer_record(self, req, options).await
}
async fn list_locations(
&self,
req: google_cloud_location::model::ListLocationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::ListLocationsResponse>> {
T::list_locations(self, req, options).await
}
async fn get_location(
&self,
req: google_cloud_location::model::GetLocationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::Location>> {
T::get_location(self, req, options).await
}
async fn list_operations(
&self,
req: google_cloud_longrunning::model::ListOperationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::ListOperationsResponse>>
{
T::list_operations(self, req, options).await
}
async fn get_operation(
&self,
req: google_cloud_longrunning::model::GetOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>> {
T::get_operation(self, req, options).await
}
async fn cancel_operation(
&self,
req: google_cloud_longrunning::model::CancelOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>> {
T::cancel_operation(self, req, options).await
}
}
#[cfg(feature = "contexts")]
#[async_trait::async_trait]
pub trait Contexts: std::fmt::Debug + Send + Sync {
async fn list_contexts(
&self,
req: crate::model::ListContextsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::ListContextsResponse>>;
async fn get_context(
&self,
req: crate::model::GetContextRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Context>>;
async fn create_context(
&self,
req: crate::model::CreateContextRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Context>>;
async fn update_context(
&self,
req: crate::model::UpdateContextRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Context>>;
async fn delete_context(
&self,
req: crate::model::DeleteContextRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>>;
async fn delete_all_contexts(
&self,
req: crate::model::DeleteAllContextsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>>;
async fn list_locations(
&self,
req: google_cloud_location::model::ListLocationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::ListLocationsResponse>>;
async fn get_location(
&self,
req: google_cloud_location::model::GetLocationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::Location>>;
async fn list_operations(
&self,
req: google_cloud_longrunning::model::ListOperationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::ListOperationsResponse>>;
async fn get_operation(
&self,
req: google_cloud_longrunning::model::GetOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>;
async fn cancel_operation(
&self,
req: google_cloud_longrunning::model::CancelOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>>;
}
#[cfg(feature = "contexts")]
#[async_trait::async_trait]
impl<T: super::Contexts> Contexts for T {
async fn list_contexts(
&self,
req: crate::model::ListContextsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::ListContextsResponse>> {
T::list_contexts(self, req, options).await
}
async fn get_context(
&self,
req: crate::model::GetContextRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Context>> {
T::get_context(self, req, options).await
}
async fn create_context(
&self,
req: crate::model::CreateContextRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Context>> {
T::create_context(self, req, options).await
}
async fn update_context(
&self,
req: crate::model::UpdateContextRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Context>> {
T::update_context(self, req, options).await
}
async fn delete_context(
&self,
req: crate::model::DeleteContextRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>> {
T::delete_context(self, req, options).await
}
async fn delete_all_contexts(
&self,
req: crate::model::DeleteAllContextsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>> {
T::delete_all_contexts(self, req, options).await
}
async fn list_locations(
&self,
req: google_cloud_location::model::ListLocationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::ListLocationsResponse>> {
T::list_locations(self, req, options).await
}
async fn get_location(
&self,
req: google_cloud_location::model::GetLocationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::Location>> {
T::get_location(self, req, options).await
}
async fn list_operations(
&self,
req: google_cloud_longrunning::model::ListOperationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::ListOperationsResponse>>
{
T::list_operations(self, req, options).await
}
async fn get_operation(
&self,
req: google_cloud_longrunning::model::GetOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>> {
T::get_operation(self, req, options).await
}
async fn cancel_operation(
&self,
req: google_cloud_longrunning::model::CancelOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>> {
T::cancel_operation(self, req, options).await
}
}
#[cfg(feature = "conversations")]
#[async_trait::async_trait]
pub trait Conversations: std::fmt::Debug + Send + Sync {
async fn create_conversation(
&self,
req: crate::model::CreateConversationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Conversation>>;
async fn list_conversations(
&self,
req: crate::model::ListConversationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::ListConversationsResponse>>;
async fn get_conversation(
&self,
req: crate::model::GetConversationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Conversation>>;
async fn complete_conversation(
&self,
req: crate::model::CompleteConversationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Conversation>>;
async fn ingest_context_references(
&self,
req: crate::model::IngestContextReferencesRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::IngestContextReferencesResponse>>;
async fn list_messages(
&self,
req: crate::model::ListMessagesRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::ListMessagesResponse>>;
async fn suggest_conversation_summary(
&self,
req: crate::model::SuggestConversationSummaryRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::SuggestConversationSummaryResponse>>;
async fn generate_stateless_summary(
&self,
req: crate::model::GenerateStatelessSummaryRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::GenerateStatelessSummaryResponse>>;
async fn generate_stateless_suggestion(
&self,
req: crate::model::GenerateStatelessSuggestionRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::GenerateStatelessSuggestionResponse>>;
async fn search_knowledge(
&self,
req: crate::model::SearchKnowledgeRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::SearchKnowledgeResponse>>;
async fn generate_suggestions(
&self,
req: crate::model::GenerateSuggestionsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::GenerateSuggestionsResponse>>;
async fn list_locations(
&self,
req: google_cloud_location::model::ListLocationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::ListLocationsResponse>>;
async fn get_location(
&self,
req: google_cloud_location::model::GetLocationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::Location>>;
async fn list_operations(
&self,
req: google_cloud_longrunning::model::ListOperationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::ListOperationsResponse>>;
async fn get_operation(
&self,
req: google_cloud_longrunning::model::GetOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>;
async fn cancel_operation(
&self,
req: google_cloud_longrunning::model::CancelOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>>;
}
#[cfg(feature = "conversations")]
#[async_trait::async_trait]
impl<T: super::Conversations> Conversations for T {
async fn create_conversation(
&self,
req: crate::model::CreateConversationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Conversation>> {
T::create_conversation(self, req, options).await
}
async fn list_conversations(
&self,
req: crate::model::ListConversationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::ListConversationsResponse>> {
T::list_conversations(self, req, options).await
}
async fn get_conversation(
&self,
req: crate::model::GetConversationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Conversation>> {
T::get_conversation(self, req, options).await
}
async fn complete_conversation(
&self,
req: crate::model::CompleteConversationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Conversation>> {
T::complete_conversation(self, req, options).await
}
async fn ingest_context_references(
&self,
req: crate::model::IngestContextReferencesRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::IngestContextReferencesResponse>> {
T::ingest_context_references(self, req, options).await
}
async fn list_messages(
&self,
req: crate::model::ListMessagesRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::ListMessagesResponse>> {
T::list_messages(self, req, options).await
}
async fn suggest_conversation_summary(
&self,
req: crate::model::SuggestConversationSummaryRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::SuggestConversationSummaryResponse>> {
T::suggest_conversation_summary(self, req, options).await
}
async fn generate_stateless_summary(
&self,
req: crate::model::GenerateStatelessSummaryRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::GenerateStatelessSummaryResponse>> {
T::generate_stateless_summary(self, req, options).await
}
async fn generate_stateless_suggestion(
&self,
req: crate::model::GenerateStatelessSuggestionRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::GenerateStatelessSuggestionResponse>> {
T::generate_stateless_suggestion(self, req, options).await
}
async fn search_knowledge(
&self,
req: crate::model::SearchKnowledgeRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::SearchKnowledgeResponse>> {
T::search_knowledge(self, req, options).await
}
async fn generate_suggestions(
&self,
req: crate::model::GenerateSuggestionsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::GenerateSuggestionsResponse>> {
T::generate_suggestions(self, req, options).await
}
async fn list_locations(
&self,
req: google_cloud_location::model::ListLocationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::ListLocationsResponse>> {
T::list_locations(self, req, options).await
}
async fn get_location(
&self,
req: google_cloud_location::model::GetLocationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::Location>> {
T::get_location(self, req, options).await
}
async fn list_operations(
&self,
req: google_cloud_longrunning::model::ListOperationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::ListOperationsResponse>>
{
T::list_operations(self, req, options).await
}
async fn get_operation(
&self,
req: google_cloud_longrunning::model::GetOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>> {
T::get_operation(self, req, options).await
}
async fn cancel_operation(
&self,
req: google_cloud_longrunning::model::CancelOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>> {
T::cancel_operation(self, req, options).await
}
}
#[cfg(feature = "conversation-datasets")]
#[async_trait::async_trait]
pub trait ConversationDatasets: std::fmt::Debug + Send + Sync {
async fn create_conversation_dataset(
&self,
req: crate::model::CreateConversationDatasetRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>;
async fn get_conversation_dataset(
&self,
req: crate::model::GetConversationDatasetRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::ConversationDataset>>;
async fn list_conversation_datasets(
&self,
req: crate::model::ListConversationDatasetsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::ListConversationDatasetsResponse>>;
async fn delete_conversation_dataset(
&self,
req: crate::model::DeleteConversationDatasetRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>;
async fn import_conversation_data(
&self,
req: crate::model::ImportConversationDataRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>;
async fn list_locations(
&self,
req: google_cloud_location::model::ListLocationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::ListLocationsResponse>>;
async fn get_location(
&self,
req: google_cloud_location::model::GetLocationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::Location>>;
async fn list_operations(
&self,
req: google_cloud_longrunning::model::ListOperationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::ListOperationsResponse>>;
async fn get_operation(
&self,
req: google_cloud_longrunning::model::GetOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>;
async fn cancel_operation(
&self,
req: google_cloud_longrunning::model::CancelOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>>;
fn get_polling_error_policy(
&self,
options: &crate::RequestOptions,
) -> std::sync::Arc<dyn google_cloud_gax::polling_error_policy::PollingErrorPolicy>;
fn get_polling_backoff_policy(
&self,
options: &crate::RequestOptions,
) -> std::sync::Arc<dyn google_cloud_gax::polling_backoff_policy::PollingBackoffPolicy>;
}
#[cfg(feature = "conversation-datasets")]
#[async_trait::async_trait]
impl<T: super::ConversationDatasets> ConversationDatasets for T {
async fn create_conversation_dataset(
&self,
req: crate::model::CreateConversationDatasetRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>> {
T::create_conversation_dataset(self, req, options).await
}
async fn get_conversation_dataset(
&self,
req: crate::model::GetConversationDatasetRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::ConversationDataset>> {
T::get_conversation_dataset(self, req, options).await
}
async fn list_conversation_datasets(
&self,
req: crate::model::ListConversationDatasetsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::ListConversationDatasetsResponse>> {
T::list_conversation_datasets(self, req, options).await
}
async fn delete_conversation_dataset(
&self,
req: crate::model::DeleteConversationDatasetRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>> {
T::delete_conversation_dataset(self, req, options).await
}
async fn import_conversation_data(
&self,
req: crate::model::ImportConversationDataRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>> {
T::import_conversation_data(self, req, options).await
}
async fn list_locations(
&self,
req: google_cloud_location::model::ListLocationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::ListLocationsResponse>> {
T::list_locations(self, req, options).await
}
async fn get_location(
&self,
req: google_cloud_location::model::GetLocationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::Location>> {
T::get_location(self, req, options).await
}
async fn list_operations(
&self,
req: google_cloud_longrunning::model::ListOperationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::ListOperationsResponse>>
{
T::list_operations(self, req, options).await
}
async fn get_operation(
&self,
req: google_cloud_longrunning::model::GetOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>> {
T::get_operation(self, req, options).await
}
async fn cancel_operation(
&self,
req: google_cloud_longrunning::model::CancelOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>> {
T::cancel_operation(self, req, options).await
}
fn get_polling_error_policy(
&self,
options: &crate::RequestOptions,
) -> std::sync::Arc<dyn google_cloud_gax::polling_error_policy::PollingErrorPolicy> {
T::get_polling_error_policy(self, options)
}
fn get_polling_backoff_policy(
&self,
options: &crate::RequestOptions,
) -> std::sync::Arc<dyn google_cloud_gax::polling_backoff_policy::PollingBackoffPolicy> {
T::get_polling_backoff_policy(self, options)
}
}
#[cfg(feature = "conversation-models")]
#[async_trait::async_trait]
pub trait ConversationModels: std::fmt::Debug + Send + Sync {
async fn create_conversation_model(
&self,
req: crate::model::CreateConversationModelRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>;
async fn get_conversation_model(
&self,
req: crate::model::GetConversationModelRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::ConversationModel>>;
async fn list_conversation_models(
&self,
req: crate::model::ListConversationModelsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::ListConversationModelsResponse>>;
async fn delete_conversation_model(
&self,
req: crate::model::DeleteConversationModelRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>;
async fn deploy_conversation_model(
&self,
req: crate::model::DeployConversationModelRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>;
async fn undeploy_conversation_model(
&self,
req: crate::model::UndeployConversationModelRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>;
async fn get_conversation_model_evaluation(
&self,
req: crate::model::GetConversationModelEvaluationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::ConversationModelEvaluation>>;
async fn list_conversation_model_evaluations(
&self,
req: crate::model::ListConversationModelEvaluationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::ListConversationModelEvaluationsResponse>>;
async fn create_conversation_model_evaluation(
&self,
req: crate::model::CreateConversationModelEvaluationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>;
async fn list_locations(
&self,
req: google_cloud_location::model::ListLocationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::ListLocationsResponse>>;
async fn get_location(
&self,
req: google_cloud_location::model::GetLocationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::Location>>;
async fn list_operations(
&self,
req: google_cloud_longrunning::model::ListOperationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::ListOperationsResponse>>;
async fn get_operation(
&self,
req: google_cloud_longrunning::model::GetOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>;
async fn cancel_operation(
&self,
req: google_cloud_longrunning::model::CancelOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>>;
fn get_polling_error_policy(
&self,
options: &crate::RequestOptions,
) -> std::sync::Arc<dyn google_cloud_gax::polling_error_policy::PollingErrorPolicy>;
fn get_polling_backoff_policy(
&self,
options: &crate::RequestOptions,
) -> std::sync::Arc<dyn google_cloud_gax::polling_backoff_policy::PollingBackoffPolicy>;
}
#[cfg(feature = "conversation-models")]
#[async_trait::async_trait]
impl<T: super::ConversationModels> ConversationModels for T {
async fn create_conversation_model(
&self,
req: crate::model::CreateConversationModelRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>> {
T::create_conversation_model(self, req, options).await
}
async fn get_conversation_model(
&self,
req: crate::model::GetConversationModelRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::ConversationModel>> {
T::get_conversation_model(self, req, options).await
}
async fn list_conversation_models(
&self,
req: crate::model::ListConversationModelsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::ListConversationModelsResponse>> {
T::list_conversation_models(self, req, options).await
}
async fn delete_conversation_model(
&self,
req: crate::model::DeleteConversationModelRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>> {
T::delete_conversation_model(self, req, options).await
}
async fn deploy_conversation_model(
&self,
req: crate::model::DeployConversationModelRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>> {
T::deploy_conversation_model(self, req, options).await
}
async fn undeploy_conversation_model(
&self,
req: crate::model::UndeployConversationModelRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>> {
T::undeploy_conversation_model(self, req, options).await
}
async fn get_conversation_model_evaluation(
&self,
req: crate::model::GetConversationModelEvaluationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::ConversationModelEvaluation>> {
T::get_conversation_model_evaluation(self, req, options).await
}
async fn list_conversation_model_evaluations(
&self,
req: crate::model::ListConversationModelEvaluationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::ListConversationModelEvaluationsResponse>>
{
T::list_conversation_model_evaluations(self, req, options).await
}
async fn create_conversation_model_evaluation(
&self,
req: crate::model::CreateConversationModelEvaluationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>> {
T::create_conversation_model_evaluation(self, req, options).await
}
async fn list_locations(
&self,
req: google_cloud_location::model::ListLocationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::ListLocationsResponse>> {
T::list_locations(self, req, options).await
}
async fn get_location(
&self,
req: google_cloud_location::model::GetLocationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::Location>> {
T::get_location(self, req, options).await
}
async fn list_operations(
&self,
req: google_cloud_longrunning::model::ListOperationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::ListOperationsResponse>>
{
T::list_operations(self, req, options).await
}
async fn get_operation(
&self,
req: google_cloud_longrunning::model::GetOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>> {
T::get_operation(self, req, options).await
}
async fn cancel_operation(
&self,
req: google_cloud_longrunning::model::CancelOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>> {
T::cancel_operation(self, req, options).await
}
fn get_polling_error_policy(
&self,
options: &crate::RequestOptions,
) -> std::sync::Arc<dyn google_cloud_gax::polling_error_policy::PollingErrorPolicy> {
T::get_polling_error_policy(self, options)
}
fn get_polling_backoff_policy(
&self,
options: &crate::RequestOptions,
) -> std::sync::Arc<dyn google_cloud_gax::polling_backoff_policy::PollingBackoffPolicy> {
T::get_polling_backoff_policy(self, options)
}
}
#[cfg(feature = "conversation-profiles")]
#[async_trait::async_trait]
pub trait ConversationProfiles: std::fmt::Debug + Send + Sync {
async fn list_conversation_profiles(
&self,
req: crate::model::ListConversationProfilesRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::ListConversationProfilesResponse>>;
async fn get_conversation_profile(
&self,
req: crate::model::GetConversationProfileRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::ConversationProfile>>;
async fn create_conversation_profile(
&self,
req: crate::model::CreateConversationProfileRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::ConversationProfile>>;
async fn update_conversation_profile(
&self,
req: crate::model::UpdateConversationProfileRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::ConversationProfile>>;
async fn delete_conversation_profile(
&self,
req: crate::model::DeleteConversationProfileRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>>;
async fn set_suggestion_feature_config(
&self,
req: crate::model::SetSuggestionFeatureConfigRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>;
async fn clear_suggestion_feature_config(
&self,
req: crate::model::ClearSuggestionFeatureConfigRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>;
async fn list_locations(
&self,
req: google_cloud_location::model::ListLocationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::ListLocationsResponse>>;
async fn get_location(
&self,
req: google_cloud_location::model::GetLocationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::Location>>;
async fn list_operations(
&self,
req: google_cloud_longrunning::model::ListOperationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::ListOperationsResponse>>;
async fn get_operation(
&self,
req: google_cloud_longrunning::model::GetOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>;
async fn cancel_operation(
&self,
req: google_cloud_longrunning::model::CancelOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>>;
fn get_polling_error_policy(
&self,
options: &crate::RequestOptions,
) -> std::sync::Arc<dyn google_cloud_gax::polling_error_policy::PollingErrorPolicy>;
fn get_polling_backoff_policy(
&self,
options: &crate::RequestOptions,
) -> std::sync::Arc<dyn google_cloud_gax::polling_backoff_policy::PollingBackoffPolicy>;
}
#[cfg(feature = "conversation-profiles")]
#[async_trait::async_trait]
impl<T: super::ConversationProfiles> ConversationProfiles for T {
async fn list_conversation_profiles(
&self,
req: crate::model::ListConversationProfilesRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::ListConversationProfilesResponse>> {
T::list_conversation_profiles(self, req, options).await
}
async fn get_conversation_profile(
&self,
req: crate::model::GetConversationProfileRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::ConversationProfile>> {
T::get_conversation_profile(self, req, options).await
}
async fn create_conversation_profile(
&self,
req: crate::model::CreateConversationProfileRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::ConversationProfile>> {
T::create_conversation_profile(self, req, options).await
}
async fn update_conversation_profile(
&self,
req: crate::model::UpdateConversationProfileRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::ConversationProfile>> {
T::update_conversation_profile(self, req, options).await
}
async fn delete_conversation_profile(
&self,
req: crate::model::DeleteConversationProfileRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>> {
T::delete_conversation_profile(self, req, options).await
}
async fn set_suggestion_feature_config(
&self,
req: crate::model::SetSuggestionFeatureConfigRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>> {
T::set_suggestion_feature_config(self, req, options).await
}
async fn clear_suggestion_feature_config(
&self,
req: crate::model::ClearSuggestionFeatureConfigRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>> {
T::clear_suggestion_feature_config(self, req, options).await
}
async fn list_locations(
&self,
req: google_cloud_location::model::ListLocationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::ListLocationsResponse>> {
T::list_locations(self, req, options).await
}
async fn get_location(
&self,
req: google_cloud_location::model::GetLocationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::Location>> {
T::get_location(self, req, options).await
}
async fn list_operations(
&self,
req: google_cloud_longrunning::model::ListOperationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::ListOperationsResponse>>
{
T::list_operations(self, req, options).await
}
async fn get_operation(
&self,
req: google_cloud_longrunning::model::GetOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>> {
T::get_operation(self, req, options).await
}
async fn cancel_operation(
&self,
req: google_cloud_longrunning::model::CancelOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>> {
T::cancel_operation(self, req, options).await
}
fn get_polling_error_policy(
&self,
options: &crate::RequestOptions,
) -> std::sync::Arc<dyn google_cloud_gax::polling_error_policy::PollingErrorPolicy> {
T::get_polling_error_policy(self, options)
}
fn get_polling_backoff_policy(
&self,
options: &crate::RequestOptions,
) -> std::sync::Arc<dyn google_cloud_gax::polling_backoff_policy::PollingBackoffPolicy> {
T::get_polling_backoff_policy(self, options)
}
}
#[cfg(feature = "documents")]
#[async_trait::async_trait]
pub trait Documents: std::fmt::Debug + Send + Sync {
async fn list_documents(
&self,
req: crate::model::ListDocumentsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::ListDocumentsResponse>>;
async fn get_document(
&self,
req: crate::model::GetDocumentRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Document>>;
async fn create_document(
&self,
req: crate::model::CreateDocumentRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>;
async fn import_documents(
&self,
req: crate::model::ImportDocumentsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>;
async fn delete_document(
&self,
req: crate::model::DeleteDocumentRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>;
async fn update_document(
&self,
req: crate::model::UpdateDocumentRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>;
async fn reload_document(
&self,
req: crate::model::ReloadDocumentRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>;
async fn export_document(
&self,
req: crate::model::ExportDocumentRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>;
async fn list_locations(
&self,
req: google_cloud_location::model::ListLocationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::ListLocationsResponse>>;
async fn get_location(
&self,
req: google_cloud_location::model::GetLocationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::Location>>;
async fn list_operations(
&self,
req: google_cloud_longrunning::model::ListOperationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::ListOperationsResponse>>;
async fn get_operation(
&self,
req: google_cloud_longrunning::model::GetOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>;
async fn cancel_operation(
&self,
req: google_cloud_longrunning::model::CancelOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>>;
fn get_polling_error_policy(
&self,
options: &crate::RequestOptions,
) -> std::sync::Arc<dyn google_cloud_gax::polling_error_policy::PollingErrorPolicy>;
fn get_polling_backoff_policy(
&self,
options: &crate::RequestOptions,
) -> std::sync::Arc<dyn google_cloud_gax::polling_backoff_policy::PollingBackoffPolicy>;
}
#[cfg(feature = "documents")]
#[async_trait::async_trait]
impl<T: super::Documents> Documents for T {
async fn list_documents(
&self,
req: crate::model::ListDocumentsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::ListDocumentsResponse>> {
T::list_documents(self, req, options).await
}
async fn get_document(
&self,
req: crate::model::GetDocumentRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Document>> {
T::get_document(self, req, options).await
}
async fn create_document(
&self,
req: crate::model::CreateDocumentRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>> {
T::create_document(self, req, options).await
}
async fn import_documents(
&self,
req: crate::model::ImportDocumentsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>> {
T::import_documents(self, req, options).await
}
async fn delete_document(
&self,
req: crate::model::DeleteDocumentRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>> {
T::delete_document(self, req, options).await
}
async fn update_document(
&self,
req: crate::model::UpdateDocumentRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>> {
T::update_document(self, req, options).await
}
async fn reload_document(
&self,
req: crate::model::ReloadDocumentRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>> {
T::reload_document(self, req, options).await
}
async fn export_document(
&self,
req: crate::model::ExportDocumentRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>> {
T::export_document(self, req, options).await
}
async fn list_locations(
&self,
req: google_cloud_location::model::ListLocationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::ListLocationsResponse>> {
T::list_locations(self, req, options).await
}
async fn get_location(
&self,
req: google_cloud_location::model::GetLocationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::Location>> {
T::get_location(self, req, options).await
}
async fn list_operations(
&self,
req: google_cloud_longrunning::model::ListOperationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::ListOperationsResponse>>
{
T::list_operations(self, req, options).await
}
async fn get_operation(
&self,
req: google_cloud_longrunning::model::GetOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>> {
T::get_operation(self, req, options).await
}
async fn cancel_operation(
&self,
req: google_cloud_longrunning::model::CancelOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>> {
T::cancel_operation(self, req, options).await
}
fn get_polling_error_policy(
&self,
options: &crate::RequestOptions,
) -> std::sync::Arc<dyn google_cloud_gax::polling_error_policy::PollingErrorPolicy> {
T::get_polling_error_policy(self, options)
}
fn get_polling_backoff_policy(
&self,
options: &crate::RequestOptions,
) -> std::sync::Arc<dyn google_cloud_gax::polling_backoff_policy::PollingBackoffPolicy> {
T::get_polling_backoff_policy(self, options)
}
}
#[cfg(feature = "encryption-spec-service")]
#[async_trait::async_trait]
pub trait EncryptionSpecService: std::fmt::Debug + Send + Sync {
async fn get_encryption_spec(
&self,
req: crate::model::GetEncryptionSpecRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::EncryptionSpec>>;
async fn initialize_encryption_spec(
&self,
req: crate::model::InitializeEncryptionSpecRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>;
async fn list_locations(
&self,
req: google_cloud_location::model::ListLocationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::ListLocationsResponse>>;
async fn get_location(
&self,
req: google_cloud_location::model::GetLocationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::Location>>;
async fn list_operations(
&self,
req: google_cloud_longrunning::model::ListOperationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::ListOperationsResponse>>;
async fn get_operation(
&self,
req: google_cloud_longrunning::model::GetOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>;
async fn cancel_operation(
&self,
req: google_cloud_longrunning::model::CancelOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>>;
fn get_polling_error_policy(
&self,
options: &crate::RequestOptions,
) -> std::sync::Arc<dyn google_cloud_gax::polling_error_policy::PollingErrorPolicy>;
fn get_polling_backoff_policy(
&self,
options: &crate::RequestOptions,
) -> std::sync::Arc<dyn google_cloud_gax::polling_backoff_policy::PollingBackoffPolicy>;
}
#[cfg(feature = "encryption-spec-service")]
#[async_trait::async_trait]
impl<T: super::EncryptionSpecService> EncryptionSpecService for T {
async fn get_encryption_spec(
&self,
req: crate::model::GetEncryptionSpecRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::EncryptionSpec>> {
T::get_encryption_spec(self, req, options).await
}
async fn initialize_encryption_spec(
&self,
req: crate::model::InitializeEncryptionSpecRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>> {
T::initialize_encryption_spec(self, req, options).await
}
async fn list_locations(
&self,
req: google_cloud_location::model::ListLocationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::ListLocationsResponse>> {
T::list_locations(self, req, options).await
}
async fn get_location(
&self,
req: google_cloud_location::model::GetLocationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::Location>> {
T::get_location(self, req, options).await
}
async fn list_operations(
&self,
req: google_cloud_longrunning::model::ListOperationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::ListOperationsResponse>>
{
T::list_operations(self, req, options).await
}
async fn get_operation(
&self,
req: google_cloud_longrunning::model::GetOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>> {
T::get_operation(self, req, options).await
}
async fn cancel_operation(
&self,
req: google_cloud_longrunning::model::CancelOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>> {
T::cancel_operation(self, req, options).await
}
fn get_polling_error_policy(
&self,
options: &crate::RequestOptions,
) -> std::sync::Arc<dyn google_cloud_gax::polling_error_policy::PollingErrorPolicy> {
T::get_polling_error_policy(self, options)
}
fn get_polling_backoff_policy(
&self,
options: &crate::RequestOptions,
) -> std::sync::Arc<dyn google_cloud_gax::polling_backoff_policy::PollingBackoffPolicy> {
T::get_polling_backoff_policy(self, options)
}
}
#[cfg(feature = "entity-types")]
#[async_trait::async_trait]
pub trait EntityTypes: std::fmt::Debug + Send + Sync {
async fn list_entity_types(
&self,
req: crate::model::ListEntityTypesRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::ListEntityTypesResponse>>;
async fn get_entity_type(
&self,
req: crate::model::GetEntityTypeRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::EntityType>>;
async fn create_entity_type(
&self,
req: crate::model::CreateEntityTypeRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::EntityType>>;
async fn update_entity_type(
&self,
req: crate::model::UpdateEntityTypeRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::EntityType>>;
async fn delete_entity_type(
&self,
req: crate::model::DeleteEntityTypeRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>>;
async fn batch_update_entity_types(
&self,
req: crate::model::BatchUpdateEntityTypesRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>;
async fn batch_delete_entity_types(
&self,
req: crate::model::BatchDeleteEntityTypesRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>;
async fn batch_create_entities(
&self,
req: crate::model::BatchCreateEntitiesRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>;
async fn batch_update_entities(
&self,
req: crate::model::BatchUpdateEntitiesRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>;
async fn batch_delete_entities(
&self,
req: crate::model::BatchDeleteEntitiesRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>;
async fn list_locations(
&self,
req: google_cloud_location::model::ListLocationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::ListLocationsResponse>>;
async fn get_location(
&self,
req: google_cloud_location::model::GetLocationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::Location>>;
async fn list_operations(
&self,
req: google_cloud_longrunning::model::ListOperationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::ListOperationsResponse>>;
async fn get_operation(
&self,
req: google_cloud_longrunning::model::GetOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>;
async fn cancel_operation(
&self,
req: google_cloud_longrunning::model::CancelOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>>;
fn get_polling_error_policy(
&self,
options: &crate::RequestOptions,
) -> std::sync::Arc<dyn google_cloud_gax::polling_error_policy::PollingErrorPolicy>;
fn get_polling_backoff_policy(
&self,
options: &crate::RequestOptions,
) -> std::sync::Arc<dyn google_cloud_gax::polling_backoff_policy::PollingBackoffPolicy>;
}
#[cfg(feature = "entity-types")]
#[async_trait::async_trait]
impl<T: super::EntityTypes> EntityTypes for T {
async fn list_entity_types(
&self,
req: crate::model::ListEntityTypesRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::ListEntityTypesResponse>> {
T::list_entity_types(self, req, options).await
}
async fn get_entity_type(
&self,
req: crate::model::GetEntityTypeRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::EntityType>> {
T::get_entity_type(self, req, options).await
}
async fn create_entity_type(
&self,
req: crate::model::CreateEntityTypeRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::EntityType>> {
T::create_entity_type(self, req, options).await
}
async fn update_entity_type(
&self,
req: crate::model::UpdateEntityTypeRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::EntityType>> {
T::update_entity_type(self, req, options).await
}
async fn delete_entity_type(
&self,
req: crate::model::DeleteEntityTypeRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>> {
T::delete_entity_type(self, req, options).await
}
async fn batch_update_entity_types(
&self,
req: crate::model::BatchUpdateEntityTypesRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>> {
T::batch_update_entity_types(self, req, options).await
}
async fn batch_delete_entity_types(
&self,
req: crate::model::BatchDeleteEntityTypesRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>> {
T::batch_delete_entity_types(self, req, options).await
}
async fn batch_create_entities(
&self,
req: crate::model::BatchCreateEntitiesRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>> {
T::batch_create_entities(self, req, options).await
}
async fn batch_update_entities(
&self,
req: crate::model::BatchUpdateEntitiesRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>> {
T::batch_update_entities(self, req, options).await
}
async fn batch_delete_entities(
&self,
req: crate::model::BatchDeleteEntitiesRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>> {
T::batch_delete_entities(self, req, options).await
}
async fn list_locations(
&self,
req: google_cloud_location::model::ListLocationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::ListLocationsResponse>> {
T::list_locations(self, req, options).await
}
async fn get_location(
&self,
req: google_cloud_location::model::GetLocationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::Location>> {
T::get_location(self, req, options).await
}
async fn list_operations(
&self,
req: google_cloud_longrunning::model::ListOperationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::ListOperationsResponse>>
{
T::list_operations(self, req, options).await
}
async fn get_operation(
&self,
req: google_cloud_longrunning::model::GetOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>> {
T::get_operation(self, req, options).await
}
async fn cancel_operation(
&self,
req: google_cloud_longrunning::model::CancelOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>> {
T::cancel_operation(self, req, options).await
}
fn get_polling_error_policy(
&self,
options: &crate::RequestOptions,
) -> std::sync::Arc<dyn google_cloud_gax::polling_error_policy::PollingErrorPolicy> {
T::get_polling_error_policy(self, options)
}
fn get_polling_backoff_policy(
&self,
options: &crate::RequestOptions,
) -> std::sync::Arc<dyn google_cloud_gax::polling_backoff_policy::PollingBackoffPolicy> {
T::get_polling_backoff_policy(self, options)
}
}
#[cfg(feature = "environments")]
#[async_trait::async_trait]
pub trait Environments: std::fmt::Debug + Send + Sync {
async fn list_environments(
&self,
req: crate::model::ListEnvironmentsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::ListEnvironmentsResponse>>;
async fn get_environment(
&self,
req: crate::model::GetEnvironmentRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Environment>>;
async fn create_environment(
&self,
req: crate::model::CreateEnvironmentRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Environment>>;
async fn update_environment(
&self,
req: crate::model::UpdateEnvironmentRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Environment>>;
async fn delete_environment(
&self,
req: crate::model::DeleteEnvironmentRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>>;
async fn get_environment_history(
&self,
req: crate::model::GetEnvironmentHistoryRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::EnvironmentHistory>>;
async fn list_locations(
&self,
req: google_cloud_location::model::ListLocationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::ListLocationsResponse>>;
async fn get_location(
&self,
req: google_cloud_location::model::GetLocationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::Location>>;
async fn list_operations(
&self,
req: google_cloud_longrunning::model::ListOperationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::ListOperationsResponse>>;
async fn get_operation(
&self,
req: google_cloud_longrunning::model::GetOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>;
async fn cancel_operation(
&self,
req: google_cloud_longrunning::model::CancelOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>>;
}
#[cfg(feature = "environments")]
#[async_trait::async_trait]
impl<T: super::Environments> Environments for T {
async fn list_environments(
&self,
req: crate::model::ListEnvironmentsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::ListEnvironmentsResponse>> {
T::list_environments(self, req, options).await
}
async fn get_environment(
&self,
req: crate::model::GetEnvironmentRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Environment>> {
T::get_environment(self, req, options).await
}
async fn create_environment(
&self,
req: crate::model::CreateEnvironmentRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Environment>> {
T::create_environment(self, req, options).await
}
async fn update_environment(
&self,
req: crate::model::UpdateEnvironmentRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Environment>> {
T::update_environment(self, req, options).await
}
async fn delete_environment(
&self,
req: crate::model::DeleteEnvironmentRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>> {
T::delete_environment(self, req, options).await
}
async fn get_environment_history(
&self,
req: crate::model::GetEnvironmentHistoryRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::EnvironmentHistory>> {
T::get_environment_history(self, req, options).await
}
async fn list_locations(
&self,
req: google_cloud_location::model::ListLocationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::ListLocationsResponse>> {
T::list_locations(self, req, options).await
}
async fn get_location(
&self,
req: google_cloud_location::model::GetLocationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::Location>> {
T::get_location(self, req, options).await
}
async fn list_operations(
&self,
req: google_cloud_longrunning::model::ListOperationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::ListOperationsResponse>>
{
T::list_operations(self, req, options).await
}
async fn get_operation(
&self,
req: google_cloud_longrunning::model::GetOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>> {
T::get_operation(self, req, options).await
}
async fn cancel_operation(
&self,
req: google_cloud_longrunning::model::CancelOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>> {
T::cancel_operation(self, req, options).await
}
}
#[cfg(feature = "fulfillments")]
#[async_trait::async_trait]
pub trait Fulfillments: std::fmt::Debug + Send + Sync {
async fn get_fulfillment(
&self,
req: crate::model::GetFulfillmentRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Fulfillment>>;
async fn update_fulfillment(
&self,
req: crate::model::UpdateFulfillmentRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Fulfillment>>;
async fn list_locations(
&self,
req: google_cloud_location::model::ListLocationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::ListLocationsResponse>>;
async fn get_location(
&self,
req: google_cloud_location::model::GetLocationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::Location>>;
async fn list_operations(
&self,
req: google_cloud_longrunning::model::ListOperationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::ListOperationsResponse>>;
async fn get_operation(
&self,
req: google_cloud_longrunning::model::GetOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>;
async fn cancel_operation(
&self,
req: google_cloud_longrunning::model::CancelOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>>;
}
#[cfg(feature = "fulfillments")]
#[async_trait::async_trait]
impl<T: super::Fulfillments> Fulfillments for T {
async fn get_fulfillment(
&self,
req: crate::model::GetFulfillmentRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Fulfillment>> {
T::get_fulfillment(self, req, options).await
}
async fn update_fulfillment(
&self,
req: crate::model::UpdateFulfillmentRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Fulfillment>> {
T::update_fulfillment(self, req, options).await
}
async fn list_locations(
&self,
req: google_cloud_location::model::ListLocationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::ListLocationsResponse>> {
T::list_locations(self, req, options).await
}
async fn get_location(
&self,
req: google_cloud_location::model::GetLocationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::Location>> {
T::get_location(self, req, options).await
}
async fn list_operations(
&self,
req: google_cloud_longrunning::model::ListOperationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::ListOperationsResponse>>
{
T::list_operations(self, req, options).await
}
async fn get_operation(
&self,
req: google_cloud_longrunning::model::GetOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>> {
T::get_operation(self, req, options).await
}
async fn cancel_operation(
&self,
req: google_cloud_longrunning::model::CancelOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>> {
T::cancel_operation(self, req, options).await
}
}
#[cfg(feature = "generators")]
#[async_trait::async_trait]
pub trait Generators: std::fmt::Debug + Send + Sync {
async fn create_generator(
&self,
req: crate::model::CreateGeneratorRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Generator>>;
async fn get_generator(
&self,
req: crate::model::GetGeneratorRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Generator>>;
async fn list_generators(
&self,
req: crate::model::ListGeneratorsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::ListGeneratorsResponse>>;
async fn delete_generator(
&self,
req: crate::model::DeleteGeneratorRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>>;
async fn update_generator(
&self,
req: crate::model::UpdateGeneratorRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Generator>>;
async fn list_locations(
&self,
req: google_cloud_location::model::ListLocationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::ListLocationsResponse>>;
async fn get_location(
&self,
req: google_cloud_location::model::GetLocationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::Location>>;
async fn list_operations(
&self,
req: google_cloud_longrunning::model::ListOperationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::ListOperationsResponse>>;
async fn get_operation(
&self,
req: google_cloud_longrunning::model::GetOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>;
async fn cancel_operation(
&self,
req: google_cloud_longrunning::model::CancelOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>>;
}
#[cfg(feature = "generators")]
#[async_trait::async_trait]
impl<T: super::Generators> Generators for T {
async fn create_generator(
&self,
req: crate::model::CreateGeneratorRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Generator>> {
T::create_generator(self, req, options).await
}
async fn get_generator(
&self,
req: crate::model::GetGeneratorRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Generator>> {
T::get_generator(self, req, options).await
}
async fn list_generators(
&self,
req: crate::model::ListGeneratorsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::ListGeneratorsResponse>> {
T::list_generators(self, req, options).await
}
async fn delete_generator(
&self,
req: crate::model::DeleteGeneratorRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>> {
T::delete_generator(self, req, options).await
}
async fn update_generator(
&self,
req: crate::model::UpdateGeneratorRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Generator>> {
T::update_generator(self, req, options).await
}
async fn list_locations(
&self,
req: google_cloud_location::model::ListLocationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::ListLocationsResponse>> {
T::list_locations(self, req, options).await
}
async fn get_location(
&self,
req: google_cloud_location::model::GetLocationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::Location>> {
T::get_location(self, req, options).await
}
async fn list_operations(
&self,
req: google_cloud_longrunning::model::ListOperationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::ListOperationsResponse>>
{
T::list_operations(self, req, options).await
}
async fn get_operation(
&self,
req: google_cloud_longrunning::model::GetOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>> {
T::get_operation(self, req, options).await
}
async fn cancel_operation(
&self,
req: google_cloud_longrunning::model::CancelOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>> {
T::cancel_operation(self, req, options).await
}
}
#[cfg(feature = "generator-evaluations")]
#[async_trait::async_trait]
pub trait GeneratorEvaluations: std::fmt::Debug + Send + Sync {
async fn create_generator_evaluation(
&self,
req: crate::model::CreateGeneratorEvaluationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>;
async fn get_generator_evaluation(
&self,
req: crate::model::GetGeneratorEvaluationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::GeneratorEvaluation>>;
async fn list_generator_evaluations(
&self,
req: crate::model::ListGeneratorEvaluationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::ListGeneratorEvaluationsResponse>>;
async fn delete_generator_evaluation(
&self,
req: crate::model::DeleteGeneratorEvaluationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>>;
async fn list_locations(
&self,
req: google_cloud_location::model::ListLocationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::ListLocationsResponse>>;
async fn get_location(
&self,
req: google_cloud_location::model::GetLocationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::Location>>;
async fn list_operations(
&self,
req: google_cloud_longrunning::model::ListOperationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::ListOperationsResponse>>;
async fn get_operation(
&self,
req: google_cloud_longrunning::model::GetOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>;
async fn cancel_operation(
&self,
req: google_cloud_longrunning::model::CancelOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>>;
fn get_polling_error_policy(
&self,
options: &crate::RequestOptions,
) -> std::sync::Arc<dyn google_cloud_gax::polling_error_policy::PollingErrorPolicy>;
fn get_polling_backoff_policy(
&self,
options: &crate::RequestOptions,
) -> std::sync::Arc<dyn google_cloud_gax::polling_backoff_policy::PollingBackoffPolicy>;
}
#[cfg(feature = "generator-evaluations")]
#[async_trait::async_trait]
impl<T: super::GeneratorEvaluations> GeneratorEvaluations for T {
async fn create_generator_evaluation(
&self,
req: crate::model::CreateGeneratorEvaluationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>> {
T::create_generator_evaluation(self, req, options).await
}
async fn get_generator_evaluation(
&self,
req: crate::model::GetGeneratorEvaluationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::GeneratorEvaluation>> {
T::get_generator_evaluation(self, req, options).await
}
async fn list_generator_evaluations(
&self,
req: crate::model::ListGeneratorEvaluationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::ListGeneratorEvaluationsResponse>> {
T::list_generator_evaluations(self, req, options).await
}
async fn delete_generator_evaluation(
&self,
req: crate::model::DeleteGeneratorEvaluationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>> {
T::delete_generator_evaluation(self, req, options).await
}
async fn list_locations(
&self,
req: google_cloud_location::model::ListLocationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::ListLocationsResponse>> {
T::list_locations(self, req, options).await
}
async fn get_location(
&self,
req: google_cloud_location::model::GetLocationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::Location>> {
T::get_location(self, req, options).await
}
async fn list_operations(
&self,
req: google_cloud_longrunning::model::ListOperationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::ListOperationsResponse>>
{
T::list_operations(self, req, options).await
}
async fn get_operation(
&self,
req: google_cloud_longrunning::model::GetOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>> {
T::get_operation(self, req, options).await
}
async fn cancel_operation(
&self,
req: google_cloud_longrunning::model::CancelOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>> {
T::cancel_operation(self, req, options).await
}
fn get_polling_error_policy(
&self,
options: &crate::RequestOptions,
) -> std::sync::Arc<dyn google_cloud_gax::polling_error_policy::PollingErrorPolicy> {
T::get_polling_error_policy(self, options)
}
fn get_polling_backoff_policy(
&self,
options: &crate::RequestOptions,
) -> std::sync::Arc<dyn google_cloud_gax::polling_backoff_policy::PollingBackoffPolicy> {
T::get_polling_backoff_policy(self, options)
}
}
#[cfg(feature = "intents")]
#[async_trait::async_trait]
pub trait Intents: std::fmt::Debug + Send + Sync {
async fn list_intents(
&self,
req: crate::model::ListIntentsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::ListIntentsResponse>>;
async fn get_intent(
&self,
req: crate::model::GetIntentRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Intent>>;
async fn create_intent(
&self,
req: crate::model::CreateIntentRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Intent>>;
async fn update_intent(
&self,
req: crate::model::UpdateIntentRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Intent>>;
async fn delete_intent(
&self,
req: crate::model::DeleteIntentRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>>;
async fn batch_update_intents(
&self,
req: crate::model::BatchUpdateIntentsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>;
async fn batch_delete_intents(
&self,
req: crate::model::BatchDeleteIntentsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>;
async fn list_locations(
&self,
req: google_cloud_location::model::ListLocationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::ListLocationsResponse>>;
async fn get_location(
&self,
req: google_cloud_location::model::GetLocationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::Location>>;
async fn list_operations(
&self,
req: google_cloud_longrunning::model::ListOperationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::ListOperationsResponse>>;
async fn get_operation(
&self,
req: google_cloud_longrunning::model::GetOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>;
async fn cancel_operation(
&self,
req: google_cloud_longrunning::model::CancelOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>>;
fn get_polling_error_policy(
&self,
options: &crate::RequestOptions,
) -> std::sync::Arc<dyn google_cloud_gax::polling_error_policy::PollingErrorPolicy>;
fn get_polling_backoff_policy(
&self,
options: &crate::RequestOptions,
) -> std::sync::Arc<dyn google_cloud_gax::polling_backoff_policy::PollingBackoffPolicy>;
}
#[cfg(feature = "intents")]
#[async_trait::async_trait]
impl<T: super::Intents> Intents for T {
async fn list_intents(
&self,
req: crate::model::ListIntentsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::ListIntentsResponse>> {
T::list_intents(self, req, options).await
}
async fn get_intent(
&self,
req: crate::model::GetIntentRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Intent>> {
T::get_intent(self, req, options).await
}
async fn create_intent(
&self,
req: crate::model::CreateIntentRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Intent>> {
T::create_intent(self, req, options).await
}
async fn update_intent(
&self,
req: crate::model::UpdateIntentRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Intent>> {
T::update_intent(self, req, options).await
}
async fn delete_intent(
&self,
req: crate::model::DeleteIntentRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>> {
T::delete_intent(self, req, options).await
}
async fn batch_update_intents(
&self,
req: crate::model::BatchUpdateIntentsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>> {
T::batch_update_intents(self, req, options).await
}
async fn batch_delete_intents(
&self,
req: crate::model::BatchDeleteIntentsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>> {
T::batch_delete_intents(self, req, options).await
}
async fn list_locations(
&self,
req: google_cloud_location::model::ListLocationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::ListLocationsResponse>> {
T::list_locations(self, req, options).await
}
async fn get_location(
&self,
req: google_cloud_location::model::GetLocationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::Location>> {
T::get_location(self, req, options).await
}
async fn list_operations(
&self,
req: google_cloud_longrunning::model::ListOperationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::ListOperationsResponse>>
{
T::list_operations(self, req, options).await
}
async fn get_operation(
&self,
req: google_cloud_longrunning::model::GetOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>> {
T::get_operation(self, req, options).await
}
async fn cancel_operation(
&self,
req: google_cloud_longrunning::model::CancelOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>> {
T::cancel_operation(self, req, options).await
}
fn get_polling_error_policy(
&self,
options: &crate::RequestOptions,
) -> std::sync::Arc<dyn google_cloud_gax::polling_error_policy::PollingErrorPolicy> {
T::get_polling_error_policy(self, options)
}
fn get_polling_backoff_policy(
&self,
options: &crate::RequestOptions,
) -> std::sync::Arc<dyn google_cloud_gax::polling_backoff_policy::PollingBackoffPolicy> {
T::get_polling_backoff_policy(self, options)
}
}
#[cfg(feature = "knowledge-bases")]
#[async_trait::async_trait]
pub trait KnowledgeBases: std::fmt::Debug + Send + Sync {
async fn list_knowledge_bases(
&self,
req: crate::model::ListKnowledgeBasesRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::ListKnowledgeBasesResponse>>;
async fn get_knowledge_base(
&self,
req: crate::model::GetKnowledgeBaseRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::KnowledgeBase>>;
async fn create_knowledge_base(
&self,
req: crate::model::CreateKnowledgeBaseRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::KnowledgeBase>>;
async fn delete_knowledge_base(
&self,
req: crate::model::DeleteKnowledgeBaseRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>>;
async fn update_knowledge_base(
&self,
req: crate::model::UpdateKnowledgeBaseRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::KnowledgeBase>>;
async fn list_locations(
&self,
req: google_cloud_location::model::ListLocationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::ListLocationsResponse>>;
async fn get_location(
&self,
req: google_cloud_location::model::GetLocationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::Location>>;
async fn list_operations(
&self,
req: google_cloud_longrunning::model::ListOperationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::ListOperationsResponse>>;
async fn get_operation(
&self,
req: google_cloud_longrunning::model::GetOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>;
async fn cancel_operation(
&self,
req: google_cloud_longrunning::model::CancelOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>>;
}
#[cfg(feature = "knowledge-bases")]
#[async_trait::async_trait]
impl<T: super::KnowledgeBases> KnowledgeBases for T {
async fn list_knowledge_bases(
&self,
req: crate::model::ListKnowledgeBasesRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::ListKnowledgeBasesResponse>> {
T::list_knowledge_bases(self, req, options).await
}
async fn get_knowledge_base(
&self,
req: crate::model::GetKnowledgeBaseRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::KnowledgeBase>> {
T::get_knowledge_base(self, req, options).await
}
async fn create_knowledge_base(
&self,
req: crate::model::CreateKnowledgeBaseRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::KnowledgeBase>> {
T::create_knowledge_base(self, req, options).await
}
async fn delete_knowledge_base(
&self,
req: crate::model::DeleteKnowledgeBaseRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>> {
T::delete_knowledge_base(self, req, options).await
}
async fn update_knowledge_base(
&self,
req: crate::model::UpdateKnowledgeBaseRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::KnowledgeBase>> {
T::update_knowledge_base(self, req, options).await
}
async fn list_locations(
&self,
req: google_cloud_location::model::ListLocationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::ListLocationsResponse>> {
T::list_locations(self, req, options).await
}
async fn get_location(
&self,
req: google_cloud_location::model::GetLocationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::Location>> {
T::get_location(self, req, options).await
}
async fn list_operations(
&self,
req: google_cloud_longrunning::model::ListOperationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::ListOperationsResponse>>
{
T::list_operations(self, req, options).await
}
async fn get_operation(
&self,
req: google_cloud_longrunning::model::GetOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>> {
T::get_operation(self, req, options).await
}
async fn cancel_operation(
&self,
req: google_cloud_longrunning::model::CancelOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>> {
T::cancel_operation(self, req, options).await
}
}
#[cfg(feature = "participants")]
#[async_trait::async_trait]
pub trait Participants: std::fmt::Debug + Send + Sync {
async fn create_participant(
&self,
req: crate::model::CreateParticipantRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Participant>>;
async fn get_participant(
&self,
req: crate::model::GetParticipantRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Participant>>;
async fn list_participants(
&self,
req: crate::model::ListParticipantsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::ListParticipantsResponse>>;
async fn update_participant(
&self,
req: crate::model::UpdateParticipantRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Participant>>;
async fn analyze_content(
&self,
req: crate::model::AnalyzeContentRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::AnalyzeContentResponse>>;
async fn suggest_articles(
&self,
req: crate::model::SuggestArticlesRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::SuggestArticlesResponse>>;
async fn suggest_faq_answers(
&self,
req: crate::model::SuggestFaqAnswersRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::SuggestFaqAnswersResponse>>;
async fn suggest_smart_replies(
&self,
req: crate::model::SuggestSmartRepliesRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::SuggestSmartRepliesResponse>>;
async fn suggest_knowledge_assist(
&self,
req: crate::model::SuggestKnowledgeAssistRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::SuggestKnowledgeAssistResponse>>;
async fn list_locations(
&self,
req: google_cloud_location::model::ListLocationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::ListLocationsResponse>>;
async fn get_location(
&self,
req: google_cloud_location::model::GetLocationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::Location>>;
async fn list_operations(
&self,
req: google_cloud_longrunning::model::ListOperationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::ListOperationsResponse>>;
async fn get_operation(
&self,
req: google_cloud_longrunning::model::GetOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>;
async fn cancel_operation(
&self,
req: google_cloud_longrunning::model::CancelOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>>;
}
#[cfg(feature = "participants")]
#[async_trait::async_trait]
impl<T: super::Participants> Participants for T {
async fn create_participant(
&self,
req: crate::model::CreateParticipantRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Participant>> {
T::create_participant(self, req, options).await
}
async fn get_participant(
&self,
req: crate::model::GetParticipantRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Participant>> {
T::get_participant(self, req, options).await
}
async fn list_participants(
&self,
req: crate::model::ListParticipantsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::ListParticipantsResponse>> {
T::list_participants(self, req, options).await
}
async fn update_participant(
&self,
req: crate::model::UpdateParticipantRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Participant>> {
T::update_participant(self, req, options).await
}
async fn analyze_content(
&self,
req: crate::model::AnalyzeContentRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::AnalyzeContentResponse>> {
T::analyze_content(self, req, options).await
}
async fn suggest_articles(
&self,
req: crate::model::SuggestArticlesRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::SuggestArticlesResponse>> {
T::suggest_articles(self, req, options).await
}
async fn suggest_faq_answers(
&self,
req: crate::model::SuggestFaqAnswersRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::SuggestFaqAnswersResponse>> {
T::suggest_faq_answers(self, req, options).await
}
async fn suggest_smart_replies(
&self,
req: crate::model::SuggestSmartRepliesRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::SuggestSmartRepliesResponse>> {
T::suggest_smart_replies(self, req, options).await
}
async fn suggest_knowledge_assist(
&self,
req: crate::model::SuggestKnowledgeAssistRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::SuggestKnowledgeAssistResponse>> {
T::suggest_knowledge_assist(self, req, options).await
}
async fn list_locations(
&self,
req: google_cloud_location::model::ListLocationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::ListLocationsResponse>> {
T::list_locations(self, req, options).await
}
async fn get_location(
&self,
req: google_cloud_location::model::GetLocationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::Location>> {
T::get_location(self, req, options).await
}
async fn list_operations(
&self,
req: google_cloud_longrunning::model::ListOperationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::ListOperationsResponse>>
{
T::list_operations(self, req, options).await
}
async fn get_operation(
&self,
req: google_cloud_longrunning::model::GetOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>> {
T::get_operation(self, req, options).await
}
async fn cancel_operation(
&self,
req: google_cloud_longrunning::model::CancelOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>> {
T::cancel_operation(self, req, options).await
}
}
#[cfg(feature = "sessions")]
#[async_trait::async_trait]
pub trait Sessions: std::fmt::Debug + Send + Sync {
async fn detect_intent(
&self,
req: crate::model::DetectIntentRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::DetectIntentResponse>>;
async fn list_locations(
&self,
req: google_cloud_location::model::ListLocationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::ListLocationsResponse>>;
async fn get_location(
&self,
req: google_cloud_location::model::GetLocationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::Location>>;
async fn list_operations(
&self,
req: google_cloud_longrunning::model::ListOperationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::ListOperationsResponse>>;
async fn get_operation(
&self,
req: google_cloud_longrunning::model::GetOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>;
async fn cancel_operation(
&self,
req: google_cloud_longrunning::model::CancelOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>>;
}
#[cfg(feature = "sessions")]
#[async_trait::async_trait]
impl<T: super::Sessions> Sessions for T {
async fn detect_intent(
&self,
req: crate::model::DetectIntentRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::DetectIntentResponse>> {
T::detect_intent(self, req, options).await
}
async fn list_locations(
&self,
req: google_cloud_location::model::ListLocationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::ListLocationsResponse>> {
T::list_locations(self, req, options).await
}
async fn get_location(
&self,
req: google_cloud_location::model::GetLocationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::Location>> {
T::get_location(self, req, options).await
}
async fn list_operations(
&self,
req: google_cloud_longrunning::model::ListOperationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::ListOperationsResponse>>
{
T::list_operations(self, req, options).await
}
async fn get_operation(
&self,
req: google_cloud_longrunning::model::GetOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>> {
T::get_operation(self, req, options).await
}
async fn cancel_operation(
&self,
req: google_cloud_longrunning::model::CancelOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>> {
T::cancel_operation(self, req, options).await
}
}
#[cfg(feature = "session-entity-types")]
#[async_trait::async_trait]
pub trait SessionEntityTypes: std::fmt::Debug + Send + Sync {
async fn list_session_entity_types(
&self,
req: crate::model::ListSessionEntityTypesRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::ListSessionEntityTypesResponse>>;
async fn get_session_entity_type(
&self,
req: crate::model::GetSessionEntityTypeRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::SessionEntityType>>;
async fn create_session_entity_type(
&self,
req: crate::model::CreateSessionEntityTypeRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::SessionEntityType>>;
async fn update_session_entity_type(
&self,
req: crate::model::UpdateSessionEntityTypeRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::SessionEntityType>>;
async fn delete_session_entity_type(
&self,
req: crate::model::DeleteSessionEntityTypeRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>>;
async fn list_locations(
&self,
req: google_cloud_location::model::ListLocationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::ListLocationsResponse>>;
async fn get_location(
&self,
req: google_cloud_location::model::GetLocationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::Location>>;
async fn list_operations(
&self,
req: google_cloud_longrunning::model::ListOperationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::ListOperationsResponse>>;
async fn get_operation(
&self,
req: google_cloud_longrunning::model::GetOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>;
async fn cancel_operation(
&self,
req: google_cloud_longrunning::model::CancelOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>>;
}
#[cfg(feature = "session-entity-types")]
#[async_trait::async_trait]
impl<T: super::SessionEntityTypes> SessionEntityTypes for T {
async fn list_session_entity_types(
&self,
req: crate::model::ListSessionEntityTypesRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::ListSessionEntityTypesResponse>> {
T::list_session_entity_types(self, req, options).await
}
async fn get_session_entity_type(
&self,
req: crate::model::GetSessionEntityTypeRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::SessionEntityType>> {
T::get_session_entity_type(self, req, options).await
}
async fn create_session_entity_type(
&self,
req: crate::model::CreateSessionEntityTypeRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::SessionEntityType>> {
T::create_session_entity_type(self, req, options).await
}
async fn update_session_entity_type(
&self,
req: crate::model::UpdateSessionEntityTypeRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::SessionEntityType>> {
T::update_session_entity_type(self, req, options).await
}
async fn delete_session_entity_type(
&self,
req: crate::model::DeleteSessionEntityTypeRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>> {
T::delete_session_entity_type(self, req, options).await
}
async fn list_locations(
&self,
req: google_cloud_location::model::ListLocationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::ListLocationsResponse>> {
T::list_locations(self, req, options).await
}
async fn get_location(
&self,
req: google_cloud_location::model::GetLocationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::Location>> {
T::get_location(self, req, options).await
}
async fn list_operations(
&self,
req: google_cloud_longrunning::model::ListOperationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::ListOperationsResponse>>
{
T::list_operations(self, req, options).await
}
async fn get_operation(
&self,
req: google_cloud_longrunning::model::GetOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>> {
T::get_operation(self, req, options).await
}
async fn cancel_operation(
&self,
req: google_cloud_longrunning::model::CancelOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>> {
T::cancel_operation(self, req, options).await
}
}
#[cfg(feature = "sip-trunks")]
#[async_trait::async_trait]
pub trait SipTrunks: std::fmt::Debug + Send + Sync {
async fn create_sip_trunk(
&self,
req: crate::model::CreateSipTrunkRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::SipTrunk>>;
async fn delete_sip_trunk(
&self,
req: crate::model::DeleteSipTrunkRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>>;
async fn list_sip_trunks(
&self,
req: crate::model::ListSipTrunksRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::ListSipTrunksResponse>>;
async fn get_sip_trunk(
&self,
req: crate::model::GetSipTrunkRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::SipTrunk>>;
async fn update_sip_trunk(
&self,
req: crate::model::UpdateSipTrunkRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::SipTrunk>>;
async fn list_locations(
&self,
req: google_cloud_location::model::ListLocationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::ListLocationsResponse>>;
async fn get_location(
&self,
req: google_cloud_location::model::GetLocationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::Location>>;
async fn list_operations(
&self,
req: google_cloud_longrunning::model::ListOperationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::ListOperationsResponse>>;
async fn get_operation(
&self,
req: google_cloud_longrunning::model::GetOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>;
async fn cancel_operation(
&self,
req: google_cloud_longrunning::model::CancelOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>>;
}
#[cfg(feature = "sip-trunks")]
#[async_trait::async_trait]
impl<T: super::SipTrunks> SipTrunks for T {
async fn create_sip_trunk(
&self,
req: crate::model::CreateSipTrunkRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::SipTrunk>> {
T::create_sip_trunk(self, req, options).await
}
async fn delete_sip_trunk(
&self,
req: crate::model::DeleteSipTrunkRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>> {
T::delete_sip_trunk(self, req, options).await
}
async fn list_sip_trunks(
&self,
req: crate::model::ListSipTrunksRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::ListSipTrunksResponse>> {
T::list_sip_trunks(self, req, options).await
}
async fn get_sip_trunk(
&self,
req: crate::model::GetSipTrunkRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::SipTrunk>> {
T::get_sip_trunk(self, req, options).await
}
async fn update_sip_trunk(
&self,
req: crate::model::UpdateSipTrunkRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::SipTrunk>> {
T::update_sip_trunk(self, req, options).await
}
async fn list_locations(
&self,
req: google_cloud_location::model::ListLocationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::ListLocationsResponse>> {
T::list_locations(self, req, options).await
}
async fn get_location(
&self,
req: google_cloud_location::model::GetLocationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::Location>> {
T::get_location(self, req, options).await
}
async fn list_operations(
&self,
req: google_cloud_longrunning::model::ListOperationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::ListOperationsResponse>>
{
T::list_operations(self, req, options).await
}
async fn get_operation(
&self,
req: google_cloud_longrunning::model::GetOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>> {
T::get_operation(self, req, options).await
}
async fn cancel_operation(
&self,
req: google_cloud_longrunning::model::CancelOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>> {
T::cancel_operation(self, req, options).await
}
}
#[cfg(feature = "tools")]
#[async_trait::async_trait]
pub trait Tools: std::fmt::Debug + Send + Sync {
async fn create_tool(
&self,
req: crate::model::CreateToolRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Tool>>;
async fn get_tool(
&self,
req: crate::model::GetToolRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Tool>>;
async fn list_tools(
&self,
req: crate::model::ListToolsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::ListToolsResponse>>;
async fn delete_tool(
&self,
req: crate::model::DeleteToolRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>>;
async fn update_tool(
&self,
req: crate::model::UpdateToolRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Tool>>;
async fn list_locations(
&self,
req: google_cloud_location::model::ListLocationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::ListLocationsResponse>>;
async fn get_location(
&self,
req: google_cloud_location::model::GetLocationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::Location>>;
async fn list_operations(
&self,
req: google_cloud_longrunning::model::ListOperationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::ListOperationsResponse>>;
async fn get_operation(
&self,
req: google_cloud_longrunning::model::GetOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>;
async fn cancel_operation(
&self,
req: google_cloud_longrunning::model::CancelOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>>;
}
#[cfg(feature = "tools")]
#[async_trait::async_trait]
impl<T: super::Tools> Tools for T {
async fn create_tool(
&self,
req: crate::model::CreateToolRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Tool>> {
T::create_tool(self, req, options).await
}
async fn get_tool(
&self,
req: crate::model::GetToolRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Tool>> {
T::get_tool(self, req, options).await
}
async fn list_tools(
&self,
req: crate::model::ListToolsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::ListToolsResponse>> {
T::list_tools(self, req, options).await
}
async fn delete_tool(
&self,
req: crate::model::DeleteToolRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>> {
T::delete_tool(self, req, options).await
}
async fn update_tool(
&self,
req: crate::model::UpdateToolRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Tool>> {
T::update_tool(self, req, options).await
}
async fn list_locations(
&self,
req: google_cloud_location::model::ListLocationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::ListLocationsResponse>> {
T::list_locations(self, req, options).await
}
async fn get_location(
&self,
req: google_cloud_location::model::GetLocationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::Location>> {
T::get_location(self, req, options).await
}
async fn list_operations(
&self,
req: google_cloud_longrunning::model::ListOperationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::ListOperationsResponse>>
{
T::list_operations(self, req, options).await
}
async fn get_operation(
&self,
req: google_cloud_longrunning::model::GetOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>> {
T::get_operation(self, req, options).await
}
async fn cancel_operation(
&self,
req: google_cloud_longrunning::model::CancelOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>> {
T::cancel_operation(self, req, options).await
}
}
#[cfg(feature = "versions")]
#[async_trait::async_trait]
pub trait Versions: std::fmt::Debug + Send + Sync {
async fn list_versions(
&self,
req: crate::model::ListVersionsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::ListVersionsResponse>>;
async fn get_version(
&self,
req: crate::model::GetVersionRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Version>>;
async fn create_version(
&self,
req: crate::model::CreateVersionRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Version>>;
async fn update_version(
&self,
req: crate::model::UpdateVersionRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Version>>;
async fn delete_version(
&self,
req: crate::model::DeleteVersionRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>>;
async fn list_locations(
&self,
req: google_cloud_location::model::ListLocationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::ListLocationsResponse>>;
async fn get_location(
&self,
req: google_cloud_location::model::GetLocationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::Location>>;
async fn list_operations(
&self,
req: google_cloud_longrunning::model::ListOperationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::ListOperationsResponse>>;
async fn get_operation(
&self,
req: google_cloud_longrunning::model::GetOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>;
async fn cancel_operation(
&self,
req: google_cloud_longrunning::model::CancelOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>>;
}
#[cfg(feature = "versions")]
#[async_trait::async_trait]
impl<T: super::Versions> Versions for T {
async fn list_versions(
&self,
req: crate::model::ListVersionsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::ListVersionsResponse>> {
T::list_versions(self, req, options).await
}
async fn get_version(
&self,
req: crate::model::GetVersionRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Version>> {
T::get_version(self, req, options).await
}
async fn create_version(
&self,
req: crate::model::CreateVersionRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Version>> {
T::create_version(self, req, options).await
}
async fn update_version(
&self,
req: crate::model::UpdateVersionRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<crate::model::Version>> {
T::update_version(self, req, options).await
}
async fn delete_version(
&self,
req: crate::model::DeleteVersionRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>> {
T::delete_version(self, req, options).await
}
async fn list_locations(
&self,
req: google_cloud_location::model::ListLocationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::ListLocationsResponse>> {
T::list_locations(self, req, options).await
}
async fn get_location(
&self,
req: google_cloud_location::model::GetLocationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_location::model::Location>> {
T::get_location(self, req, options).await
}
async fn list_operations(
&self,
req: google_cloud_longrunning::model::ListOperationsRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::ListOperationsResponse>>
{
T::list_operations(self, req, options).await
}
async fn get_operation(
&self,
req: google_cloud_longrunning::model::GetOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<google_cloud_longrunning::model::Operation>> {
T::get_operation(self, req, options).await
}
async fn cancel_operation(
&self,
req: google_cloud_longrunning::model::CancelOperationRequest,
options: crate::RequestOptions,
) -> crate::Result<crate::Response<()>> {
T::cancel_operation(self, req, options).await
}
}