17
17
import dataclasses
18
18
import json # type: ignore
19
19
import re
20
- from typing import Callable , Dict , List , Optional , Sequence , Tuple , Union
20
+ from typing import Any , Callable , Dict , List , Optional , Sequence , Tuple , Union
21
21
import warnings
22
22
23
23
from google .api_core import (
@@ -854,7 +854,7 @@ def pre_get_location(
854
854
self ,
855
855
request : locations_pb2 .GetLocationRequest ,
856
856
metadata : Sequence [Tuple [str , str ]],
857
- ) -> locations_pb2 .Location :
857
+ ) -> Tuple [ locations_pb2 .GetLocationRequest , Sequence [ Tuple [ str , str ]]] :
858
858
"""Pre-rpc interceptor for get_location
859
859
860
860
Override in a subclass to manipulate the request or metadata
@@ -863,7 +863,7 @@ def pre_get_location(
863
863
return request , metadata
864
864
865
865
def post_get_location (
866
- self , response : locations_pb2 .GetLocationRequest
866
+ self , response : locations_pb2 .Location
867
867
) -> locations_pb2 .Location :
868
868
"""Post-rpc interceptor for get_location
869
869
@@ -877,7 +877,7 @@ def pre_list_locations(
877
877
self ,
878
878
request : locations_pb2 .ListLocationsRequest ,
879
879
metadata : Sequence [Tuple [str , str ]],
880
- ) -> locations_pb2 .ListLocationsResponse :
880
+ ) -> Tuple [ locations_pb2 .ListLocationsRequest , Sequence [ Tuple [ str , str ]]] :
881
881
"""Pre-rpc interceptor for list_locations
882
882
883
883
Override in a subclass to manipulate the request or metadata
@@ -886,7 +886,7 @@ def pre_list_locations(
886
886
return request , metadata
887
887
888
888
def post_list_locations (
889
- self , response : locations_pb2 .ListLocationsRequest
889
+ self , response : locations_pb2 .ListLocationsResponse
890
890
) -> locations_pb2 .ListLocationsResponse :
891
891
"""Post-rpc interceptor for list_locations
892
892
@@ -900,17 +900,15 @@ def pre_cancel_operation(
900
900
self ,
901
901
request : operations_pb2 .CancelOperationRequest ,
902
902
metadata : Sequence [Tuple [str , str ]],
903
- ) -> None :
903
+ ) -> Tuple [ operations_pb2 . CancelOperationRequest , Sequence [ Tuple [ str , str ]]] :
904
904
"""Pre-rpc interceptor for cancel_operation
905
905
906
906
Override in a subclass to manipulate the request or metadata
907
907
before they are sent to the Datastream server.
908
908
"""
909
909
return request , metadata
910
910
911
- def post_cancel_operation (
912
- self , response : operations_pb2 .CancelOperationRequest
913
- ) -> None :
911
+ def post_cancel_operation (self , response : None ) -> None :
914
912
"""Post-rpc interceptor for cancel_operation
915
913
916
914
Override in a subclass to manipulate the response
@@ -923,17 +921,15 @@ def pre_delete_operation(
923
921
self ,
924
922
request : operations_pb2 .DeleteOperationRequest ,
925
923
metadata : Sequence [Tuple [str , str ]],
926
- ) -> None :
924
+ ) -> Tuple [ operations_pb2 . DeleteOperationRequest , Sequence [ Tuple [ str , str ]]] :
927
925
"""Pre-rpc interceptor for delete_operation
928
926
929
927
Override in a subclass to manipulate the request or metadata
930
928
before they are sent to the Datastream server.
931
929
"""
932
930
return request , metadata
933
931
934
- def post_delete_operation (
935
- self , response : operations_pb2 .DeleteOperationRequest
936
- ) -> None :
932
+ def post_delete_operation (self , response : None ) -> None :
937
933
"""Post-rpc interceptor for delete_operation
938
934
939
935
Override in a subclass to manipulate the response
@@ -946,7 +942,7 @@ def pre_get_operation(
946
942
self ,
947
943
request : operations_pb2 .GetOperationRequest ,
948
944
metadata : Sequence [Tuple [str , str ]],
949
- ) -> operations_pb2 .Operation :
945
+ ) -> Tuple [ operations_pb2 .GetOperationRequest , Sequence [ Tuple [ str , str ]]] :
950
946
"""Pre-rpc interceptor for get_operation
951
947
952
948
Override in a subclass to manipulate the request or metadata
@@ -955,7 +951,7 @@ def pre_get_operation(
955
951
return request , metadata
956
952
957
953
def post_get_operation (
958
- self , response : operations_pb2 .GetOperationRequest
954
+ self , response : operations_pb2 .Operation
959
955
) -> operations_pb2 .Operation :
960
956
"""Post-rpc interceptor for get_operation
961
957
@@ -969,7 +965,7 @@ def pre_list_operations(
969
965
self ,
970
966
request : operations_pb2 .ListOperationsRequest ,
971
967
metadata : Sequence [Tuple [str , str ]],
972
- ) -> operations_pb2 .ListOperationsResponse :
968
+ ) -> Tuple [ operations_pb2 .ListOperationsRequest , Sequence [ Tuple [ str , str ]]] :
973
969
"""Pre-rpc interceptor for list_operations
974
970
975
971
Override in a subclass to manipulate the request or metadata
@@ -978,7 +974,7 @@ def pre_list_operations(
978
974
return request , metadata
979
975
980
976
def post_list_operations (
981
- self , response : operations_pb2 .ListOperationsRequest
977
+ self , response : operations_pb2 .ListOperationsResponse
982
978
) -> operations_pb2 .ListOperationsResponse :
983
979
"""Post-rpc interceptor for list_operations
984
980
@@ -1143,7 +1139,7 @@ class _CreateConnectionProfile(DatastreamRestStub):
1143
1139
def __hash__ (self ):
1144
1140
return hash ("CreateConnectionProfile" )
1145
1141
1146
- __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , str ] = {
1142
+ __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , Any ] = {
1147
1143
"connectionProfileId" : "" ,
1148
1144
}
1149
1145
@@ -1245,7 +1241,7 @@ class _CreatePrivateConnection(DatastreamRestStub):
1245
1241
def __hash__ (self ):
1246
1242
return hash ("CreatePrivateConnection" )
1247
1243
1248
- __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , str ] = {
1244
+ __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , Any ] = {
1249
1245
"privateConnectionId" : "" ,
1250
1246
}
1251
1247
@@ -1347,7 +1343,7 @@ class _CreateRoute(DatastreamRestStub):
1347
1343
def __hash__ (self ):
1348
1344
return hash ("CreateRoute" )
1349
1345
1350
- __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , str ] = {
1346
+ __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , Any ] = {
1351
1347
"routeId" : "" ,
1352
1348
}
1353
1349
@@ -1445,7 +1441,7 @@ class _CreateStream(DatastreamRestStub):
1445
1441
def __hash__ (self ):
1446
1442
return hash ("CreateStream" )
1447
1443
1448
- __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , str ] = {
1444
+ __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , Any ] = {
1449
1445
"streamId" : "" ,
1450
1446
}
1451
1447
@@ -1545,7 +1541,7 @@ class _DeleteConnectionProfile(DatastreamRestStub):
1545
1541
def __hash__ (self ):
1546
1542
return hash ("DeleteConnectionProfile" )
1547
1543
1548
- __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , str ] = {}
1544
+ __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , Any ] = {}
1549
1545
1550
1546
@classmethod
1551
1547
def _get_unset_required_fields (cls , message_dict ):
@@ -1636,7 +1632,7 @@ class _DeletePrivateConnection(DatastreamRestStub):
1636
1632
def __hash__ (self ):
1637
1633
return hash ("DeletePrivateConnection" )
1638
1634
1639
- __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , str ] = {}
1635
+ __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , Any ] = {}
1640
1636
1641
1637
@classmethod
1642
1638
def _get_unset_required_fields (cls , message_dict ):
@@ -1727,7 +1723,7 @@ class _DeleteRoute(DatastreamRestStub):
1727
1723
def __hash__ (self ):
1728
1724
return hash ("DeleteRoute" )
1729
1725
1730
- __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , str ] = {}
1726
+ __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , Any ] = {}
1731
1727
1732
1728
@classmethod
1733
1729
def _get_unset_required_fields (cls , message_dict ):
@@ -1814,7 +1810,7 @@ class _DeleteStream(DatastreamRestStub):
1814
1810
def __hash__ (self ):
1815
1811
return hash ("DeleteStream" )
1816
1812
1817
- __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , str ] = {}
1813
+ __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , Any ] = {}
1818
1814
1819
1815
@classmethod
1820
1816
def _get_unset_required_fields (cls , message_dict ):
@@ -1903,7 +1899,7 @@ class _DiscoverConnectionProfile(DatastreamRestStub):
1903
1899
def __hash__ (self ):
1904
1900
return hash ("DiscoverConnectionProfile" )
1905
1901
1906
- __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , str ] = {}
1902
+ __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , Any ] = {}
1907
1903
1908
1904
@classmethod
1909
1905
def _get_unset_required_fields (cls , message_dict ):
@@ -2003,7 +1999,7 @@ class _FetchStaticIps(DatastreamRestStub):
2003
1999
def __hash__ (self ):
2004
2000
return hash ("FetchStaticIps" )
2005
2001
2006
- __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , str ] = {}
2002
+ __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , Any ] = {}
2007
2003
2008
2004
@classmethod
2009
2005
def _get_unset_required_fields (cls , message_dict ):
@@ -2095,7 +2091,7 @@ class _GetConnectionProfile(DatastreamRestStub):
2095
2091
def __hash__ (self ):
2096
2092
return hash ("GetConnectionProfile" )
2097
2093
2098
- __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , str ] = {}
2094
+ __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , Any ] = {}
2099
2095
2100
2096
@classmethod
2101
2097
def _get_unset_required_fields (cls , message_dict ):
@@ -2188,7 +2184,7 @@ class _GetPrivateConnection(DatastreamRestStub):
2188
2184
def __hash__ (self ):
2189
2185
return hash ("GetPrivateConnection" )
2190
2186
2191
- __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , str ] = {}
2187
+ __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , Any ] = {}
2192
2188
2193
2189
@classmethod
2194
2190
def _get_unset_required_fields (cls , message_dict ):
@@ -2282,7 +2278,7 @@ class _GetRoute(DatastreamRestStub):
2282
2278
def __hash__ (self ):
2283
2279
return hash ("GetRoute" )
2284
2280
2285
- __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , str ] = {}
2281
+ __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , Any ] = {}
2286
2282
2287
2283
@classmethod
2288
2284
def _get_unset_required_fields (cls , message_dict ):
@@ -2372,7 +2368,7 @@ class _GetStream(DatastreamRestStub):
2372
2368
def __hash__ (self ):
2373
2369
return hash ("GetStream" )
2374
2370
2375
- __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , str ] = {}
2371
+ __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , Any ] = {}
2376
2372
2377
2373
@classmethod
2378
2374
def _get_unset_required_fields (cls , message_dict ):
@@ -2460,7 +2456,7 @@ class _GetStreamObject(DatastreamRestStub):
2460
2456
def __hash__ (self ):
2461
2457
return hash ("GetStreamObject" )
2462
2458
2463
- __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , str ] = {}
2459
+ __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , Any ] = {}
2464
2460
2465
2461
@classmethod
2466
2462
def _get_unset_required_fields (cls , message_dict ):
@@ -2552,7 +2548,7 @@ class _ListConnectionProfiles(DatastreamRestStub):
2552
2548
def __hash__ (self ):
2553
2549
return hash ("ListConnectionProfiles" )
2554
2550
2555
- __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , str ] = {}
2551
+ __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , Any ] = {}
2556
2552
2557
2553
@classmethod
2558
2554
def _get_unset_required_fields (cls , message_dict ):
@@ -2644,7 +2640,7 @@ class _ListPrivateConnections(DatastreamRestStub):
2644
2640
def __hash__ (self ):
2645
2641
return hash ("ListPrivateConnections" )
2646
2642
2647
- __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , str ] = {}
2643
+ __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , Any ] = {}
2648
2644
2649
2645
@classmethod
2650
2646
def _get_unset_required_fields (cls , message_dict ):
@@ -2736,7 +2732,7 @@ class _ListRoutes(DatastreamRestStub):
2736
2732
def __hash__ (self ):
2737
2733
return hash ("ListRoutes" )
2738
2734
2739
- __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , str ] = {}
2735
+ __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , Any ] = {}
2740
2736
2741
2737
@classmethod
2742
2738
def _get_unset_required_fields (cls , message_dict ):
@@ -2822,7 +2818,7 @@ class _ListStreamObjects(DatastreamRestStub):
2822
2818
def __hash__ (self ):
2823
2819
return hash ("ListStreamObjects" )
2824
2820
2825
- __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , str ] = {}
2821
+ __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , Any ] = {}
2826
2822
2827
2823
@classmethod
2828
2824
def _get_unset_required_fields (cls , message_dict ):
@@ -2914,7 +2910,7 @@ class _ListStreams(DatastreamRestStub):
2914
2910
def __hash__ (self ):
2915
2911
return hash ("ListStreams" )
2916
2912
2917
- __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , str ] = {}
2913
+ __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , Any ] = {}
2918
2914
2919
2915
@classmethod
2920
2916
def _get_unset_required_fields (cls , message_dict ):
@@ -3000,7 +2996,7 @@ class _LookupStreamObject(DatastreamRestStub):
3000
2996
def __hash__ (self ):
3001
2997
return hash ("LookupStreamObject" )
3002
2998
3003
- __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , str ] = {}
2999
+ __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , Any ] = {}
3004
3000
3005
3001
@classmethod
3006
3002
def _get_unset_required_fields (cls , message_dict ):
@@ -3102,7 +3098,7 @@ class _StartBackfillJob(DatastreamRestStub):
3102
3098
def __hash__ (self ):
3103
3099
return hash ("StartBackfillJob" )
3104
3100
3105
- __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , str ] = {}
3101
+ __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , Any ] = {}
3106
3102
3107
3103
@classmethod
3108
3104
def _get_unset_required_fields (cls , message_dict ):
@@ -3205,7 +3201,7 @@ class _StopBackfillJob(DatastreamRestStub):
3205
3201
def __hash__ (self ):
3206
3202
return hash ("StopBackfillJob" )
3207
3203
3208
- __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , str ] = {}
3204
+ __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , Any ] = {}
3209
3205
3210
3206
@classmethod
3211
3207
def _get_unset_required_fields (cls , message_dict ):
@@ -3307,7 +3303,7 @@ class _UpdateConnectionProfile(DatastreamRestStub):
3307
3303
def __hash__ (self ):
3308
3304
return hash ("UpdateConnectionProfile" )
3309
3305
3310
- __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , str ] = {}
3306
+ __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , Any ] = {}
3311
3307
3312
3308
@classmethod
3313
3309
def _get_unset_required_fields (cls , message_dict ):
@@ -3405,7 +3401,7 @@ class _UpdateStream(DatastreamRestStub):
3405
3401
def __hash__ (self ):
3406
3402
return hash ("UpdateStream" )
3407
3403
3408
- __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , str ] = {}
3404
+ __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , Any ] = {}
3409
3405
3410
3406
@classmethod
3411
3407
def _get_unset_required_fields (cls , message_dict ):
0 commit comments