Skip to main content

google_cloud_vectorsearch_v1/
stub.rs

1// Copyright 2026 Google LLC
2//
3// Licensed under the Apache License, Version 2.0 (the "License");
4// you may not use this file except in compliance with the License.
5// You may obtain a copy of the License at
6//
7//     https://www.apache.org/licenses/LICENSE-2.0
8//
9// Unless required by applicable law or agreed to in writing, software
10// distributed under the License is distributed on an "AS IS" BASIS,
11// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12// See the License for the specific language governing permissions and
13// limitations under the License.
14//
15// Code generated by sidekick. DO NOT EDIT.
16
17//! Traits to mock the clients in this library.
18//!
19//! Application developers may need to mock the clients in this library to test
20//! how their application works with different (and sometimes hard to trigger)
21//! client and service behavior. Such test can define mocks implementing the
22//! trait(s) defined in this module, initialize the client with an instance of
23//! this mock in their tests, and verify their application responds as expected.
24
25#![allow(rustdoc::broken_intra_doc_links)]
26
27pub(crate) mod dynamic;
28
29/// Defines the trait used to implement [super::client::DataObjectSearchService].
30///
31/// Application developers may need to implement this trait to mock
32/// `client::DataObjectSearchService`.  In other use-cases, application developers only
33/// use `client::DataObjectSearchService` and need not be concerned with this trait or
34/// its implementations.
35///
36/// Services gain new RPCs routinely. Consequently, this trait gains new methods
37/// too. To avoid breaking applications the trait provides a default
38/// implementation of each method. Most of these implementations just return an
39/// error.
40pub trait DataObjectSearchService: std::fmt::Debug + Send + Sync {
41    /// Implements [super::client::DataObjectSearchService::search_data_objects].
42    fn search_data_objects(
43        &self,
44        _req: crate::model::SearchDataObjectsRequest,
45        _options: crate::RequestOptions,
46    ) -> impl std::future::Future<
47        Output = crate::Result<crate::Response<crate::model::SearchDataObjectsResponse>>,
48    > + Send {
49        gaxi::unimplemented::unimplemented_stub()
50    }
51
52    /// Implements [super::client::DataObjectSearchService::query_data_objects].
53    fn query_data_objects(
54        &self,
55        _req: crate::model::QueryDataObjectsRequest,
56        _options: crate::RequestOptions,
57    ) -> impl std::future::Future<
58        Output = crate::Result<crate::Response<crate::model::QueryDataObjectsResponse>>,
59    > + Send {
60        gaxi::unimplemented::unimplemented_stub()
61    }
62
63    /// Implements [super::client::DataObjectSearchService::aggregate_data_objects].
64    fn aggregate_data_objects(
65        &self,
66        _req: crate::model::AggregateDataObjectsRequest,
67        _options: crate::RequestOptions,
68    ) -> impl std::future::Future<
69        Output = crate::Result<crate::Response<crate::model::AggregateDataObjectsResponse>>,
70    > + Send {
71        gaxi::unimplemented::unimplemented_stub()
72    }
73
74    /// Implements [super::client::DataObjectSearchService::batch_search_data_objects].
75    fn batch_search_data_objects(
76        &self,
77        _req: crate::model::BatchSearchDataObjectsRequest,
78        _options: crate::RequestOptions,
79    ) -> impl std::future::Future<
80        Output = crate::Result<crate::Response<crate::model::BatchSearchDataObjectsResponse>>,
81    > + Send {
82        gaxi::unimplemented::unimplemented_stub()
83    }
84
85    /// Implements [super::client::DataObjectSearchService::list_locations].
86    fn list_locations(
87        &self,
88        _req: google_cloud_location::model::ListLocationsRequest,
89        _options: crate::RequestOptions,
90    ) -> impl std::future::Future<
91        Output = crate::Result<
92            crate::Response<google_cloud_location::model::ListLocationsResponse>,
93        >,
94    > + Send {
95        gaxi::unimplemented::unimplemented_stub()
96    }
97
98    /// Implements [super::client::DataObjectSearchService::get_location].
99    fn get_location(
100        &self,
101        _req: google_cloud_location::model::GetLocationRequest,
102        _options: crate::RequestOptions,
103    ) -> impl std::future::Future<
104        Output = crate::Result<crate::Response<google_cloud_location::model::Location>>,
105    > + Send {
106        gaxi::unimplemented::unimplemented_stub()
107    }
108
109    /// Implements [super::client::DataObjectSearchService::list_operations].
110    fn list_operations(
111        &self,
112        _req: google_cloud_longrunning::model::ListOperationsRequest,
113        _options: crate::RequestOptions,
114    ) -> impl std::future::Future<
115        Output = crate::Result<
116            crate::Response<google_cloud_longrunning::model::ListOperationsResponse>,
117        >,
118    > + Send {
119        gaxi::unimplemented::unimplemented_stub()
120    }
121
122    /// Implements [super::client::DataObjectSearchService::get_operation].
123    fn get_operation(
124        &self,
125        _req: google_cloud_longrunning::model::GetOperationRequest,
126        _options: crate::RequestOptions,
127    ) -> impl std::future::Future<
128        Output = crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>,
129    > + Send {
130        gaxi::unimplemented::unimplemented_stub()
131    }
132
133    /// Implements [super::client::DataObjectSearchService::delete_operation].
134    fn delete_operation(
135        &self,
136        _req: google_cloud_longrunning::model::DeleteOperationRequest,
137        _options: crate::RequestOptions,
138    ) -> impl std::future::Future<Output = crate::Result<crate::Response<()>>> + Send {
139        gaxi::unimplemented::unimplemented_stub()
140    }
141
142    /// Implements [super::client::DataObjectSearchService::cancel_operation].
143    fn cancel_operation(
144        &self,
145        _req: google_cloud_longrunning::model::CancelOperationRequest,
146        _options: crate::RequestOptions,
147    ) -> impl std::future::Future<Output = crate::Result<crate::Response<()>>> + Send {
148        gaxi::unimplemented::unimplemented_stub()
149    }
150}
151
152/// Defines the trait used to implement [super::client::DataObjectService].
153///
154/// Application developers may need to implement this trait to mock
155/// `client::DataObjectService`.  In other use-cases, application developers only
156/// use `client::DataObjectService` and need not be concerned with this trait or
157/// its implementations.
158///
159/// Services gain new RPCs routinely. Consequently, this trait gains new methods
160/// too. To avoid breaking applications the trait provides a default
161/// implementation of each method. Most of these implementations just return an
162/// error.
163pub trait DataObjectService: std::fmt::Debug + Send + Sync {
164    /// Implements [super::client::DataObjectService::create_data_object].
165    fn create_data_object(
166        &self,
167        _req: crate::model::CreateDataObjectRequest,
168        _options: crate::RequestOptions,
169    ) -> impl std::future::Future<Output = crate::Result<crate::Response<crate::model::DataObject>>> + Send
170    {
171        gaxi::unimplemented::unimplemented_stub()
172    }
173
174    /// Implements [super::client::DataObjectService::batch_create_data_objects].
175    fn batch_create_data_objects(
176        &self,
177        _req: crate::model::BatchCreateDataObjectsRequest,
178        _options: crate::RequestOptions,
179    ) -> impl std::future::Future<
180        Output = crate::Result<crate::Response<crate::model::BatchCreateDataObjectsResponse>>,
181    > + Send {
182        gaxi::unimplemented::unimplemented_stub()
183    }
184
185    /// Implements [super::client::DataObjectService::get_data_object].
186    fn get_data_object(
187        &self,
188        _req: crate::model::GetDataObjectRequest,
189        _options: crate::RequestOptions,
190    ) -> impl std::future::Future<Output = crate::Result<crate::Response<crate::model::DataObject>>> + Send
191    {
192        gaxi::unimplemented::unimplemented_stub()
193    }
194
195    /// Implements [super::client::DataObjectService::update_data_object].
196    fn update_data_object(
197        &self,
198        _req: crate::model::UpdateDataObjectRequest,
199        _options: crate::RequestOptions,
200    ) -> impl std::future::Future<Output = crate::Result<crate::Response<crate::model::DataObject>>> + Send
201    {
202        gaxi::unimplemented::unimplemented_stub()
203    }
204
205    /// Implements [super::client::DataObjectService::batch_update_data_objects].
206    fn batch_update_data_objects(
207        &self,
208        _req: crate::model::BatchUpdateDataObjectsRequest,
209        _options: crate::RequestOptions,
210    ) -> impl std::future::Future<
211        Output = crate::Result<crate::Response<crate::model::BatchUpdateDataObjectsResponse>>,
212    > + Send {
213        gaxi::unimplemented::unimplemented_stub()
214    }
215
216    /// Implements [super::client::DataObjectService::delete_data_object].
217    fn delete_data_object(
218        &self,
219        _req: crate::model::DeleteDataObjectRequest,
220        _options: crate::RequestOptions,
221    ) -> impl std::future::Future<Output = crate::Result<crate::Response<()>>> + Send {
222        gaxi::unimplemented::unimplemented_stub()
223    }
224
225    /// Implements [super::client::DataObjectService::batch_delete_data_objects].
226    fn batch_delete_data_objects(
227        &self,
228        _req: crate::model::BatchDeleteDataObjectsRequest,
229        _options: crate::RequestOptions,
230    ) -> impl std::future::Future<Output = crate::Result<crate::Response<()>>> + Send {
231        gaxi::unimplemented::unimplemented_stub()
232    }
233
234    /// Implements [super::client::DataObjectService::list_locations].
235    fn list_locations(
236        &self,
237        _req: google_cloud_location::model::ListLocationsRequest,
238        _options: crate::RequestOptions,
239    ) -> impl std::future::Future<
240        Output = crate::Result<
241            crate::Response<google_cloud_location::model::ListLocationsResponse>,
242        >,
243    > + Send {
244        gaxi::unimplemented::unimplemented_stub()
245    }
246
247    /// Implements [super::client::DataObjectService::get_location].
248    fn get_location(
249        &self,
250        _req: google_cloud_location::model::GetLocationRequest,
251        _options: crate::RequestOptions,
252    ) -> impl std::future::Future<
253        Output = crate::Result<crate::Response<google_cloud_location::model::Location>>,
254    > + Send {
255        gaxi::unimplemented::unimplemented_stub()
256    }
257
258    /// Implements [super::client::DataObjectService::list_operations].
259    fn list_operations(
260        &self,
261        _req: google_cloud_longrunning::model::ListOperationsRequest,
262        _options: crate::RequestOptions,
263    ) -> impl std::future::Future<
264        Output = crate::Result<
265            crate::Response<google_cloud_longrunning::model::ListOperationsResponse>,
266        >,
267    > + Send {
268        gaxi::unimplemented::unimplemented_stub()
269    }
270
271    /// Implements [super::client::DataObjectService::get_operation].
272    fn get_operation(
273        &self,
274        _req: google_cloud_longrunning::model::GetOperationRequest,
275        _options: crate::RequestOptions,
276    ) -> impl std::future::Future<
277        Output = crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>,
278    > + Send {
279        gaxi::unimplemented::unimplemented_stub()
280    }
281
282    /// Implements [super::client::DataObjectService::delete_operation].
283    fn delete_operation(
284        &self,
285        _req: google_cloud_longrunning::model::DeleteOperationRequest,
286        _options: crate::RequestOptions,
287    ) -> impl std::future::Future<Output = crate::Result<crate::Response<()>>> + Send {
288        gaxi::unimplemented::unimplemented_stub()
289    }
290
291    /// Implements [super::client::DataObjectService::cancel_operation].
292    fn cancel_operation(
293        &self,
294        _req: google_cloud_longrunning::model::CancelOperationRequest,
295        _options: crate::RequestOptions,
296    ) -> impl std::future::Future<Output = crate::Result<crate::Response<()>>> + Send {
297        gaxi::unimplemented::unimplemented_stub()
298    }
299}
300
301/// Defines the trait used to implement [super::client::VectorSearchService].
302///
303/// Application developers may need to implement this trait to mock
304/// `client::VectorSearchService`.  In other use-cases, application developers only
305/// use `client::VectorSearchService` and need not be concerned with this trait or
306/// its implementations.
307///
308/// Services gain new RPCs routinely. Consequently, this trait gains new methods
309/// too. To avoid breaking applications the trait provides a default
310/// implementation of each method. Most of these implementations just return an
311/// error.
312pub trait VectorSearchService: std::fmt::Debug + Send + Sync {
313    /// Implements [super::client::VectorSearchService::list_collections].
314    fn list_collections(
315        &self,
316        _req: crate::model::ListCollectionsRequest,
317        _options: crate::RequestOptions,
318    ) -> impl std::future::Future<
319        Output = crate::Result<crate::Response<crate::model::ListCollectionsResponse>>,
320    > + Send {
321        gaxi::unimplemented::unimplemented_stub()
322    }
323
324    /// Implements [super::client::VectorSearchService::get_collection].
325    fn get_collection(
326        &self,
327        _req: crate::model::GetCollectionRequest,
328        _options: crate::RequestOptions,
329    ) -> impl std::future::Future<Output = crate::Result<crate::Response<crate::model::Collection>>> + Send
330    {
331        gaxi::unimplemented::unimplemented_stub()
332    }
333
334    /// Implements [super::client::VectorSearchService::create_collection].
335    fn create_collection(
336        &self,
337        _req: crate::model::CreateCollectionRequest,
338        _options: crate::RequestOptions,
339    ) -> impl std::future::Future<
340        Output = crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>,
341    > + Send {
342        gaxi::unimplemented::unimplemented_stub()
343    }
344
345    /// Implements [super::client::VectorSearchService::update_collection].
346    fn update_collection(
347        &self,
348        _req: crate::model::UpdateCollectionRequest,
349        _options: crate::RequestOptions,
350    ) -> impl std::future::Future<
351        Output = crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>,
352    > + Send {
353        gaxi::unimplemented::unimplemented_stub()
354    }
355
356    /// Implements [super::client::VectorSearchService::delete_collection].
357    fn delete_collection(
358        &self,
359        _req: crate::model::DeleteCollectionRequest,
360        _options: crate::RequestOptions,
361    ) -> impl std::future::Future<
362        Output = crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>,
363    > + Send {
364        gaxi::unimplemented::unimplemented_stub()
365    }
366
367    /// Implements [super::client::VectorSearchService::list_indexes].
368    fn list_indexes(
369        &self,
370        _req: crate::model::ListIndexesRequest,
371        _options: crate::RequestOptions,
372    ) -> impl std::future::Future<
373        Output = crate::Result<crate::Response<crate::model::ListIndexesResponse>>,
374    > + Send {
375        gaxi::unimplemented::unimplemented_stub()
376    }
377
378    /// Implements [super::client::VectorSearchService::get_index].
379    fn get_index(
380        &self,
381        _req: crate::model::GetIndexRequest,
382        _options: crate::RequestOptions,
383    ) -> impl std::future::Future<Output = crate::Result<crate::Response<crate::model::Index>>> + Send
384    {
385        gaxi::unimplemented::unimplemented_stub()
386    }
387
388    /// Implements [super::client::VectorSearchService::create_index].
389    fn create_index(
390        &self,
391        _req: crate::model::CreateIndexRequest,
392        _options: crate::RequestOptions,
393    ) -> impl std::future::Future<
394        Output = crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>,
395    > + Send {
396        gaxi::unimplemented::unimplemented_stub()
397    }
398
399    /// Implements [super::client::VectorSearchService::delete_index].
400    fn delete_index(
401        &self,
402        _req: crate::model::DeleteIndexRequest,
403        _options: crate::RequestOptions,
404    ) -> impl std::future::Future<
405        Output = crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>,
406    > + Send {
407        gaxi::unimplemented::unimplemented_stub()
408    }
409
410    /// Implements [super::client::VectorSearchService::import_data_objects].
411    fn import_data_objects(
412        &self,
413        _req: crate::model::ImportDataObjectsRequest,
414        _options: crate::RequestOptions,
415    ) -> impl std::future::Future<
416        Output = crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>,
417    > + Send {
418        gaxi::unimplemented::unimplemented_stub()
419    }
420
421    /// Implements [super::client::VectorSearchService::export_data_objects].
422    fn export_data_objects(
423        &self,
424        _req: crate::model::ExportDataObjectsRequest,
425        _options: crate::RequestOptions,
426    ) -> impl std::future::Future<
427        Output = crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>,
428    > + Send {
429        gaxi::unimplemented::unimplemented_stub()
430    }
431
432    /// Implements [super::client::VectorSearchService::list_locations].
433    fn list_locations(
434        &self,
435        _req: google_cloud_location::model::ListLocationsRequest,
436        _options: crate::RequestOptions,
437    ) -> impl std::future::Future<
438        Output = crate::Result<
439            crate::Response<google_cloud_location::model::ListLocationsResponse>,
440        >,
441    > + Send {
442        gaxi::unimplemented::unimplemented_stub()
443    }
444
445    /// Implements [super::client::VectorSearchService::get_location].
446    fn get_location(
447        &self,
448        _req: google_cloud_location::model::GetLocationRequest,
449        _options: crate::RequestOptions,
450    ) -> impl std::future::Future<
451        Output = crate::Result<crate::Response<google_cloud_location::model::Location>>,
452    > + Send {
453        gaxi::unimplemented::unimplemented_stub()
454    }
455
456    /// Implements [super::client::VectorSearchService::list_operations].
457    fn list_operations(
458        &self,
459        _req: google_cloud_longrunning::model::ListOperationsRequest,
460        _options: crate::RequestOptions,
461    ) -> impl std::future::Future<
462        Output = crate::Result<
463            crate::Response<google_cloud_longrunning::model::ListOperationsResponse>,
464        >,
465    > + Send {
466        gaxi::unimplemented::unimplemented_stub()
467    }
468
469    /// Implements [super::client::VectorSearchService::get_operation].
470    fn get_operation(
471        &self,
472        _req: google_cloud_longrunning::model::GetOperationRequest,
473        _options: crate::RequestOptions,
474    ) -> impl std::future::Future<
475        Output = crate::Result<crate::Response<google_cloud_longrunning::model::Operation>>,
476    > + Send {
477        gaxi::unimplemented::unimplemented_stub()
478    }
479
480    /// Implements [super::client::VectorSearchService::delete_operation].
481    fn delete_operation(
482        &self,
483        _req: google_cloud_longrunning::model::DeleteOperationRequest,
484        _options: crate::RequestOptions,
485    ) -> impl std::future::Future<Output = crate::Result<crate::Response<()>>> + Send {
486        gaxi::unimplemented::unimplemented_stub()
487    }
488
489    /// Implements [super::client::VectorSearchService::cancel_operation].
490    fn cancel_operation(
491        &self,
492        _req: google_cloud_longrunning::model::CancelOperationRequest,
493        _options: crate::RequestOptions,
494    ) -> impl std::future::Future<Output = crate::Result<crate::Response<()>>> + Send {
495        gaxi::unimplemented::unimplemented_stub()
496    }
497
498    /// Returns the polling error policy.
499    ///
500    /// When mocking, this method is typically irrelevant. Do not try to verify
501    /// it is called by your mocks.
502    fn get_polling_error_policy(
503        &self,
504        _options: &crate::RequestOptions,
505    ) -> std::sync::Arc<dyn google_cloud_gax::polling_error_policy::PollingErrorPolicy> {
506        std::sync::Arc::new(google_cloud_gax::polling_error_policy::Aip194Strict)
507    }
508
509    /// Returns the polling backoff policy.
510    ///
511    /// When mocking, this method is typically irrelevant. Do not try to verify
512    /// it is called by your mocks.
513    fn get_polling_backoff_policy(
514        &self,
515        _options: &crate::RequestOptions,
516    ) -> std::sync::Arc<dyn google_cloud_gax::polling_backoff_policy::PollingBackoffPolicy> {
517        std::sync::Arc::new(google_cloud_gax::exponential_backoff::ExponentialBackoff::default())
518    }
519}