1717import dataclasses
1818import json # type: ignore
1919import re
20- from typing import Callable , Dict , List , Optional , Sequence , Tuple , Union
20+ from typing import Any , Callable , Dict , List , Optional , Sequence , Tuple , Union
2121import warnings
2222
2323from google .api_core import (
@@ -283,7 +283,7 @@ def pre_get_location(
283283 self ,
284284 request : locations_pb2 .GetLocationRequest ,
285285 metadata : Sequence [Tuple [str , str ]],
286- ) -> locations_pb2 .Location :
286+ ) -> Tuple [ locations_pb2 .GetLocationRequest , Sequence [ Tuple [ str , str ]]] :
287287 """Pre-rpc interceptor for get_location
288288
289289 Override in a subclass to manipulate the request or metadata
@@ -292,7 +292,7 @@ def pre_get_location(
292292 return request , metadata
293293
294294 def post_get_location (
295- self , response : locations_pb2 .GetLocationRequest
295+ self , response : locations_pb2 .Location
296296 ) -> locations_pb2 .Location :
297297 """Post-rpc interceptor for get_location
298298
@@ -306,7 +306,7 @@ def pre_list_locations(
306306 self ,
307307 request : locations_pb2 .ListLocationsRequest ,
308308 metadata : Sequence [Tuple [str , str ]],
309- ) -> locations_pb2 .ListLocationsResponse :
309+ ) -> Tuple [ locations_pb2 .ListLocationsRequest , Sequence [ Tuple [ str , str ]]] :
310310 """Pre-rpc interceptor for list_locations
311311
312312 Override in a subclass to manipulate the request or metadata
@@ -315,7 +315,7 @@ def pre_list_locations(
315315 return request , metadata
316316
317317 def post_list_locations (
318- self , response : locations_pb2 .ListLocationsRequest
318+ self , response : locations_pb2 .ListLocationsResponse
319319 ) -> locations_pb2 .ListLocationsResponse :
320320 """Post-rpc interceptor for list_locations
321321
@@ -329,17 +329,15 @@ def pre_get_iam_policy(
329329 self ,
330330 request : iam_policy_pb2 .GetIamPolicyRequest ,
331331 metadata : Sequence [Tuple [str , str ]],
332- ) -> policy_pb2 . Policy :
332+ ) -> Tuple [ iam_policy_pb2 . GetIamPolicyRequest , Sequence [ Tuple [ str , str ]]] :
333333 """Pre-rpc interceptor for get_iam_policy
334334
335335 Override in a subclass to manipulate the request or metadata
336336 before they are sent to the AppConnectionsService server.
337337 """
338338 return request , metadata
339339
340- def post_get_iam_policy (
341- self , response : iam_policy_pb2 .GetIamPolicyRequest
342- ) -> policy_pb2 .Policy :
340+ def post_get_iam_policy (self , response : policy_pb2 .Policy ) -> policy_pb2 .Policy :
343341 """Post-rpc interceptor for get_iam_policy
344342
345343 Override in a subclass to manipulate the response
@@ -352,17 +350,15 @@ def pre_set_iam_policy(
352350 self ,
353351 request : iam_policy_pb2 .SetIamPolicyRequest ,
354352 metadata : Sequence [Tuple [str , str ]],
355- ) -> policy_pb2 . Policy :
353+ ) -> Tuple [ iam_policy_pb2 . SetIamPolicyRequest , Sequence [ Tuple [ str , str ]]] :
356354 """Pre-rpc interceptor for set_iam_policy
357355
358356 Override in a subclass to manipulate the request or metadata
359357 before they are sent to the AppConnectionsService server.
360358 """
361359 return request , metadata
362360
363- def post_set_iam_policy (
364- self , response : iam_policy_pb2 .SetIamPolicyRequest
365- ) -> policy_pb2 .Policy :
361+ def post_set_iam_policy (self , response : policy_pb2 .Policy ) -> policy_pb2 .Policy :
366362 """Post-rpc interceptor for set_iam_policy
367363
368364 Override in a subclass to manipulate the response
@@ -375,7 +371,7 @@ def pre_test_iam_permissions(
375371 self ,
376372 request : iam_policy_pb2 .TestIamPermissionsRequest ,
377373 metadata : Sequence [Tuple [str , str ]],
378- ) -> iam_policy_pb2 .TestIamPermissionsResponse :
374+ ) -> Tuple [ iam_policy_pb2 .TestIamPermissionsRequest , Sequence [ Tuple [ str , str ]]] :
379375 """Pre-rpc interceptor for test_iam_permissions
380376
381377 Override in a subclass to manipulate the request or metadata
@@ -384,7 +380,7 @@ def pre_test_iam_permissions(
384380 return request , metadata
385381
386382 def post_test_iam_permissions (
387- self , response : iam_policy_pb2 .TestIamPermissionsRequest
383+ self , response : iam_policy_pb2 .TestIamPermissionsResponse
388384 ) -> iam_policy_pb2 .TestIamPermissionsResponse :
389385 """Post-rpc interceptor for test_iam_permissions
390386
@@ -398,17 +394,15 @@ def pre_cancel_operation(
398394 self ,
399395 request : operations_pb2 .CancelOperationRequest ,
400396 metadata : Sequence [Tuple [str , str ]],
401- ) -> None :
397+ ) -> Tuple [ operations_pb2 . CancelOperationRequest , Sequence [ Tuple [ str , str ]]] :
402398 """Pre-rpc interceptor for cancel_operation
403399
404400 Override in a subclass to manipulate the request or metadata
405401 before they are sent to the AppConnectionsService server.
406402 """
407403 return request , metadata
408404
409- def post_cancel_operation (
410- self , response : operations_pb2 .CancelOperationRequest
411- ) -> None :
405+ def post_cancel_operation (self , response : None ) -> None :
412406 """Post-rpc interceptor for cancel_operation
413407
414408 Override in a subclass to manipulate the response
@@ -421,17 +415,15 @@ def pre_delete_operation(
421415 self ,
422416 request : operations_pb2 .DeleteOperationRequest ,
423417 metadata : Sequence [Tuple [str , str ]],
424- ) -> None :
418+ ) -> Tuple [ operations_pb2 . DeleteOperationRequest , Sequence [ Tuple [ str , str ]]] :
425419 """Pre-rpc interceptor for delete_operation
426420
427421 Override in a subclass to manipulate the request or metadata
428422 before they are sent to the AppConnectionsService server.
429423 """
430424 return request , metadata
431425
432- def post_delete_operation (
433- self , response : operations_pb2 .DeleteOperationRequest
434- ) -> None :
426+ def post_delete_operation (self , response : None ) -> None :
435427 """Post-rpc interceptor for delete_operation
436428
437429 Override in a subclass to manipulate the response
@@ -444,7 +436,7 @@ def pre_get_operation(
444436 self ,
445437 request : operations_pb2 .GetOperationRequest ,
446438 metadata : Sequence [Tuple [str , str ]],
447- ) -> operations_pb2 .Operation :
439+ ) -> Tuple [ operations_pb2 .GetOperationRequest , Sequence [ Tuple [ str , str ]]] :
448440 """Pre-rpc interceptor for get_operation
449441
450442 Override in a subclass to manipulate the request or metadata
@@ -453,7 +445,7 @@ def pre_get_operation(
453445 return request , metadata
454446
455447 def post_get_operation (
456- self , response : operations_pb2 .GetOperationRequest
448+ self , response : operations_pb2 .Operation
457449 ) -> operations_pb2 .Operation :
458450 """Post-rpc interceptor for get_operation
459451
@@ -467,7 +459,7 @@ def pre_list_operations(
467459 self ,
468460 request : operations_pb2 .ListOperationsRequest ,
469461 metadata : Sequence [Tuple [str , str ]],
470- ) -> operations_pb2 .ListOperationsResponse :
462+ ) -> Tuple [ operations_pb2 .ListOperationsRequest , Sequence [ Tuple [ str , str ]]] :
471463 """Pre-rpc interceptor for list_operations
472464
473465 Override in a subclass to manipulate the request or metadata
@@ -476,7 +468,7 @@ def pre_list_operations(
476468 return request , metadata
477469
478470 def post_list_operations (
479- self , response : operations_pb2 .ListOperationsRequest
471+ self , response : operations_pb2 .ListOperationsResponse
480472 ) -> operations_pb2 .ListOperationsResponse :
481473 """Post-rpc interceptor for list_operations
482474
@@ -654,7 +646,7 @@ class _CreateAppConnection(AppConnectionsServiceRestStub):
654646 def __hash__ (self ):
655647 return hash ("CreateAppConnection" )
656648
657- __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , str ] = {}
649+ __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , Any ] = {}
658650
659651 @classmethod
660652 def _get_unset_required_fields (cls , message_dict ):
@@ -754,7 +746,7 @@ class _DeleteAppConnection(AppConnectionsServiceRestStub):
754746 def __hash__ (self ):
755747 return hash ("DeleteAppConnection" )
756748
757- __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , str ] = {}
749+ __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , Any ] = {}
758750
759751 @classmethod
760752 def _get_unset_required_fields (cls , message_dict ):
@@ -845,7 +837,7 @@ class _GetAppConnection(AppConnectionsServiceRestStub):
845837 def __hash__ (self ):
846838 return hash ("GetAppConnection" )
847839
848- __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , str ] = {}
840+ __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , Any ] = {}
849841
850842 @classmethod
851843 def _get_unset_required_fields (cls , message_dict ):
@@ -943,7 +935,7 @@ class _ListAppConnections(AppConnectionsServiceRestStub):
943935 def __hash__ (self ):
944936 return hash ("ListAppConnections" )
945937
946- __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , str ] = {}
938+ __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , Any ] = {}
947939
948940 @classmethod
949941 def _get_unset_required_fields (cls , message_dict ):
@@ -1035,7 +1027,7 @@ class _ResolveAppConnections(AppConnectionsServiceRestStub):
10351027 def __hash__ (self ):
10361028 return hash ("ResolveAppConnections" )
10371029
1038- __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , str ] = {
1030+ __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , Any ] = {
10391031 "appConnectorId" : "" ,
10401032 }
10411033
@@ -1131,7 +1123,7 @@ class _UpdateAppConnection(AppConnectionsServiceRestStub):
11311123 def __hash__ (self ):
11321124 return hash ("UpdateAppConnection" )
11331125
1134- __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , str ] = {
1126+ __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , Any ] = {
11351127 "updateMask" : {},
11361128 }
11371129
0 commit comments