1pub mod datastore_admin {
18 use crate::Result;
19
20 pub type ClientBuilder = crate::ClientBuilder<client::Factory, gaxi::options::Credentials>;
34
35 pub(crate) mod client {
36 use super::super::super::client::DatastoreAdmin;
37 pub struct Factory;
38 impl crate::ClientFactory for Factory {
39 type Client = DatastoreAdmin;
40 type Credentials = gaxi::options::Credentials;
41 async fn build(
42 self,
43 config: gaxi::options::ClientConfig,
44 ) -> crate::ClientBuilderResult<Self::Client> {
45 Self::Client::new(config).await
46 }
47 }
48 }
49
50 #[derive(Clone, Debug)]
52 pub(crate) struct RequestBuilder<R: std::default::Default> {
53 stub: std::sync::Arc<dyn super::super::stub::dynamic::DatastoreAdmin>,
54 request: R,
55 options: crate::RequestOptions,
56 }
57
58 impl<R> RequestBuilder<R>
59 where
60 R: std::default::Default,
61 {
62 pub(crate) fn new(
63 stub: std::sync::Arc<dyn super::super::stub::dynamic::DatastoreAdmin>,
64 ) -> Self {
65 Self {
66 stub,
67 request: R::default(),
68 options: crate::RequestOptions::default(),
69 }
70 }
71 }
72
73 #[derive(Clone, Debug)]
91 pub struct ExportEntities(RequestBuilder<crate::model::ExportEntitiesRequest>);
92
93 impl ExportEntities {
94 pub(crate) fn new(
95 stub: std::sync::Arc<dyn super::super::stub::dynamic::DatastoreAdmin>,
96 ) -> Self {
97 Self(RequestBuilder::new(stub))
98 }
99
100 pub fn with_request<V: Into<crate::model::ExportEntitiesRequest>>(mut self, v: V) -> Self {
102 self.0.request = v.into();
103 self
104 }
105
106 pub fn with_options<V: Into<crate::RequestOptions>>(mut self, v: V) -> Self {
108 self.0.options = v.into();
109 self
110 }
111
112 pub async fn send(self) -> Result<google_cloud_longrunning::model::Operation> {
119 (*self.0.stub)
120 .export_entities(self.0.request, self.0.options)
121 .await
122 .map(crate::Response::into_body)
123 }
124
125 pub fn poller(
127 self,
128 ) -> impl google_cloud_lro::Poller<
129 crate::model::ExportEntitiesResponse,
130 crate::model::ExportEntitiesMetadata,
131 > {
132 type Operation = google_cloud_lro::internal::Operation<
133 crate::model::ExportEntitiesResponse,
134 crate::model::ExportEntitiesMetadata,
135 >;
136 let polling_error_policy = self.0.stub.get_polling_error_policy(&self.0.options);
137 let polling_backoff_policy = self.0.stub.get_polling_backoff_policy(&self.0.options);
138
139 let stub = self.0.stub.clone();
140 let mut options = self.0.options.clone();
141 options.set_retry_policy(google_cloud_gax::retry_policy::NeverRetry);
142 let query = move |name| {
143 let stub = stub.clone();
144 let options = options.clone();
145 async {
146 let op = GetOperation::new(stub)
147 .set_name(name)
148 .with_options(options)
149 .send()
150 .await?;
151 Ok(Operation::new(op))
152 }
153 };
154
155 let start = move || async {
156 let op = self.send().await?;
157 Ok(Operation::new(op))
158 };
159
160 google_cloud_lro::internal::new_poller(
161 polling_error_policy,
162 polling_backoff_policy,
163 start,
164 query,
165 )
166 }
167
168 pub fn set_project_id<T: Into<std::string::String>>(mut self, v: T) -> Self {
172 self.0.request.project_id = v.into();
173 self
174 }
175
176 pub fn set_labels<T, K, V>(mut self, v: T) -> Self
178 where
179 T: std::iter::IntoIterator<Item = (K, V)>,
180 K: std::convert::Into<std::string::String>,
181 V: std::convert::Into<std::string::String>,
182 {
183 self.0.request.labels = v.into_iter().map(|(k, v)| (k.into(), v.into())).collect();
184 self
185 }
186
187 pub fn set_entity_filter<T>(mut self, v: T) -> Self
189 where
190 T: std::convert::Into<crate::model::EntityFilter>,
191 {
192 self.0.request.entity_filter = std::option::Option::Some(v.into());
193 self
194 }
195
196 pub fn set_or_clear_entity_filter<T>(mut self, v: std::option::Option<T>) -> Self
198 where
199 T: std::convert::Into<crate::model::EntityFilter>,
200 {
201 self.0.request.entity_filter = v.map(|x| x.into());
202 self
203 }
204
205 pub fn set_output_url_prefix<T: Into<std::string::String>>(mut self, v: T) -> Self {
209 self.0.request.output_url_prefix = v.into();
210 self
211 }
212 }
213
214 #[doc(hidden)]
215 impl crate::RequestBuilder for ExportEntities {
216 fn request_options(&mut self) -> &mut crate::RequestOptions {
217 &mut self.0.options
218 }
219 }
220
221 #[derive(Clone, Debug)]
239 pub struct ImportEntities(RequestBuilder<crate::model::ImportEntitiesRequest>);
240
241 impl ImportEntities {
242 pub(crate) fn new(
243 stub: std::sync::Arc<dyn super::super::stub::dynamic::DatastoreAdmin>,
244 ) -> Self {
245 Self(RequestBuilder::new(stub))
246 }
247
248 pub fn with_request<V: Into<crate::model::ImportEntitiesRequest>>(mut self, v: V) -> Self {
250 self.0.request = v.into();
251 self
252 }
253
254 pub fn with_options<V: Into<crate::RequestOptions>>(mut self, v: V) -> Self {
256 self.0.options = v.into();
257 self
258 }
259
260 pub async fn send(self) -> Result<google_cloud_longrunning::model::Operation> {
267 (*self.0.stub)
268 .import_entities(self.0.request, self.0.options)
269 .await
270 .map(crate::Response::into_body)
271 }
272
273 pub fn poller(
275 self,
276 ) -> impl google_cloud_lro::Poller<(), crate::model::ImportEntitiesMetadata> {
277 type Operation = google_cloud_lro::internal::Operation<
278 wkt::Empty,
279 crate::model::ImportEntitiesMetadata,
280 >;
281 let polling_error_policy = self.0.stub.get_polling_error_policy(&self.0.options);
282 let polling_backoff_policy = self.0.stub.get_polling_backoff_policy(&self.0.options);
283
284 let stub = self.0.stub.clone();
285 let mut options = self.0.options.clone();
286 options.set_retry_policy(google_cloud_gax::retry_policy::NeverRetry);
287 let query = move |name| {
288 let stub = stub.clone();
289 let options = options.clone();
290 async {
291 let op = GetOperation::new(stub)
292 .set_name(name)
293 .with_options(options)
294 .send()
295 .await?;
296 Ok(Operation::new(op))
297 }
298 };
299
300 let start = move || async {
301 let op = self.send().await?;
302 Ok(Operation::new(op))
303 };
304
305 google_cloud_lro::internal::new_unit_response_poller(
306 polling_error_policy,
307 polling_backoff_policy,
308 start,
309 query,
310 )
311 }
312
313 pub fn set_project_id<T: Into<std::string::String>>(mut self, v: T) -> Self {
317 self.0.request.project_id = v.into();
318 self
319 }
320
321 pub fn set_labels<T, K, V>(mut self, v: T) -> Self
323 where
324 T: std::iter::IntoIterator<Item = (K, V)>,
325 K: std::convert::Into<std::string::String>,
326 V: std::convert::Into<std::string::String>,
327 {
328 self.0.request.labels = v.into_iter().map(|(k, v)| (k.into(), v.into())).collect();
329 self
330 }
331
332 pub fn set_input_url<T: Into<std::string::String>>(mut self, v: T) -> Self {
336 self.0.request.input_url = v.into();
337 self
338 }
339
340 pub fn set_entity_filter<T>(mut self, v: T) -> Self
342 where
343 T: std::convert::Into<crate::model::EntityFilter>,
344 {
345 self.0.request.entity_filter = std::option::Option::Some(v.into());
346 self
347 }
348
349 pub fn set_or_clear_entity_filter<T>(mut self, v: std::option::Option<T>) -> Self
351 where
352 T: std::convert::Into<crate::model::EntityFilter>,
353 {
354 self.0.request.entity_filter = v.map(|x| x.into());
355 self
356 }
357 }
358
359 #[doc(hidden)]
360 impl crate::RequestBuilder for ImportEntities {
361 fn request_options(&mut self) -> &mut crate::RequestOptions {
362 &mut self.0.options
363 }
364 }
365
366 #[derive(Clone, Debug)]
384 pub struct CreateIndex(RequestBuilder<crate::model::CreateIndexRequest>);
385
386 impl CreateIndex {
387 pub(crate) fn new(
388 stub: std::sync::Arc<dyn super::super::stub::dynamic::DatastoreAdmin>,
389 ) -> Self {
390 Self(RequestBuilder::new(stub))
391 }
392
393 pub fn with_request<V: Into<crate::model::CreateIndexRequest>>(mut self, v: V) -> Self {
395 self.0.request = v.into();
396 self
397 }
398
399 pub fn with_options<V: Into<crate::RequestOptions>>(mut self, v: V) -> Self {
401 self.0.options = v.into();
402 self
403 }
404
405 pub async fn send(self) -> Result<google_cloud_longrunning::model::Operation> {
412 (*self.0.stub)
413 .create_index(self.0.request, self.0.options)
414 .await
415 .map(crate::Response::into_body)
416 }
417
418 pub fn poller(
420 self,
421 ) -> impl google_cloud_lro::Poller<crate::model::Index, crate::model::IndexOperationMetadata>
422 {
423 type Operation = google_cloud_lro::internal::Operation<
424 crate::model::Index,
425 crate::model::IndexOperationMetadata,
426 >;
427 let polling_error_policy = self.0.stub.get_polling_error_policy(&self.0.options);
428 let polling_backoff_policy = self.0.stub.get_polling_backoff_policy(&self.0.options);
429
430 let stub = self.0.stub.clone();
431 let mut options = self.0.options.clone();
432 options.set_retry_policy(google_cloud_gax::retry_policy::NeverRetry);
433 let query = move |name| {
434 let stub = stub.clone();
435 let options = options.clone();
436 async {
437 let op = GetOperation::new(stub)
438 .set_name(name)
439 .with_options(options)
440 .send()
441 .await?;
442 Ok(Operation::new(op))
443 }
444 };
445
446 let start = move || async {
447 let op = self.send().await?;
448 Ok(Operation::new(op))
449 };
450
451 google_cloud_lro::internal::new_poller(
452 polling_error_policy,
453 polling_backoff_policy,
454 start,
455 query,
456 )
457 }
458
459 pub fn set_project_id<T: Into<std::string::String>>(mut self, v: T) -> Self {
461 self.0.request.project_id = v.into();
462 self
463 }
464
465 pub fn set_index<T>(mut self, v: T) -> Self
467 where
468 T: std::convert::Into<crate::model::Index>,
469 {
470 self.0.request.index = std::option::Option::Some(v.into());
471 self
472 }
473
474 pub fn set_or_clear_index<T>(mut self, v: std::option::Option<T>) -> Self
476 where
477 T: std::convert::Into<crate::model::Index>,
478 {
479 self.0.request.index = v.map(|x| x.into());
480 self
481 }
482 }
483
484 #[doc(hidden)]
485 impl crate::RequestBuilder for CreateIndex {
486 fn request_options(&mut self) -> &mut crate::RequestOptions {
487 &mut self.0.options
488 }
489 }
490
491 #[derive(Clone, Debug)]
509 pub struct DeleteIndex(RequestBuilder<crate::model::DeleteIndexRequest>);
510
511 impl DeleteIndex {
512 pub(crate) fn new(
513 stub: std::sync::Arc<dyn super::super::stub::dynamic::DatastoreAdmin>,
514 ) -> Self {
515 Self(RequestBuilder::new(stub))
516 }
517
518 pub fn with_request<V: Into<crate::model::DeleteIndexRequest>>(mut self, v: V) -> Self {
520 self.0.request = v.into();
521 self
522 }
523
524 pub fn with_options<V: Into<crate::RequestOptions>>(mut self, v: V) -> Self {
526 self.0.options = v.into();
527 self
528 }
529
530 pub async fn send(self) -> Result<google_cloud_longrunning::model::Operation> {
537 (*self.0.stub)
538 .delete_index(self.0.request, self.0.options)
539 .await
540 .map(crate::Response::into_body)
541 }
542
543 pub fn poller(
545 self,
546 ) -> impl google_cloud_lro::Poller<crate::model::Index, crate::model::IndexOperationMetadata>
547 {
548 type Operation = google_cloud_lro::internal::Operation<
549 crate::model::Index,
550 crate::model::IndexOperationMetadata,
551 >;
552 let polling_error_policy = self.0.stub.get_polling_error_policy(&self.0.options);
553 let polling_backoff_policy = self.0.stub.get_polling_backoff_policy(&self.0.options);
554
555 let stub = self.0.stub.clone();
556 let mut options = self.0.options.clone();
557 options.set_retry_policy(google_cloud_gax::retry_policy::NeverRetry);
558 let query = move |name| {
559 let stub = stub.clone();
560 let options = options.clone();
561 async {
562 let op = GetOperation::new(stub)
563 .set_name(name)
564 .with_options(options)
565 .send()
566 .await?;
567 Ok(Operation::new(op))
568 }
569 };
570
571 let start = move || async {
572 let op = self.send().await?;
573 Ok(Operation::new(op))
574 };
575
576 google_cloud_lro::internal::new_poller(
577 polling_error_policy,
578 polling_backoff_policy,
579 start,
580 query,
581 )
582 }
583
584 pub fn set_project_id<T: Into<std::string::String>>(mut self, v: T) -> Self {
586 self.0.request.project_id = v.into();
587 self
588 }
589
590 pub fn set_index_id<T: Into<std::string::String>>(mut self, v: T) -> Self {
592 self.0.request.index_id = v.into();
593 self
594 }
595 }
596
597 #[doc(hidden)]
598 impl crate::RequestBuilder for DeleteIndex {
599 fn request_options(&mut self) -> &mut crate::RequestOptions {
600 &mut self.0.options
601 }
602 }
603
604 #[derive(Clone, Debug)]
621 pub struct GetIndex(RequestBuilder<crate::model::GetIndexRequest>);
622
623 impl GetIndex {
624 pub(crate) fn new(
625 stub: std::sync::Arc<dyn super::super::stub::dynamic::DatastoreAdmin>,
626 ) -> Self {
627 Self(RequestBuilder::new(stub))
628 }
629
630 pub fn with_request<V: Into<crate::model::GetIndexRequest>>(mut self, v: V) -> Self {
632 self.0.request = v.into();
633 self
634 }
635
636 pub fn with_options<V: Into<crate::RequestOptions>>(mut self, v: V) -> Self {
638 self.0.options = v.into();
639 self
640 }
641
642 pub async fn send(self) -> Result<crate::model::Index> {
644 (*self.0.stub)
645 .get_index(self.0.request, self.0.options)
646 .await
647 .map(crate::Response::into_body)
648 }
649
650 pub fn set_project_id<T: Into<std::string::String>>(mut self, v: T) -> Self {
652 self.0.request.project_id = v.into();
653 self
654 }
655
656 pub fn set_index_id<T: Into<std::string::String>>(mut self, v: T) -> Self {
658 self.0.request.index_id = v.into();
659 self
660 }
661 }
662
663 #[doc(hidden)]
664 impl crate::RequestBuilder for GetIndex {
665 fn request_options(&mut self) -> &mut crate::RequestOptions {
666 &mut self.0.options
667 }
668 }
669
670 #[derive(Clone, Debug)]
691 pub struct ListIndexes(RequestBuilder<crate::model::ListIndexesRequest>);
692
693 impl ListIndexes {
694 pub(crate) fn new(
695 stub: std::sync::Arc<dyn super::super::stub::dynamic::DatastoreAdmin>,
696 ) -> Self {
697 Self(RequestBuilder::new(stub))
698 }
699
700 pub fn with_request<V: Into<crate::model::ListIndexesRequest>>(mut self, v: V) -> Self {
702 self.0.request = v.into();
703 self
704 }
705
706 pub fn with_options<V: Into<crate::RequestOptions>>(mut self, v: V) -> Self {
708 self.0.options = v.into();
709 self
710 }
711
712 pub async fn send(self) -> Result<crate::model::ListIndexesResponse> {
714 (*self.0.stub)
715 .list_indexes(self.0.request, self.0.options)
716 .await
717 .map(crate::Response::into_body)
718 }
719
720 pub fn by_page(
722 self,
723 ) -> impl google_cloud_gax::paginator::Paginator<crate::model::ListIndexesResponse, crate::Error>
724 {
725 use std::clone::Clone;
726 let token = self.0.request.page_token.clone();
727 let execute = move |token: String| {
728 let mut builder = self.clone();
729 builder.0.request = builder.0.request.set_page_token(token);
730 builder.send()
731 };
732 google_cloud_gax::paginator::internal::new_paginator(token, execute)
733 }
734
735 pub fn by_item(
737 self,
738 ) -> impl google_cloud_gax::paginator::ItemPaginator<
739 crate::model::ListIndexesResponse,
740 crate::Error,
741 > {
742 use google_cloud_gax::paginator::Paginator;
743 self.by_page().items()
744 }
745
746 pub fn set_project_id<T: Into<std::string::String>>(mut self, v: T) -> Self {
748 self.0.request.project_id = v.into();
749 self
750 }
751
752 pub fn set_filter<T: Into<std::string::String>>(mut self, v: T) -> Self {
754 self.0.request.filter = v.into();
755 self
756 }
757
758 pub fn set_page_size<T: Into<i32>>(mut self, v: T) -> Self {
760 self.0.request.page_size = v.into();
761 self
762 }
763
764 pub fn set_page_token<T: Into<std::string::String>>(mut self, v: T) -> Self {
766 self.0.request.page_token = v.into();
767 self
768 }
769 }
770
771 #[doc(hidden)]
772 impl crate::RequestBuilder for ListIndexes {
773 fn request_options(&mut self) -> &mut crate::RequestOptions {
774 &mut self.0.options
775 }
776 }
777
778 #[derive(Clone, Debug)]
799 pub struct ListOperations(
800 RequestBuilder<google_cloud_longrunning::model::ListOperationsRequest>,
801 );
802
803 impl ListOperations {
804 pub(crate) fn new(
805 stub: std::sync::Arc<dyn super::super::stub::dynamic::DatastoreAdmin>,
806 ) -> Self {
807 Self(RequestBuilder::new(stub))
808 }
809
810 pub fn with_request<V: Into<google_cloud_longrunning::model::ListOperationsRequest>>(
812 mut self,
813 v: V,
814 ) -> Self {
815 self.0.request = v.into();
816 self
817 }
818
819 pub fn with_options<V: Into<crate::RequestOptions>>(mut self, v: V) -> Self {
821 self.0.options = v.into();
822 self
823 }
824
825 pub async fn send(self) -> Result<google_cloud_longrunning::model::ListOperationsResponse> {
827 (*self.0.stub)
828 .list_operations(self.0.request, self.0.options)
829 .await
830 .map(crate::Response::into_body)
831 }
832
833 pub fn by_page(
835 self,
836 ) -> impl google_cloud_gax::paginator::Paginator<
837 google_cloud_longrunning::model::ListOperationsResponse,
838 crate::Error,
839 > {
840 use std::clone::Clone;
841 let token = self.0.request.page_token.clone();
842 let execute = move |token: String| {
843 let mut builder = self.clone();
844 builder.0.request = builder.0.request.set_page_token(token);
845 builder.send()
846 };
847 google_cloud_gax::paginator::internal::new_paginator(token, execute)
848 }
849
850 pub fn by_item(
852 self,
853 ) -> impl google_cloud_gax::paginator::ItemPaginator<
854 google_cloud_longrunning::model::ListOperationsResponse,
855 crate::Error,
856 > {
857 use google_cloud_gax::paginator::Paginator;
858 self.by_page().items()
859 }
860
861 pub fn set_name<T: Into<std::string::String>>(mut self, v: T) -> Self {
863 self.0.request.name = v.into();
864 self
865 }
866
867 pub fn set_filter<T: Into<std::string::String>>(mut self, v: T) -> Self {
869 self.0.request.filter = v.into();
870 self
871 }
872
873 pub fn set_page_size<T: Into<i32>>(mut self, v: T) -> Self {
875 self.0.request.page_size = v.into();
876 self
877 }
878
879 pub fn set_page_token<T: Into<std::string::String>>(mut self, v: T) -> Self {
881 self.0.request.page_token = v.into();
882 self
883 }
884
885 pub fn set_return_partial_success<T: Into<bool>>(mut self, v: T) -> Self {
887 self.0.request.return_partial_success = v.into();
888 self
889 }
890 }
891
892 #[doc(hidden)]
893 impl crate::RequestBuilder for ListOperations {
894 fn request_options(&mut self) -> &mut crate::RequestOptions {
895 &mut self.0.options
896 }
897 }
898
899 #[derive(Clone, Debug)]
916 pub struct GetOperation(RequestBuilder<google_cloud_longrunning::model::GetOperationRequest>);
917
918 impl GetOperation {
919 pub(crate) fn new(
920 stub: std::sync::Arc<dyn super::super::stub::dynamic::DatastoreAdmin>,
921 ) -> Self {
922 Self(RequestBuilder::new(stub))
923 }
924
925 pub fn with_request<V: Into<google_cloud_longrunning::model::GetOperationRequest>>(
927 mut self,
928 v: V,
929 ) -> Self {
930 self.0.request = v.into();
931 self
932 }
933
934 pub fn with_options<V: Into<crate::RequestOptions>>(mut self, v: V) -> Self {
936 self.0.options = v.into();
937 self
938 }
939
940 pub async fn send(self) -> Result<google_cloud_longrunning::model::Operation> {
942 (*self.0.stub)
943 .get_operation(self.0.request, self.0.options)
944 .await
945 .map(crate::Response::into_body)
946 }
947
948 pub fn set_name<T: Into<std::string::String>>(mut self, v: T) -> Self {
950 self.0.request.name = v.into();
951 self
952 }
953 }
954
955 #[doc(hidden)]
956 impl crate::RequestBuilder for GetOperation {
957 fn request_options(&mut self) -> &mut crate::RequestOptions {
958 &mut self.0.options
959 }
960 }
961
962 #[derive(Clone, Debug)]
979 pub struct DeleteOperation(
980 RequestBuilder<google_cloud_longrunning::model::DeleteOperationRequest>,
981 );
982
983 impl DeleteOperation {
984 pub(crate) fn new(
985 stub: std::sync::Arc<dyn super::super::stub::dynamic::DatastoreAdmin>,
986 ) -> Self {
987 Self(RequestBuilder::new(stub))
988 }
989
990 pub fn with_request<V: Into<google_cloud_longrunning::model::DeleteOperationRequest>>(
992 mut self,
993 v: V,
994 ) -> Self {
995 self.0.request = v.into();
996 self
997 }
998
999 pub fn with_options<V: Into<crate::RequestOptions>>(mut self, v: V) -> Self {
1001 self.0.options = v.into();
1002 self
1003 }
1004
1005 pub async fn send(self) -> Result<()> {
1007 (*self.0.stub)
1008 .delete_operation(self.0.request, self.0.options)
1009 .await
1010 .map(crate::Response::into_body)
1011 }
1012
1013 pub fn set_name<T: Into<std::string::String>>(mut self, v: T) -> Self {
1015 self.0.request.name = v.into();
1016 self
1017 }
1018 }
1019
1020 #[doc(hidden)]
1021 impl crate::RequestBuilder for DeleteOperation {
1022 fn request_options(&mut self) -> &mut crate::RequestOptions {
1023 &mut self.0.options
1024 }
1025 }
1026
1027 #[derive(Clone, Debug)]
1044 pub struct CancelOperation(
1045 RequestBuilder<google_cloud_longrunning::model::CancelOperationRequest>,
1046 );
1047
1048 impl CancelOperation {
1049 pub(crate) fn new(
1050 stub: std::sync::Arc<dyn super::super::stub::dynamic::DatastoreAdmin>,
1051 ) -> Self {
1052 Self(RequestBuilder::new(stub))
1053 }
1054
1055 pub fn with_request<V: Into<google_cloud_longrunning::model::CancelOperationRequest>>(
1057 mut self,
1058 v: V,
1059 ) -> Self {
1060 self.0.request = v.into();
1061 self
1062 }
1063
1064 pub fn with_options<V: Into<crate::RequestOptions>>(mut self, v: V) -> Self {
1066 self.0.options = v.into();
1067 self
1068 }
1069
1070 pub async fn send(self) -> Result<()> {
1072 (*self.0.stub)
1073 .cancel_operation(self.0.request, self.0.options)
1074 .await
1075 .map(crate::Response::into_body)
1076 }
1077
1078 pub fn set_name<T: Into<std::string::String>>(mut self, v: T) -> Self {
1080 self.0.request.name = v.into();
1081 self
1082 }
1083 }
1084
1085 #[doc(hidden)]
1086 impl crate::RequestBuilder for CancelOperation {
1087 fn request_options(&mut self) -> &mut crate::RequestOptions {
1088 &mut self.0.options
1089 }
1090 }
1091}