@@ -72,6 +72,8 @@ def __init__(
72
72
profile : KnownProfiles = KnownProfiles .default ,
73
73
** kwargs : Any
74
74
):
75
+ if api_version :
76
+ kwargs .setdefault ('api_version' , api_version )
75
77
self ._config = EventHubManagementClientConfiguration (credential , subscription_id , ** kwargs )
76
78
self ._client = ARMPipelineClient (base_url = base_url , config = self ._config , ** kwargs )
77
79
super (EventHubManagementClient , self ).__init__ (
@@ -137,7 +139,7 @@ def application_group(self):
137
139
else :
138
140
raise ValueError ("API version {} does not have operation group 'application_group'" .format (api_version ))
139
141
self ._config .api_version = api_version
140
- return OperationClass (self ._client , self ._config , Serializer (self ._models_dict (api_version )), Deserializer (self ._models_dict (api_version )))
142
+ return OperationClass (self ._client , self ._config , Serializer (self ._models_dict (api_version )), Deserializer (self ._models_dict (api_version )), api_version )
141
143
142
144
@property
143
145
def clusters (self ):
@@ -163,7 +165,7 @@ def clusters(self):
163
165
else :
164
166
raise ValueError ("API version {} does not have operation group 'clusters'" .format (api_version ))
165
167
self ._config .api_version = api_version
166
- return OperationClass (self ._client , self ._config , Serializer (self ._models_dict (api_version )), Deserializer (self ._models_dict (api_version )))
168
+ return OperationClass (self ._client , self ._config , Serializer (self ._models_dict (api_version )), Deserializer (self ._models_dict (api_version )), api_version )
167
169
168
170
@property
169
171
def configuration (self ):
@@ -189,7 +191,7 @@ def configuration(self):
189
191
else :
190
192
raise ValueError ("API version {} does not have operation group 'configuration'" .format (api_version ))
191
193
self ._config .api_version = api_version
192
- return OperationClass (self ._client , self ._config , Serializer (self ._models_dict (api_version )), Deserializer (self ._models_dict (api_version )))
194
+ return OperationClass (self ._client , self ._config , Serializer (self ._models_dict (api_version )), Deserializer (self ._models_dict (api_version )), api_version )
193
195
194
196
@property
195
197
def consumer_groups (self ):
@@ -224,7 +226,7 @@ def consumer_groups(self):
224
226
else :
225
227
raise ValueError ("API version {} does not have operation group 'consumer_groups'" .format (api_version ))
226
228
self ._config .api_version = api_version
227
- return OperationClass (self ._client , self ._config , Serializer (self ._models_dict (api_version )), Deserializer (self ._models_dict (api_version )))
229
+ return OperationClass (self ._client , self ._config , Serializer (self ._models_dict (api_version )), Deserializer (self ._models_dict (api_version )), api_version )
228
230
229
231
@property
230
232
def disaster_recovery_configs (self ):
@@ -256,7 +258,7 @@ def disaster_recovery_configs(self):
256
258
else :
257
259
raise ValueError ("API version {} does not have operation group 'disaster_recovery_configs'" .format (api_version ))
258
260
self ._config .api_version = api_version
259
- return OperationClass (self ._client , self ._config , Serializer (self ._models_dict (api_version )), Deserializer (self ._models_dict (api_version )))
261
+ return OperationClass (self ._client , self ._config , Serializer (self ._models_dict (api_version )), Deserializer (self ._models_dict (api_version )), api_version )
260
262
261
263
@property
262
264
def event_hubs (self ):
@@ -291,7 +293,7 @@ def event_hubs(self):
291
293
else :
292
294
raise ValueError ("API version {} does not have operation group 'event_hubs'" .format (api_version ))
293
295
self ._config .api_version = api_version
294
- return OperationClass (self ._client , self ._config , Serializer (self ._models_dict (api_version )), Deserializer (self ._models_dict (api_version )))
296
+ return OperationClass (self ._client , self ._config , Serializer (self ._models_dict (api_version )), Deserializer (self ._models_dict (api_version )), api_version )
295
297
296
298
@property
297
299
def namespaces (self ):
@@ -326,7 +328,7 @@ def namespaces(self):
326
328
else :
327
329
raise ValueError ("API version {} does not have operation group 'namespaces'" .format (api_version ))
328
330
self ._config .api_version = api_version
329
- return OperationClass (self ._client , self ._config , Serializer (self ._models_dict (api_version )), Deserializer (self ._models_dict (api_version )))
331
+ return OperationClass (self ._client , self ._config , Serializer (self ._models_dict (api_version )), Deserializer (self ._models_dict (api_version )), api_version )
330
332
331
333
@property
332
334
def network_security_perimeter_configuration (self ):
@@ -343,7 +345,7 @@ def network_security_perimeter_configuration(self):
343
345
else :
344
346
raise ValueError ("API version {} does not have operation group 'network_security_perimeter_configuration'" .format (api_version ))
345
347
self ._config .api_version = api_version
346
- return OperationClass (self ._client , self ._config , Serializer (self ._models_dict (api_version )), Deserializer (self ._models_dict (api_version )))
348
+ return OperationClass (self ._client , self ._config , Serializer (self ._models_dict (api_version )), Deserializer (self ._models_dict (api_version )), api_version )
347
349
348
350
@property
349
351
def network_security_perimeter_configurations (self ):
@@ -360,7 +362,7 @@ def network_security_perimeter_configurations(self):
360
362
else :
361
363
raise ValueError ("API version {} does not have operation group 'network_security_perimeter_configurations'" .format (api_version ))
362
364
self ._config .api_version = api_version
363
- return OperationClass (self ._client , self ._config , Serializer (self ._models_dict (api_version )), Deserializer (self ._models_dict (api_version )))
365
+ return OperationClass (self ._client , self ._config , Serializer (self ._models_dict (api_version )), Deserializer (self ._models_dict (api_version )), api_version )
364
366
365
367
@property
366
368
def operations (self ):
@@ -395,7 +397,7 @@ def operations(self):
395
397
else :
396
398
raise ValueError ("API version {} does not have operation group 'operations'" .format (api_version ))
397
399
self ._config .api_version = api_version
398
- return OperationClass (self ._client , self ._config , Serializer (self ._models_dict (api_version )), Deserializer (self ._models_dict (api_version )))
400
+ return OperationClass (self ._client , self ._config , Serializer (self ._models_dict (api_version )), Deserializer (self ._models_dict (api_version )), api_version )
399
401
400
402
@property
401
403
def private_endpoint_connections (self ):
@@ -424,7 +426,7 @@ def private_endpoint_connections(self):
424
426
else :
425
427
raise ValueError ("API version {} does not have operation group 'private_endpoint_connections'" .format (api_version ))
426
428
self ._config .api_version = api_version
427
- return OperationClass (self ._client , self ._config , Serializer (self ._models_dict (api_version )), Deserializer (self ._models_dict (api_version )))
429
+ return OperationClass (self ._client , self ._config , Serializer (self ._models_dict (api_version )), Deserializer (self ._models_dict (api_version )), api_version )
428
430
429
431
@property
430
432
def private_link_resources (self ):
@@ -453,7 +455,7 @@ def private_link_resources(self):
453
455
else :
454
456
raise ValueError ("API version {} does not have operation group 'private_link_resources'" .format (api_version ))
455
457
self ._config .api_version = api_version
456
- return OperationClass (self ._client , self ._config , Serializer (self ._models_dict (api_version )), Deserializer (self ._models_dict (api_version )))
458
+ return OperationClass (self ._client , self ._config , Serializer (self ._models_dict (api_version )), Deserializer (self ._models_dict (api_version )), api_version )
457
459
458
460
@property
459
461
def regions (self ):
@@ -470,7 +472,7 @@ def regions(self):
470
472
else :
471
473
raise ValueError ("API version {} does not have operation group 'regions'" .format (api_version ))
472
474
self ._config .api_version = api_version
473
- return OperationClass (self ._client , self ._config , Serializer (self ._models_dict (api_version )), Deserializer (self ._models_dict (api_version )))
475
+ return OperationClass (self ._client , self ._config , Serializer (self ._models_dict (api_version )), Deserializer (self ._models_dict (api_version )), api_version )
474
476
475
477
@property
476
478
def schema_registry (self ):
@@ -490,7 +492,7 @@ def schema_registry(self):
490
492
else :
491
493
raise ValueError ("API version {} does not have operation group 'schema_registry'" .format (api_version ))
492
494
self ._config .api_version = api_version
493
- return OperationClass (self ._client , self ._config , Serializer (self ._models_dict (api_version )), Deserializer (self ._models_dict (api_version )))
495
+ return OperationClass (self ._client , self ._config , Serializer (self ._models_dict (api_version )), Deserializer (self ._models_dict (api_version )), api_version )
494
496
495
497
def close (self ):
496
498
self ._client .close ()
0 commit comments