comet_backup_ruby_sdk 0.4.0 → 1.4.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (140) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +32 -0
  3. data/Gemfile.lock +1 -1
  4. data/LICENSE +1 -1
  5. data/RELEASING.md +1 -1
  6. data/comet_backup_ruby_sdk.gemspec +1 -1
  7. data/lib/comet/api_response_error.rb +1 -1
  8. data/lib/comet/comet_server.rb +613 -274
  9. data/lib/comet/definitions.rb +19 -7
  10. data/lib/comet/models/add_bucket_response_message.rb +7 -7
  11. data/lib/comet/models/admin_account_properties_response.rb +12 -3
  12. data/lib/comet/models/admin_email_options.rb +84 -0
  13. data/lib/comet/models/admin_resource_response.rb +6 -6
  14. data/lib/comet/models/admin_security_options.rb +8 -8
  15. data/lib/comet/models/admin_u2fregistration.rb +5 -5
  16. data/lib/comet/models/admin_user_permissions.rb +3 -3
  17. data/lib/comet/models/available_download.rb +5 -5
  18. data/lib/comet/models/azure_destination_location.rb +8 -8
  19. data/lib/comet/models/b2destination_location.rb +8 -8
  20. data/lib/comet/models/b2storage_extra_info.rb +3 -3
  21. data/lib/comet/models/b2transaction_totals.rb +6 -6
  22. data/lib/comet/models/b2virtual_storage_role_settings.rb +6 -6
  23. data/lib/comet/models/backup_job_advanced_options.rb +5 -5
  24. data/lib/comet/models/backup_job_detail.rb +21 -21
  25. data/lib/comet/models/backup_job_progress.rb +8 -8
  26. data/lib/comet/models/backup_rule_config.rb +28 -12
  27. data/lib/comet/models/backup_rule_event_triggers.rb +3 -3
  28. data/lib/comet/models/branding_options.rb +28 -28
  29. data/lib/comet/models/branding_properties.rb +24 -24
  30. data/lib/comet/models/browse_disk_drives_response.rb +5 -5
  31. data/lib/comet/models/browse_edbresponse.rb +5 -5
  32. data/lib/comet/models/browse_hvresponse.rb +5 -5
  33. data/lib/comet/models/browse_vssresponse.rb +5 -5
  34. data/lib/comet/models/bucket_properties.rb +15 -6
  35. data/lib/comet/models/bucket_usage_info.rb +4 -4
  36. data/lib/comet/models/comet_apiresponse_message.rb +5 -5
  37. data/lib/comet/models/comet_destination_location.rb +6 -6
  38. data/lib/comet/models/constellation_check_report.rb +5 -5
  39. data/lib/comet/models/constellation_stats.rb +7 -7
  40. data/lib/comet/models/constellation_status_apiresponse.rb +5 -5
  41. data/lib/comet/models/content_measurement.rb +5 -5
  42. data/lib/comet/models/content_measurement_component.rb +5 -5
  43. data/lib/comet/models/create_group_policy_response.rb +6 -6
  44. data/lib/comet/models/custom_remote_bucket_settings.rb +75 -0
  45. data/lib/comet/models/default_email_report_policy.rb +3 -3
  46. data/lib/comet/models/destination_config.rb +72 -44
  47. data/lib/comet/models/destination_location.rb +41 -35
  48. data/lib/comet/models/destination_statistics.rb +6 -6
  49. data/lib/comet/models/device_config.rb +4 -4
  50. data/lib/comet/models/disk_drive.rb +14 -14
  51. data/lib/comet/models/dispatcher_admin_sources_response.rb +6 -6
  52. data/lib/comet/models/dispatcher_stored_objects_response.rb +5 -5
  53. data/lib/comet/models/dispatcher_vault_snapshots_response.rb +5 -5
  54. data/lib/comet/models/edbfile_info.rb +6 -6
  55. data/lib/comet/models/email_options.rb +10 -10
  56. data/lib/comet/models/email_report_config.rb +4 -4
  57. data/lib/comet/models/email_report_generated_preview.rb +8 -8
  58. data/lib/comet/models/external_ldapauthentication_source_settings.rb +40 -7
  59. data/lib/comet/models/extra_file_exclusion.rb +5 -5
  60. data/lib/comet/models/ftpdestination_location.rb +10 -10
  61. data/lib/comet/models/get_group_policy_response.rb +6 -6
  62. data/lib/comet/models/get_profile_and_hash_response_message.rb +6 -6
  63. data/lib/comet/models/get_profile_hash_response_message.rb +6 -6
  64. data/lib/comet/models/group_policy.rb +13 -4
  65. data/lib/comet/models/hyper_vmachine_info.rb +5 -5
  66. data/lib/comet/models/install_creds.rb +99 -0
  67. data/lib/comet/models/install_token.rb +117 -0
  68. data/lib/comet/models/install_token_response.rb +92 -0
  69. data/lib/comet/models/job_entry.rb +6 -6
  70. data/lib/comet/models/live_user_connection.rb +9 -9
  71. data/lib/comet/models/local_destination_location.rb +7 -7
  72. data/lib/comet/models/mac_oscode_sign_properties.rb +9 -9
  73. data/lib/comet/models/mongo_dbconnection.rb +16 -16
  74. data/lib/comet/models/new_bucket_detail.rb +5 -5
  75. data/lib/comet/models/news_entry.rb +14 -5
  76. data/lib/comet/models/organization.rb +145 -0
  77. data/lib/comet/models/organization_response.rb +101 -0
  78. data/lib/comet/models/osinfo.rb +6 -6
  79. data/lib/comet/models/partition.rb +14 -14
  80. data/lib/comet/models/private_branding_properties.rb +18 -18
  81. data/lib/comet/models/protected_item_engine_type_policy.rb +4 -4
  82. data/lib/comet/models/public_branding_properties.rb +9 -9
  83. data/lib/comet/models/remote_server_address.rb +18 -8
  84. data/lib/comet/models/remote_storage_option.rb +25 -9
  85. data/lib/comet/models/replicator_state_apiresponse.rb +15 -15
  86. data/lib/comet/models/request_storage_vault_response_message.rb +6 -6
  87. data/lib/comet/models/restore_job_advanced_options.rb +13 -7
  88. data/lib/comet/models/retention_policy.rb +4 -4
  89. data/lib/comet/models/retention_range.rb +11 -11
  90. data/lib/comet/models/s3destination_location.rb +8 -8
  91. data/lib/comet/models/schedule_config.rb +6 -6
  92. data/lib/comet/models/search_clause.rb +7 -7
  93. data/lib/comet/models/server_config_options_branding_fragment.rb +3 -3
  94. data/lib/comet/models/server_config_options_software_build_role_fragment.rb +3 -3
  95. data/lib/comet/models/server_meta_version_info.rb +18 -18
  96. data/lib/comet/models/session_key_regenerated_response.rb +7 -7
  97. data/lib/comet/models/sftpdestination_location.rb +10 -10
  98. data/lib/comet/models/size_measurement.rb +6 -6
  99. data/lib/comet/models/software_build_role_options.rb +3 -3
  100. data/lib/comet/models/software_update_news_response.rb +7 -7
  101. data/lib/comet/models/source_basic_info.rb +5 -5
  102. data/lib/comet/models/source_config.rb +27 -11
  103. data/lib/comet/models/source_statistics.rb +3 -3
  104. data/lib/comet/models/spanned_destination_location.rb +9 -3
  105. data/lib/comet/models/spanned_storage_extra_info.rb +3 -3
  106. data/lib/comet/models/sshconnection.rb +9 -9
  107. data/lib/comet/models/stat_result.rb +7 -7
  108. data/lib/comet/models/storage_free_space_info.rb +5 -5
  109. data/lib/comet/models/storage_vault_provider_policy.rb +4 -4
  110. data/lib/comet/models/stored_object.rb +11 -11
  111. data/lib/comet/models/streamable_event.rb +16 -5
  112. data/lib/comet/models/swift_destination_location.rb +16 -16
  113. data/lib/comet/models/test_response.rb +5 -5
  114. data/lib/comet/models/totp_regenerated_response.rb +8 -8
  115. data/lib/comet/models/u2fregister_request.rb +5 -5
  116. data/lib/comet/models/u2fregistered_key.rb +6 -6
  117. data/lib/comet/models/u2fregistration_challenge_response.rb +7 -7
  118. data/lib/comet/models/u2fsign_request.rb +6 -6
  119. data/lib/comet/models/u2fsign_response.rb +7 -7
  120. data/lib/comet/models/uninstall_config.rb +3 -3
  121. data/lib/comet/models/update_campaign_device_status.rb +4 -4
  122. data/lib/comet/models/update_campaign_options.rb +3 -3
  123. data/lib/comet/models/update_campaign_properties.rb +5 -5
  124. data/lib/comet/models/update_campaign_status.rb +5 -5
  125. data/lib/comet/models/update_campaign_status_device_entry.rb +6 -6
  126. data/lib/comet/models/user_custom_email_settings.rb +3 -3
  127. data/lib/comet/models/user_on_server.rb +5 -5
  128. data/lib/comet/models/user_policy.rb +7 -7
  129. data/lib/comet/models/user_profile_config.rb +29 -18
  130. data/lib/comet/models/user_profile_fragment.rb +4 -4
  131. data/lib/comet/models/vault_snapshot.rb +12 -6
  132. data/lib/comet/models/vsscomponent.rb +6 -6
  133. data/lib/comet/models/vsswriter_info.rb +4 -4
  134. data/lib/comet/models/wasabi_virtual_storage_role_settings.rb +6 -6
  135. data/lib/comet/models/web_interface_branding_properties.rb +7 -7
  136. data/lib/comet/models/webhook_option.rb +5 -5
  137. data/lib/comet/models/win_smbauth.rb +7 -7
  138. data/lib/comet/models/windows_code_sign_properties.rb +12 -12
  139. data/lib/comet_backup_ruby_sdk.rb +8 -1
  140. metadata +9 -2
@@ -1,6 +1,6 @@
1
1
  #!/usr/bin/env ruby --enable-frozen-string-literal
2
2
  #
3
- # Copyright (c) 2020-2020 Comet Licensing Ltd.
3
+ # Copyright (c) 2020-2021 Comet Licensing Ltd.
4
4
  # Please see the LICENSE file for usage information.
5
5
  #
6
6
  # SPDX-License-Identifier: MIT
@@ -34,14 +34,14 @@ module Comet
34
34
 
35
35
  # @param [String] json_string The complete object in JSON format
36
36
  def from_json(json_string)
37
- raise TypeError "'json_string' expected String, got #{json_string.class}" unless json_string.is_a? String
37
+ raise TypeError, "'json_string' expected String, got #{json_string.class}" unless json_string.is_a? String
38
38
 
39
39
  from_hash(JSON.parse(json_string))
40
40
  end
41
41
 
42
42
  # @param [Hash] obj The complete object as a Ruby hash
43
43
  def from_hash(obj)
44
- raise TypeError "'obj' expected Hash, got #{obj.class}" unless obj.is_a? Hash
44
+ raise TypeError, "'obj' expected Hash, got #{obj.class}" unless obj.is_a? Hash
45
45
 
46
46
  obj.each do |k, v|
47
47
  case k
@@ -1,6 +1,6 @@
1
1
  #!/usr/bin/env ruby --enable-frozen-string-literal
2
2
  #
3
- # Copyright (c) 2020-2020 Comet Licensing Ltd.
3
+ # Copyright (c) 2020-2021 Comet Licensing Ltd.
4
4
  # Please see the LICENSE file for usage information.
5
5
  #
6
6
  # SPDX-License-Identifier: MIT
@@ -26,6 +26,9 @@ module Comet
26
26
  # @type [Array<String>] pre_exec
27
27
  attr_accessor :pre_exec
28
28
 
29
+ # @type [Array<String>] thaw_exec
30
+ attr_accessor :thaw_exec
31
+
29
32
  # @type [Array<String>] post_exec
30
33
  attr_accessor :post_exec
31
34
 
@@ -149,6 +152,9 @@ module Comet
149
152
  # @type [Array<Comet::DestinationLocation>] span_targets
150
153
  attr_accessor :span_targets
151
154
 
155
+ # @type [Boolean] span_use_static_slots
156
+ attr_accessor :span_use_static_slots
157
+
152
158
  # @type [Number] encryption_key_encryption_method
153
159
  attr_accessor :encryption_key_encryption_method
154
160
 
@@ -170,6 +176,9 @@ module Comet
170
176
  # @type [Comet::RetentionPolicy] default_retention
171
177
  attr_accessor :default_retention
172
178
 
179
+ # @type [Boolean] rebrand_storage
180
+ attr_accessor :rebrand_storage
181
+
173
182
  # @type [Hash] Hidden storage to preserve future properties for non-destructive roundtrip operations
174
183
  attr_accessor :unknown_json_fields
175
184
 
@@ -182,6 +191,7 @@ module Comet
182
191
  @create_time = 0
183
192
  @modify_time = 0
184
193
  @pre_exec = []
194
+ @thaw_exec = []
185
195
  @post_exec = []
186
196
  @destination_type = 0
187
197
  @comet_server = ''
@@ -229,27 +239,27 @@ module Comet
229
239
 
230
240
  # @param [String] json_string The complete object in JSON format
231
241
  def from_json(json_string)
232
- raise TypeError "'json_string' expected String, got #{json_string.class}" unless json_string.is_a? String
242
+ raise TypeError, "'json_string' expected String, got #{json_string.class}" unless json_string.is_a? String
233
243
 
234
244
  from_hash(JSON.parse(json_string))
235
245
  end
236
246
 
237
247
  # @param [Hash] obj The complete object as a Ruby hash
238
248
  def from_hash(obj)
239
- raise TypeError "'obj' expected Hash, got #{obj.class}" unless obj.is_a? Hash
249
+ raise TypeError, "'obj' expected Hash, got #{obj.class}" unless obj.is_a? Hash
240
250
 
241
251
  obj.each do |k, v|
242
252
  case k
243
253
  when 'Description'
244
- raise TypeError "'v' expected String, got #{v.class}" unless v.is_a? String
254
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
245
255
 
246
256
  @description = v
247
257
  when 'CreateTime'
248
- raise TypeError "'v' expected Numeric, got #{v.class}" unless v.is_a? Numeric
258
+ raise TypeError, "'v' expected Numeric, got #{v.class}" unless v.is_a? Numeric
249
259
 
250
260
  @create_time = v
251
261
  when 'ModifyTime'
252
- raise TypeError "'v' expected Numeric, got #{v.class}" unless v.is_a? Numeric
262
+ raise TypeError, "'v' expected Numeric, got #{v.class}" unless v.is_a? Numeric
253
263
 
254
264
  @modify_time = v
255
265
  when 'PreExec'
@@ -258,158 +268,169 @@ module Comet
258
268
  else
259
269
  @pre_exec = Array.new(v.length)
260
270
  v.each_with_index do |v1, i1|
261
- raise TypeError "'v1' expected String, got #{v1.class}" unless v1.is_a? String
271
+ raise TypeError, "'v1' expected String, got #{v1.class}" unless v1.is_a? String
262
272
 
263
273
  @pre_exec[i1] = v1
264
274
  end
265
275
  end
276
+ when 'ThawExec'
277
+ if v.nil?
278
+ @thaw_exec = []
279
+ else
280
+ @thaw_exec = Array.new(v.length)
281
+ v.each_with_index do |v1, i1|
282
+ raise TypeError, "'v1' expected String, got #{v1.class}" unless v1.is_a? String
283
+
284
+ @thaw_exec[i1] = v1
285
+ end
286
+ end
266
287
  when 'PostExec'
267
288
  if v.nil?
268
289
  @post_exec = []
269
290
  else
270
291
  @post_exec = Array.new(v.length)
271
292
  v.each_with_index do |v1, i1|
272
- raise TypeError "'v1' expected String, got #{v1.class}" unless v1.is_a? String
293
+ raise TypeError, "'v1' expected String, got #{v1.class}" unless v1.is_a? String
273
294
 
274
295
  @post_exec[i1] = v1
275
296
  end
276
297
  end
277
298
  when 'DestinationType'
278
- raise TypeError "'v' expected Numeric, got #{v.class}" unless v.is_a? Numeric
299
+ raise TypeError, "'v' expected Numeric, got #{v.class}" unless v.is_a? Numeric
279
300
 
280
301
  @destination_type = v
281
302
  when 'CometServer'
282
- raise TypeError "'v' expected String, got #{v.class}" unless v.is_a? String
303
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
283
304
 
284
305
  @comet_server = v
285
306
  when 'CometBucket'
286
- raise TypeError "'v' expected String, got #{v.class}" unless v.is_a? String
307
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
287
308
 
288
309
  @comet_bucket = v
289
310
  when 'CometBucketKey'
290
- raise TypeError "'v' expected String, got #{v.class}" unless v.is_a? String
311
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
291
312
 
292
313
  @comet_bucket_key = v
293
314
  when 'S3Server'
294
- raise TypeError "'v' expected String, got #{v.class}" unless v.is_a? String
315
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
295
316
 
296
317
  @s3server = v
297
318
  when 'S3UsesTLS'
298
319
  @s3uses_tls = v
299
320
  when 'S3AccessKey'
300
- raise TypeError "'v' expected String, got #{v.class}" unless v.is_a? String
321
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
301
322
 
302
323
  @s3access_key = v
303
324
  when 'S3SecretKey'
304
- raise TypeError "'v' expected String, got #{v.class}" unless v.is_a? String
325
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
305
326
 
306
327
  @s3secret_key = v
307
328
  when 'S3BucketName'
308
- raise TypeError "'v' expected String, got #{v.class}" unless v.is_a? String
329
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
309
330
 
310
331
  @s3bucket_name = v
311
332
  when 'S3Subdir'
312
- raise TypeError "'v' expected String, got #{v.class}" unless v.is_a? String
333
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
313
334
 
314
335
  @s3subdir = v
315
336
  when 'S3UsesV2Signing'
316
337
  @s3uses_v2signing = v
317
338
  when 'SFTPServer'
318
- raise TypeError "'v' expected String, got #{v.class}" unless v.is_a? String
339
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
319
340
 
320
341
  @sftpserver = v
321
342
  when 'SFTPUsername'
322
- raise TypeError "'v' expected String, got #{v.class}" unless v.is_a? String
343
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
323
344
 
324
345
  @sftpusername = v
325
346
  when 'SFTPRemotePath'
326
- raise TypeError "'v' expected String, got #{v.class}" unless v.is_a? String
347
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
327
348
 
328
349
  @sftpremote_path = v
329
350
  when 'SFTPAuthMode'
330
- raise TypeError "'v' expected Numeric, got #{v.class}" unless v.is_a? Numeric
351
+ raise TypeError, "'v' expected Numeric, got #{v.class}" unless v.is_a? Numeric
331
352
 
332
353
  @sftpauth_mode = v
333
354
  when 'SFTPPassword'
334
- raise TypeError "'v' expected String, got #{v.class}" unless v.is_a? String
355
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
335
356
 
336
357
  @sftppassword = v
337
358
  when 'SFTPPrivateKey'
338
- raise TypeError "'v' expected String, got #{v.class}" unless v.is_a? String
359
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
339
360
 
340
361
  @sftpprivate_key = v
341
362
  when 'SFTPCustomAuth_UseKnownHostsFile'
342
363
  @sftpcustom_auth__use_known_hosts_file = v
343
364
  when 'SFTPCustomAuth_KnownHostsFile'
344
- raise TypeError "'v' expected String, got #{v.class}" unless v.is_a? String
365
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
345
366
 
346
367
  @sftpcustom_auth__known_hosts_file = v
347
368
  when 'FTPServer'
348
- raise TypeError "'v' expected String, got #{v.class}" unless v.is_a? String
369
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
349
370
 
350
371
  @ftpserver = v
351
372
  when 'FTPUsername'
352
- raise TypeError "'v' expected String, got #{v.class}" unless v.is_a? String
373
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
353
374
 
354
375
  @ftpusername = v
355
376
  when 'FTPPassword'
356
- raise TypeError "'v' expected String, got #{v.class}" unless v.is_a? String
377
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
357
378
 
358
379
  @ftppassword = v
359
380
  when 'FTPBaseUseHomeDirectory'
360
381
  @ftpbase_use_home_directory = v
361
382
  when 'FTPCustomBaseDirectory'
362
- raise TypeError "'v' expected String, got #{v.class}" unless v.is_a? String
383
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
363
384
 
364
385
  @ftpcustom_base_directory = v
365
386
  when 'FTPSMode'
366
- raise TypeError "'v' expected Numeric, got #{v.class}" unless v.is_a? Numeric
387
+ raise TypeError, "'v' expected Numeric, got #{v.class}" unless v.is_a? Numeric
367
388
 
368
389
  @ftpsmode = v
369
390
  when 'FTPPort'
370
- raise TypeError "'v' expected Numeric, got #{v.class}" unless v.is_a? Numeric
391
+ raise TypeError, "'v' expected Numeric, got #{v.class}" unless v.is_a? Numeric
371
392
 
372
393
  @ftpport = v
373
394
  when 'FTPMaxConnections'
374
- raise TypeError "'v' expected Numeric, got #{v.class}" unless v.is_a? Numeric
395
+ raise TypeError, "'v' expected Numeric, got #{v.class}" unless v.is_a? Numeric
375
396
 
376
397
  @ftpmax_connections = v
377
398
  when 'FTPAcceptInvalidSSL'
378
399
  @ftpaccept_invalid_ssl = v
379
400
  when 'AZBAccountName'
380
- raise TypeError "'v' expected String, got #{v.class}" unless v.is_a? String
401
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
381
402
 
382
403
  @azbaccount_name = v
383
404
  when 'AZBAccountKey'
384
- raise TypeError "'v' expected String, got #{v.class}" unless v.is_a? String
405
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
385
406
 
386
407
  @azbaccount_key = v
387
408
  when 'AZBContainer'
388
- raise TypeError "'v' expected String, got #{v.class}" unless v.is_a? String
409
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
389
410
 
390
411
  @azbcontainer = v
391
412
  when 'AZBRealm'
392
- raise TypeError "'v' expected String, got #{v.class}" unless v.is_a? String
413
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
393
414
 
394
415
  @azbrealm = v
395
416
  when 'AZBPrefix'
396
- raise TypeError "'v' expected String, got #{v.class}" unless v.is_a? String
417
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
397
418
 
398
419
  @azbprefix = v
399
420
  when 'LocalcopyPath'
400
- raise TypeError "'v' expected String, got #{v.class}" unless v.is_a? String
421
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
401
422
 
402
423
  @localcopy_path = v
403
424
  when 'LocalcopyWinSMBUsername'
404
- raise TypeError "'v' expected String, got #{v.class}" unless v.is_a? String
425
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
405
426
 
406
427
  @localcopy_win_smbusername = v
407
428
  when 'LocalcopyWinSMBPassword'
408
- raise TypeError "'v' expected String, got #{v.class}" unless v.is_a? String
429
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
409
430
 
410
431
  @localcopy_win_smbpassword = v
411
432
  when 'LocalcopyWinSMBPasswordFormat'
412
- raise TypeError "'v' expected Numeric, got #{v.class}" unless v.is_a? Numeric
433
+ raise TypeError, "'v' expected Numeric, got #{v.class}" unless v.is_a? Numeric
413
434
 
414
435
  @localcopy_win_smbpassword_format = v
415
436
  when 'Swift'
@@ -428,22 +449,24 @@ module Comet
428
449
  @span_targets[i1].from_hash(v1)
429
450
  end
430
451
  end
452
+ when 'SpanUseStaticSlots'
453
+ @span_use_static_slots = v
431
454
  when 'EncryptionKeyEncryptionMethod'
432
- raise TypeError "'v' expected Numeric, got #{v.class}" unless v.is_a? Numeric
455
+ raise TypeError, "'v' expected Numeric, got #{v.class}" unless v.is_a? Numeric
433
456
 
434
457
  @encryption_key_encryption_method = v
435
458
  when 'EncryptedEncryptionKey'
436
- raise TypeError "'v' expected String, got #{v.class}" unless v.is_a? String
459
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
437
460
 
438
461
  @encrypted_encryption_key = v
439
462
  when 'RepoInitTimestamp'
440
- raise TypeError "'v' expected Numeric, got #{v.class}" unless v.is_a? Numeric
463
+ raise TypeError, "'v' expected Numeric, got #{v.class}" unless v.is_a? Numeric
441
464
 
442
465
  @repo_init_timestamp = v
443
466
  when 'StorageLimitEnabled'
444
467
  @storage_limit_enabled = v
445
468
  when 'StorageLimitBytes'
446
- raise TypeError "'v' expected Numeric, got #{v.class}" unless v.is_a? Numeric
469
+ raise TypeError, "'v' expected Numeric, got #{v.class}" unless v.is_a? Numeric
447
470
 
448
471
  @storage_limit_bytes = v
449
472
  when 'Statistics'
@@ -452,6 +475,8 @@ module Comet
452
475
  when 'DefaultRetention'
453
476
  @default_retention = Comet::RetentionPolicy.new
454
477
  @default_retention.from_hash(v)
478
+ when 'RebrandStorage'
479
+ @rebrand_storage = v
455
480
  else
456
481
  @unknown_json_fields[k] = v
457
482
  end
@@ -465,6 +490,7 @@ module Comet
465
490
  ret['CreateTime'] = @create_time
466
491
  ret['ModifyTime'] = @modify_time
467
492
  ret['PreExec'] = @pre_exec
493
+ ret['ThawExec'] = @thaw_exec
468
494
  ret['PostExec'] = @post_exec
469
495
  ret['DestinationType'] = @destination_type
470
496
  ret['CometServer'] = @comet_server
@@ -506,6 +532,7 @@ module Comet
506
532
  ret['Swift'] = @swift
507
533
  ret['B2'] = @b2
508
534
  ret['SpanTargets'] = @span_targets
535
+ ret['SpanUseStaticSlots'] = @span_use_static_slots
509
536
  ret['EncryptionKeyEncryptionMethod'] = @encryption_key_encryption_method
510
537
  ret['EncryptedEncryptionKey'] = @encrypted_encryption_key
511
538
  ret['RepoInitTimestamp'] = @repo_init_timestamp
@@ -515,6 +542,7 @@ module Comet
515
542
  ret['Statistics'] = @statistics
516
543
  end
517
544
  ret['DefaultRetention'] = @default_retention
545
+ ret['RebrandStorage'] = @rebrand_storage
518
546
  @unknown_json_fields.each do |k, v|
519
547
  ret[k] = v
520
548
  end
@@ -1,6 +1,6 @@
1
1
  #!/usr/bin/env ruby --enable-frozen-string-literal
2
2
  #
3
- # Copyright (c) 2020-2020 Comet Licensing Ltd.
3
+ # Copyright (c) 2020-2021 Comet Licensing Ltd.
4
4
  # Please see the LICENSE file for usage information.
5
5
  #
6
6
  # SPDX-License-Identifier: MIT
@@ -134,6 +134,9 @@ module Comet
134
134
  # @type [Array<Comet::DestinationLocation>] span_targets
135
135
  attr_accessor :span_targets
136
136
 
137
+ # @type [Boolean] span_use_static_slots
138
+ attr_accessor :span_use_static_slots
139
+
137
140
  # @type [Hash] Hidden storage to preserve future properties for non-destructive roundtrip operations
138
141
  attr_accessor :unknown_json_fields
139
142
 
@@ -182,153 +185,153 @@ module Comet
182
185
 
183
186
  # @param [String] json_string The complete object in JSON format
184
187
  def from_json(json_string)
185
- raise TypeError "'json_string' expected String, got #{json_string.class}" unless json_string.is_a? String
188
+ raise TypeError, "'json_string' expected String, got #{json_string.class}" unless json_string.is_a? String
186
189
 
187
190
  from_hash(JSON.parse(json_string))
188
191
  end
189
192
 
190
193
  # @param [Hash] obj The complete object as a Ruby hash
191
194
  def from_hash(obj)
192
- raise TypeError "'obj' expected Hash, got #{obj.class}" unless obj.is_a? Hash
195
+ raise TypeError, "'obj' expected Hash, got #{obj.class}" unless obj.is_a? Hash
193
196
 
194
197
  obj.each do |k, v|
195
198
  case k
196
199
  when 'DestinationType'
197
- raise TypeError "'v' expected Numeric, got #{v.class}" unless v.is_a? Numeric
200
+ raise TypeError, "'v' expected Numeric, got #{v.class}" unless v.is_a? Numeric
198
201
 
199
202
  @destination_type = v
200
203
  when 'CometServer'
201
- raise TypeError "'v' expected String, got #{v.class}" unless v.is_a? String
204
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
202
205
 
203
206
  @comet_server = v
204
207
  when 'CometBucket'
205
- raise TypeError "'v' expected String, got #{v.class}" unless v.is_a? String
208
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
206
209
 
207
210
  @comet_bucket = v
208
211
  when 'CometBucketKey'
209
- raise TypeError "'v' expected String, got #{v.class}" unless v.is_a? String
212
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
210
213
 
211
214
  @comet_bucket_key = v
212
215
  when 'S3Server'
213
- raise TypeError "'v' expected String, got #{v.class}" unless v.is_a? String
216
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
214
217
 
215
218
  @s3server = v
216
219
  when 'S3UsesTLS'
217
220
  @s3uses_tls = v
218
221
  when 'S3AccessKey'
219
- raise TypeError "'v' expected String, got #{v.class}" unless v.is_a? String
222
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
220
223
 
221
224
  @s3access_key = v
222
225
  when 'S3SecretKey'
223
- raise TypeError "'v' expected String, got #{v.class}" unless v.is_a? String
226
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
224
227
 
225
228
  @s3secret_key = v
226
229
  when 'S3BucketName'
227
- raise TypeError "'v' expected String, got #{v.class}" unless v.is_a? String
230
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
228
231
 
229
232
  @s3bucket_name = v
230
233
  when 'S3Subdir'
231
- raise TypeError "'v' expected String, got #{v.class}" unless v.is_a? String
234
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
232
235
 
233
236
  @s3subdir = v
234
237
  when 'S3UsesV2Signing'
235
238
  @s3uses_v2signing = v
236
239
  when 'SFTPServer'
237
- raise TypeError "'v' expected String, got #{v.class}" unless v.is_a? String
240
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
238
241
 
239
242
  @sftpserver = v
240
243
  when 'SFTPUsername'
241
- raise TypeError "'v' expected String, got #{v.class}" unless v.is_a? String
244
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
242
245
 
243
246
  @sftpusername = v
244
247
  when 'SFTPRemotePath'
245
- raise TypeError "'v' expected String, got #{v.class}" unless v.is_a? String
248
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
246
249
 
247
250
  @sftpremote_path = v
248
251
  when 'SFTPAuthMode'
249
- raise TypeError "'v' expected Numeric, got #{v.class}" unless v.is_a? Numeric
252
+ raise TypeError, "'v' expected Numeric, got #{v.class}" unless v.is_a? Numeric
250
253
 
251
254
  @sftpauth_mode = v
252
255
  when 'SFTPPassword'
253
- raise TypeError "'v' expected String, got #{v.class}" unless v.is_a? String
256
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
254
257
 
255
258
  @sftppassword = v
256
259
  when 'SFTPPrivateKey'
257
- raise TypeError "'v' expected String, got #{v.class}" unless v.is_a? String
260
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
258
261
 
259
262
  @sftpprivate_key = v
260
263
  when 'SFTPCustomAuth_UseKnownHostsFile'
261
264
  @sftpcustom_auth__use_known_hosts_file = v
262
265
  when 'SFTPCustomAuth_KnownHostsFile'
263
- raise TypeError "'v' expected String, got #{v.class}" unless v.is_a? String
266
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
264
267
 
265
268
  @sftpcustom_auth__known_hosts_file = v
266
269
  when 'FTPServer'
267
- raise TypeError "'v' expected String, got #{v.class}" unless v.is_a? String
270
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
268
271
 
269
272
  @ftpserver = v
270
273
  when 'FTPUsername'
271
- raise TypeError "'v' expected String, got #{v.class}" unless v.is_a? String
274
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
272
275
 
273
276
  @ftpusername = v
274
277
  when 'FTPPassword'
275
- raise TypeError "'v' expected String, got #{v.class}" unless v.is_a? String
278
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
276
279
 
277
280
  @ftppassword = v
278
281
  when 'FTPBaseUseHomeDirectory'
279
282
  @ftpbase_use_home_directory = v
280
283
  when 'FTPCustomBaseDirectory'
281
- raise TypeError "'v' expected String, got #{v.class}" unless v.is_a? String
284
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
282
285
 
283
286
  @ftpcustom_base_directory = v
284
287
  when 'FTPSMode'
285
- raise TypeError "'v' expected Numeric, got #{v.class}" unless v.is_a? Numeric
288
+ raise TypeError, "'v' expected Numeric, got #{v.class}" unless v.is_a? Numeric
286
289
 
287
290
  @ftpsmode = v
288
291
  when 'FTPPort'
289
- raise TypeError "'v' expected Numeric, got #{v.class}" unless v.is_a? Numeric
292
+ raise TypeError, "'v' expected Numeric, got #{v.class}" unless v.is_a? Numeric
290
293
 
291
294
  @ftpport = v
292
295
  when 'FTPMaxConnections'
293
- raise TypeError "'v' expected Numeric, got #{v.class}" unless v.is_a? Numeric
296
+ raise TypeError, "'v' expected Numeric, got #{v.class}" unless v.is_a? Numeric
294
297
 
295
298
  @ftpmax_connections = v
296
299
  when 'FTPAcceptInvalidSSL'
297
300
  @ftpaccept_invalid_ssl = v
298
301
  when 'AZBAccountName'
299
- raise TypeError "'v' expected String, got #{v.class}" unless v.is_a? String
302
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
300
303
 
301
304
  @azbaccount_name = v
302
305
  when 'AZBAccountKey'
303
- raise TypeError "'v' expected String, got #{v.class}" unless v.is_a? String
306
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
304
307
 
305
308
  @azbaccount_key = v
306
309
  when 'AZBContainer'
307
- raise TypeError "'v' expected String, got #{v.class}" unless v.is_a? String
310
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
308
311
 
309
312
  @azbcontainer = v
310
313
  when 'AZBRealm'
311
- raise TypeError "'v' expected String, got #{v.class}" unless v.is_a? String
314
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
312
315
 
313
316
  @azbrealm = v
314
317
  when 'AZBPrefix'
315
- raise TypeError "'v' expected String, got #{v.class}" unless v.is_a? String
318
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
316
319
 
317
320
  @azbprefix = v
318
321
  when 'LocalcopyPath'
319
- raise TypeError "'v' expected String, got #{v.class}" unless v.is_a? String
322
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
320
323
 
321
324
  @localcopy_path = v
322
325
  when 'LocalcopyWinSMBUsername'
323
- raise TypeError "'v' expected String, got #{v.class}" unless v.is_a? String
326
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
324
327
 
325
328
  @localcopy_win_smbusername = v
326
329
  when 'LocalcopyWinSMBPassword'
327
- raise TypeError "'v' expected String, got #{v.class}" unless v.is_a? String
330
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
328
331
 
329
332
  @localcopy_win_smbpassword = v
330
333
  when 'LocalcopyWinSMBPasswordFormat'
331
- raise TypeError "'v' expected Numeric, got #{v.class}" unless v.is_a? Numeric
334
+ raise TypeError, "'v' expected Numeric, got #{v.class}" unless v.is_a? Numeric
332
335
 
333
336
  @localcopy_win_smbpassword_format = v
334
337
  when 'Swift'
@@ -347,6 +350,8 @@ module Comet
347
350
  @span_targets[i1].from_hash(v1)
348
351
  end
349
352
  end
353
+ when 'SpanUseStaticSlots'
354
+ @span_use_static_slots = v
350
355
  else
351
356
  @unknown_json_fields[k] = v
352
357
  end
@@ -396,6 +401,7 @@ module Comet
396
401
  ret['Swift'] = @swift
397
402
  ret['B2'] = @b2
398
403
  ret['SpanTargets'] = @span_targets
404
+ ret['SpanUseStaticSlots'] = @span_use_static_slots
399
405
  @unknown_json_fields.each do |k, v|
400
406
  ret[k] = v
401
407
  end