azure_mgmt_event_grid 0.17.4 → 0.17.5

Sign up to get free protection for your applications and to get access to all the features.
Files changed (80) hide show
  1. checksums.yaml +4 -4
  2. data/lib/2017-06-15-preview/generated/azure_mgmt_event_grid/event_grid_management_client.rb +1 -1
  3. data/lib/2017-09-15-preview/generated/azure_mgmt_event_grid/event_grid_management_client.rb +1 -1
  4. data/lib/2018-01-01/generated/azure_mgmt_event_grid/event_grid_management_client.rb +1 -1
  5. data/lib/2018-05-01-preview/generated/azure_mgmt_event_grid/event_grid_management_client.rb +1 -1
  6. data/lib/2018-09-15-preview/generated/azure_mgmt_event_grid/event_grid_management_client.rb +1 -1
  7. data/lib/2019-01-01/generated/azure_mgmt_event_grid/event_grid_management_client.rb +1 -1
  8. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid.rb +93 -0
  9. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/domain_topics.rb +653 -0
  10. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/domains.rb +1236 -0
  11. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/event_grid_management_client.rb +153 -0
  12. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/event_subscriptions.rb +3318 -0
  13. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/advanced_filter.rb +74 -0
  14. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/bool_equals_advanced_filter.rb +69 -0
  15. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/dead_letter_destination.rb +50 -0
  16. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/domain.rb +142 -0
  17. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/domain_provisioning_state.rb +20 -0
  18. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/domain_regenerate_key_request.rb +46 -0
  19. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/domain_shared_access_keys.rb +57 -0
  20. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/domain_topic.rb +75 -0
  21. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/domain_topic_provisioning_state.rb +20 -0
  22. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/domain_topics_list_result.rb +98 -0
  23. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/domain_update_parameters.rb +54 -0
  24. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/domains_list_result.rb +98 -0
  25. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/event_delivery_schema.rb +17 -0
  26. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/event_hub_event_subscription_destination.rb +62 -0
  27. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/event_subscription.rb +189 -0
  28. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/event_subscription_destination.rb +50 -0
  29. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/event_subscription_filter.rb +120 -0
  30. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/event_subscription_full_url.rb +47 -0
  31. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/event_subscription_provisioning_state.rb +21 -0
  32. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/event_subscription_update_parameters.rb +137 -0
  33. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/event_subscriptions_list_result.rb +98 -0
  34. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/event_type.rb +106 -0
  35. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/event_types_list_result.rb +55 -0
  36. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/hybrid_connection_event_subscription_destination.rb +64 -0
  37. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/input_schema.rb +17 -0
  38. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/input_schema_mapping.rb +49 -0
  39. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/json_field.rb +50 -0
  40. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/json_field_with_default.rb +67 -0
  41. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/json_input_schema_mapping.rb +130 -0
  42. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/number_greater_than_advanced_filter.rb +69 -0
  43. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/number_greater_than_or_equals_advanced_filter.rb +69 -0
  44. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/number_in_advanced_filter.rb +77 -0
  45. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/number_less_than_advanced_filter.rb +69 -0
  46. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/number_less_than_or_equals_advanced_filter.rb +69 -0
  47. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/number_not_in_advanced_filter.rb +77 -0
  48. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/operation.rb +80 -0
  49. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/operation_info.rb +79 -0
  50. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/operations_list_result.rb +55 -0
  51. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/resource.rb +80 -0
  52. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/resource_region_type.rb +16 -0
  53. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/retry_policy.rb +57 -0
  54. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/service_bus_queue_event_subscription_destination.rb +63 -0
  55. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/storage_blob_dead_letter_destination.rb +74 -0
  56. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/storage_queue_event_subscription_destination.rb +75 -0
  57. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/string_begins_with_advanced_filter.rb +77 -0
  58. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/string_contains_advanced_filter.rb +77 -0
  59. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/string_ends_with_advanced_filter.rb +77 -0
  60. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/string_in_advanced_filter.rb +77 -0
  61. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/string_not_in_advanced_filter.rb +77 -0
  62. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/topic.rb +144 -0
  63. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/topic_provisioning_state.rb +20 -0
  64. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/topic_regenerate_key_request.rb +46 -0
  65. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/topic_shared_access_keys.rb +57 -0
  66. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/topic_type_info.rb +139 -0
  67. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/topic_type_provisioning_state.rb +20 -0
  68. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/topic_types_list_result.rb +55 -0
  69. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/topic_update_parameters.rb +54 -0
  70. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/topics_list_result.rb +98 -0
  71. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/tracked_resource.rb +92 -0
  72. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/models/web_hook_event_subscription_destination.rb +75 -0
  73. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/module_definition.rb +9 -0
  74. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/operations.rb +116 -0
  75. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/topic_types.rb +299 -0
  76. data/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/topics.rb +1345 -0
  77. data/lib/azure_mgmt_event_grid.rb +1 -0
  78. data/lib/profiles/latest/modules/eventgrid_profile_module.rb +204 -84
  79. data/lib/version.rb +1 -1
  80. metadata +70 -1
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 37bfaff59635a763855dd7e8964bc08c4d87765b2be3566a2d1b4a7b64d317ae
4
- data.tar.gz: 514f12579835fdbe57222561f873033711fb7eeed96bf7e41a3679bd1c9e0dac
3
+ metadata.gz: e0e9a462f184bf1068ba396a219ae2634ef2ff7dc2fb7225d98440da4340178e
4
+ data.tar.gz: 889f06e5e171e5800064572fadfdb71bb3ef36b53c5e6dc71a52207e82b72ccd
5
5
  SHA512:
6
- metadata.gz: a49747984b5a42543ce19cc6b104bdb0c95503a591326f5607703d8b32c22e5d8ed109f7266bcce13c7003c615f2823dc751dec796ed4b934226c009b746393d
7
- data.tar.gz: 8195f512ef7897e3a77772e56d92d68e9c5694e4db22c1fecbcdb33aced893e4431c7d01ce7bf0efc88c970be057453b0a6b3127a41cae7391650f86c0a5145f
6
+ metadata.gz: 51f00fd096f0d7d7fdf2547ee24a3be4529b5fc677cce559ef3ee8eccc0507b0e9fd26bd34fab2ef8a2b4aa391d35375d11b77318c83491078ff3d78428f9e70
7
+ data.tar.gz: d0ba812201b57a440ecfff5eda615a344952dc62e86701cee825ffd8069c1f1dd346725d85c63417beec629f6130cbcd974daa234964ac23dde3bd9906bbed49
@@ -138,7 +138,7 @@ module Azure::EventGrid::Mgmt::V2017_06_15_preview
138
138
  #
139
139
  def add_telemetry
140
140
  sdk_information = 'azure_mgmt_event_grid'
141
- sdk_information = "#{sdk_information}/0.17.4"
141
+ sdk_information = "#{sdk_information}/0.17.5"
142
142
  add_user_agent_information(sdk_information)
143
143
  end
144
144
  end
@@ -138,7 +138,7 @@ module Azure::EventGrid::Mgmt::V2017_09_15_preview
138
138
  #
139
139
  def add_telemetry
140
140
  sdk_information = 'azure_mgmt_event_grid'
141
- sdk_information = "#{sdk_information}/0.17.4"
141
+ sdk_information = "#{sdk_information}/0.17.5"
142
142
  add_user_agent_information(sdk_information)
143
143
  end
144
144
  end
@@ -138,7 +138,7 @@ module Azure::EventGrid::Mgmt::V2018_01_01
138
138
  #
139
139
  def add_telemetry
140
140
  sdk_information = 'azure_mgmt_event_grid'
141
- sdk_information = "#{sdk_information}/0.17.4"
141
+ sdk_information = "#{sdk_information}/0.17.5"
142
142
  add_user_agent_information(sdk_information)
143
143
  end
144
144
  end
@@ -138,7 +138,7 @@ module Azure::EventGrid::Mgmt::V2018_05_01_preview
138
138
  #
139
139
  def add_telemetry
140
140
  sdk_information = 'azure_mgmt_event_grid'
141
- sdk_information = "#{sdk_information}/0.17.4"
141
+ sdk_information = "#{sdk_information}/0.17.5"
142
142
  add_user_agent_information(sdk_information)
143
143
  end
144
144
  end
@@ -146,7 +146,7 @@ module Azure::EventGrid::Mgmt::V2018_09_15_preview
146
146
  #
147
147
  def add_telemetry
148
148
  sdk_information = 'azure_mgmt_event_grid'
149
- sdk_information = "#{sdk_information}/0.17.4"
149
+ sdk_information = "#{sdk_information}/0.17.5"
150
150
  add_user_agent_information(sdk_information)
151
151
  end
152
152
  end
@@ -138,7 +138,7 @@ module Azure::EventGrid::Mgmt::V2019_01_01
138
138
  #
139
139
  def add_telemetry
140
140
  sdk_information = 'azure_mgmt_event_grid'
141
- sdk_information = "#{sdk_information}/0.17.4"
141
+ sdk_information = "#{sdk_information}/0.17.5"
142
142
  add_user_agent_information(sdk_information)
143
143
  end
144
144
  end
@@ -0,0 +1,93 @@
1
+ # encoding: utf-8
2
+ # Code generated by Microsoft (R) AutoRest Code Generator.
3
+ # Changes may cause incorrect behavior and will be lost if the code is
4
+ # regenerated.
5
+
6
+ require 'uri'
7
+ require 'cgi'
8
+ require 'date'
9
+ require 'json'
10
+ require 'base64'
11
+ require 'erb'
12
+ require 'securerandom'
13
+ require 'time'
14
+ require 'timeliness'
15
+ require 'faraday'
16
+ require 'faraday-cookie_jar'
17
+ require 'concurrent'
18
+ require 'ms_rest'
19
+ require '2019-02-01-preview/generated/azure_mgmt_event_grid/module_definition'
20
+ require 'ms_rest_azure'
21
+
22
+ module Azure::EventGrid::Mgmt::V2019_02_01_preview
23
+ autoload :Domains, '2019-02-01-preview/generated/azure_mgmt_event_grid/domains.rb'
24
+ autoload :DomainTopics, '2019-02-01-preview/generated/azure_mgmt_event_grid/domain_topics.rb'
25
+ autoload :EventSubscriptions, '2019-02-01-preview/generated/azure_mgmt_event_grid/event_subscriptions.rb'
26
+ autoload :Operations, '2019-02-01-preview/generated/azure_mgmt_event_grid/operations.rb'
27
+ autoload :Topics, '2019-02-01-preview/generated/azure_mgmt_event_grid/topics.rb'
28
+ autoload :TopicTypes, '2019-02-01-preview/generated/azure_mgmt_event_grid/topic_types.rb'
29
+ autoload :EventGridManagementClient, '2019-02-01-preview/generated/azure_mgmt_event_grid/event_grid_management_client.rb'
30
+
31
+ module Models
32
+ autoload :EventSubscriptionFilter, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/event_subscription_filter.rb'
33
+ autoload :RetryPolicy, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/retry_policy.rb'
34
+ autoload :Resource, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/resource.rb'
35
+ autoload :DeadLetterDestination, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/dead_letter_destination.rb'
36
+ autoload :JsonFieldWithDefault, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/json_field_with_default.rb'
37
+ autoload :InputSchemaMapping, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/input_schema_mapping.rb'
38
+ autoload :JsonField, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/json_field.rb'
39
+ autoload :TopicRegenerateKeyRequest, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/topic_regenerate_key_request.rb'
40
+ autoload :TopicTypesListResult, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/topic_types_list_result.rb'
41
+ autoload :DomainsListResult, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/domains_list_result.rb'
42
+ autoload :TopicsListResult, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/topics_list_result.rb'
43
+ autoload :DomainRegenerateKeyRequest, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/domain_regenerate_key_request.rb'
44
+ autoload :EventSubscriptionFullUrl, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/event_subscription_full_url.rb'
45
+ autoload :DomainTopicsListResult, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/domain_topics_list_result.rb'
46
+ autoload :EventSubscriptionUpdateParameters, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/event_subscription_update_parameters.rb'
47
+ autoload :AdvancedFilter, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/advanced_filter.rb'
48
+ autoload :EventSubscriptionsListResult, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/event_subscriptions_list_result.rb'
49
+ autoload :DomainUpdateParameters, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/domain_update_parameters.rb'
50
+ autoload :OperationInfo, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/operation_info.rb'
51
+ autoload :EventTypesListResult, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/event_types_list_result.rb'
52
+ autoload :Operation, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/operation.rb'
53
+ autoload :TopicSharedAccessKeys, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/topic_shared_access_keys.rb'
54
+ autoload :OperationsListResult, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/operations_list_result.rb'
55
+ autoload :EventSubscriptionDestination, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/event_subscription_destination.rb'
56
+ autoload :TopicUpdateParameters, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/topic_update_parameters.rb'
57
+ autoload :DomainSharedAccessKeys, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/domain_shared_access_keys.rb'
58
+ autoload :JsonInputSchemaMapping, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/json_input_schema_mapping.rb'
59
+ autoload :TrackedResource, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/tracked_resource.rb'
60
+ autoload :Domain, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/domain.rb'
61
+ autoload :DomainTopic, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/domain_topic.rb'
62
+ autoload :NumberInAdvancedFilter, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/number_in_advanced_filter.rb'
63
+ autoload :StorageBlobDeadLetterDestination, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/storage_blob_dead_letter_destination.rb'
64
+ autoload :NumberNotInAdvancedFilter, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/number_not_in_advanced_filter.rb'
65
+ autoload :NumberLessThanAdvancedFilter, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/number_less_than_advanced_filter.rb'
66
+ autoload :NumberGreaterThanAdvancedFilter, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/number_greater_than_advanced_filter.rb'
67
+ autoload :NumberLessThanOrEqualsAdvancedFilter, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/number_less_than_or_equals_advanced_filter.rb'
68
+ autoload :NumberGreaterThanOrEqualsAdvancedFilter, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/number_greater_than_or_equals_advanced_filter.rb'
69
+ autoload :BoolEqualsAdvancedFilter, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/bool_equals_advanced_filter.rb'
70
+ autoload :StringInAdvancedFilter, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/string_in_advanced_filter.rb'
71
+ autoload :StringNotInAdvancedFilter, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/string_not_in_advanced_filter.rb'
72
+ autoload :StringBeginsWithAdvancedFilter, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/string_begins_with_advanced_filter.rb'
73
+ autoload :StringEndsWithAdvancedFilter, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/string_ends_with_advanced_filter.rb'
74
+ autoload :StringContainsAdvancedFilter, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/string_contains_advanced_filter.rb'
75
+ autoload :WebHookEventSubscriptionDestination, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/web_hook_event_subscription_destination.rb'
76
+ autoload :EventHubEventSubscriptionDestination, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/event_hub_event_subscription_destination.rb'
77
+ autoload :StorageQueueEventSubscriptionDestination, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/storage_queue_event_subscription_destination.rb'
78
+ autoload :HybridConnectionEventSubscriptionDestination, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/hybrid_connection_event_subscription_destination.rb'
79
+ autoload :ServiceBusQueueEventSubscriptionDestination, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/service_bus_queue_event_subscription_destination.rb'
80
+ autoload :EventSubscription, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/event_subscription.rb'
81
+ autoload :Topic, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/topic.rb'
82
+ autoload :EventType, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/event_type.rb'
83
+ autoload :TopicTypeInfo, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/topic_type_info.rb'
84
+ autoload :DomainProvisioningState, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/domain_provisioning_state.rb'
85
+ autoload :InputSchema, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/input_schema.rb'
86
+ autoload :DomainTopicProvisioningState, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/domain_topic_provisioning_state.rb'
87
+ autoload :EventSubscriptionProvisioningState, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/event_subscription_provisioning_state.rb'
88
+ autoload :EventDeliverySchema, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/event_delivery_schema.rb'
89
+ autoload :TopicProvisioningState, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/topic_provisioning_state.rb'
90
+ autoload :ResourceRegionType, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/resource_region_type.rb'
91
+ autoload :TopicTypeProvisioningState, '2019-02-01-preview/generated/azure_mgmt_event_grid/models/topic_type_provisioning_state.rb'
92
+ end
93
+ end
@@ -0,0 +1,653 @@
1
+ # encoding: utf-8
2
+ # Code generated by Microsoft (R) AutoRest Code Generator.
3
+ # Changes may cause incorrect behavior and will be lost if the code is
4
+ # regenerated.
5
+
6
+ module Azure::EventGrid::Mgmt::V2019_02_01_preview
7
+ #
8
+ # Azure EventGrid Management Client
9
+ #
10
+ class DomainTopics
11
+ include MsRestAzure
12
+
13
+ #
14
+ # Creates and initializes a new instance of the DomainTopics class.
15
+ # @param client service class for accessing basic functionality.
16
+ #
17
+ def initialize(client)
18
+ @client = client
19
+ end
20
+
21
+ # @return [EventGridManagementClient] reference to the EventGridManagementClient
22
+ attr_reader :client
23
+
24
+ #
25
+ # Get a domain topic
26
+ #
27
+ # Get properties of a domain topic
28
+ #
29
+ # @param resource_group_name [String] The name of the resource group within the
30
+ # user's subscription.
31
+ # @param domain_name [String] Name of the domain
32
+ # @param domain_topic_name [String] Name of the topic
33
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
34
+ # will be added to the HTTP request.
35
+ #
36
+ # @return [DomainTopic] operation results.
37
+ #
38
+ def get(resource_group_name, domain_name, domain_topic_name, custom_headers:nil)
39
+ response = get_async(resource_group_name, domain_name, domain_topic_name, custom_headers:custom_headers).value!
40
+ response.body unless response.nil?
41
+ end
42
+
43
+ #
44
+ # Get a domain topic
45
+ #
46
+ # Get properties of a domain topic
47
+ #
48
+ # @param resource_group_name [String] The name of the resource group within the
49
+ # user's subscription.
50
+ # @param domain_name [String] Name of the domain
51
+ # @param domain_topic_name [String] Name of the topic
52
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
53
+ # will be added to the HTTP request.
54
+ #
55
+ # @return [MsRestAzure::AzureOperationResponse] HTTP response information.
56
+ #
57
+ def get_with_http_info(resource_group_name, domain_name, domain_topic_name, custom_headers:nil)
58
+ get_async(resource_group_name, domain_name, domain_topic_name, custom_headers:custom_headers).value!
59
+ end
60
+
61
+ #
62
+ # Get a domain topic
63
+ #
64
+ # Get properties of a domain topic
65
+ #
66
+ # @param resource_group_name [String] The name of the resource group within the
67
+ # user's subscription.
68
+ # @param domain_name [String] Name of the domain
69
+ # @param domain_topic_name [String] Name of the topic
70
+ # @param [Hash{String => String}] A hash of custom headers that will be added
71
+ # to the HTTP request.
72
+ #
73
+ # @return [Concurrent::Promise] Promise object which holds the HTTP response.
74
+ #
75
+ def get_async(resource_group_name, domain_name, domain_topic_name, custom_headers:nil)
76
+ fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
77
+ fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
78
+ fail ArgumentError, 'domain_name is nil' if domain_name.nil?
79
+ fail ArgumentError, 'domain_topic_name is nil' if domain_topic_name.nil?
80
+ fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
81
+
82
+
83
+ request_headers = {}
84
+ request_headers['Content-Type'] = 'application/json; charset=utf-8'
85
+
86
+ # Set Headers
87
+ request_headers['x-ms-client-request-id'] = SecureRandom.uuid
88
+ request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
89
+ path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.EventGrid/domains/{domainName}/topics/{domainTopicName}'
90
+
91
+ request_url = @base_url || @client.base_url
92
+
93
+ options = {
94
+ middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
95
+ path_params: {'subscriptionId' => @client.subscription_id,'resourceGroupName' => resource_group_name,'domainName' => domain_name,'domainTopicName' => domain_topic_name},
96
+ query_params: {'api-version' => @client.api_version},
97
+ headers: request_headers.merge(custom_headers || {}),
98
+ base_url: request_url
99
+ }
100
+ promise = @client.make_request_async(:get, path_template, options)
101
+
102
+ promise = promise.then do |result|
103
+ http_response = result.response
104
+ status_code = http_response.status
105
+ response_content = http_response.body
106
+ unless status_code == 200
107
+ error_model = JSON.load(response_content)
108
+ fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model)
109
+ end
110
+
111
+ result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
112
+ # Deserialize Response
113
+ if status_code == 200
114
+ begin
115
+ parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content)
116
+ result_mapper = Azure::EventGrid::Mgmt::V2019_02_01_preview::Models::DomainTopic.mapper()
117
+ result.body = @client.deserialize(result_mapper, parsed_response)
118
+ rescue Exception => e
119
+ fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result)
120
+ end
121
+ end
122
+
123
+ result
124
+ end
125
+
126
+ promise.execute
127
+ end
128
+
129
+ #
130
+ # Create or update a domain topic
131
+ #
132
+ # Asynchronously creates or updates a new domain topic with the specified
133
+ # parameters.
134
+ #
135
+ # @param resource_group_name [String] The name of the resource group within the
136
+ # user's subscription.
137
+ # @param domain_name [String] Name of the domain
138
+ # @param domain_topic_name [String] Name of the domain topic
139
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
140
+ # will be added to the HTTP request.
141
+ #
142
+ # @return [DomainTopic] operation results.
143
+ #
144
+ def create_or_update(resource_group_name, domain_name, domain_topic_name, custom_headers:nil)
145
+ response = create_or_update_async(resource_group_name, domain_name, domain_topic_name, custom_headers:custom_headers).value!
146
+ response.body unless response.nil?
147
+ end
148
+
149
+ #
150
+ # @param resource_group_name [String] The name of the resource group within the
151
+ # user's subscription.
152
+ # @param domain_name [String] Name of the domain
153
+ # @param domain_topic_name [String] Name of the domain topic
154
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
155
+ # will be added to the HTTP request.
156
+ #
157
+ # @return [Concurrent::Promise] promise which provides async access to http
158
+ # response.
159
+ #
160
+ def create_or_update_async(resource_group_name, domain_name, domain_topic_name, custom_headers:nil)
161
+ # Send request
162
+ promise = begin_create_or_update_async(resource_group_name, domain_name, domain_topic_name, custom_headers:custom_headers)
163
+
164
+ promise = promise.then do |response|
165
+ # Defining deserialization method.
166
+ deserialize_method = lambda do |parsed_response|
167
+ result_mapper = Azure::EventGrid::Mgmt::V2019_02_01_preview::Models::DomainTopic.mapper()
168
+ parsed_response = @client.deserialize(result_mapper, parsed_response)
169
+ end
170
+
171
+ # Waiting for response.
172
+ @client.get_long_running_operation_result(response, deserialize_method)
173
+ end
174
+
175
+ promise
176
+ end
177
+
178
+ #
179
+ # Delete a domain topic
180
+ #
181
+ # Delete existing domain topic
182
+ #
183
+ # @param resource_group_name [String] The name of the resource group within the
184
+ # user's subscription.
185
+ # @param domain_name [String] Name of the domain
186
+ # @param domain_topic_name [String] Name of the domain topic
187
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
188
+ # will be added to the HTTP request.
189
+ #
190
+ def delete(resource_group_name, domain_name, domain_topic_name, custom_headers:nil)
191
+ response = delete_async(resource_group_name, domain_name, domain_topic_name, custom_headers:custom_headers).value!
192
+ nil
193
+ end
194
+
195
+ #
196
+ # @param resource_group_name [String] The name of the resource group within the
197
+ # user's subscription.
198
+ # @param domain_name [String] Name of the domain
199
+ # @param domain_topic_name [String] Name of the domain topic
200
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
201
+ # will be added to the HTTP request.
202
+ #
203
+ # @return [Concurrent::Promise] promise which provides async access to http
204
+ # response.
205
+ #
206
+ def delete_async(resource_group_name, domain_name, domain_topic_name, custom_headers:nil)
207
+ # Send request
208
+ promise = begin_delete_async(resource_group_name, domain_name, domain_topic_name, custom_headers:custom_headers)
209
+
210
+ promise = promise.then do |response|
211
+ # Defining deserialization method.
212
+ deserialize_method = lambda do |parsed_response|
213
+ end
214
+
215
+ # Waiting for response.
216
+ @client.get_long_running_operation_result(response, deserialize_method)
217
+ end
218
+
219
+ promise
220
+ end
221
+
222
+ #
223
+ # List domain topics.
224
+ #
225
+ # List all the topics in a domain.
226
+ #
227
+ # @param resource_group_name [String] The name of the resource group within the
228
+ # user's subscription.
229
+ # @param domain_name [String] Domain name.
230
+ # @param filter [String] Filter the results using OData syntax.
231
+ # @param top [Integer] The number of results to return.
232
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
233
+ # will be added to the HTTP request.
234
+ #
235
+ # @return [Array<DomainTopic>] operation results.
236
+ #
237
+ def list_by_domain(resource_group_name, domain_name, filter:nil, top:nil, custom_headers:nil)
238
+ first_page = list_by_domain_as_lazy(resource_group_name, domain_name, filter:filter, top:top, custom_headers:custom_headers)
239
+ first_page.get_all_items
240
+ end
241
+
242
+ #
243
+ # List domain topics.
244
+ #
245
+ # List all the topics in a domain.
246
+ #
247
+ # @param resource_group_name [String] The name of the resource group within the
248
+ # user's subscription.
249
+ # @param domain_name [String] Domain name.
250
+ # @param filter [String] Filter the results using OData syntax.
251
+ # @param top [Integer] The number of results to return.
252
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
253
+ # will be added to the HTTP request.
254
+ #
255
+ # @return [MsRestAzure::AzureOperationResponse] HTTP response information.
256
+ #
257
+ def list_by_domain_with_http_info(resource_group_name, domain_name, filter:nil, top:nil, custom_headers:nil)
258
+ list_by_domain_async(resource_group_name, domain_name, filter:filter, top:top, custom_headers:custom_headers).value!
259
+ end
260
+
261
+ #
262
+ # List domain topics.
263
+ #
264
+ # List all the topics in a domain.
265
+ #
266
+ # @param resource_group_name [String] The name of the resource group within the
267
+ # user's subscription.
268
+ # @param domain_name [String] Domain name.
269
+ # @param filter [String] Filter the results using OData syntax.
270
+ # @param top [Integer] The number of results to return.
271
+ # @param [Hash{String => String}] A hash of custom headers that will be added
272
+ # to the HTTP request.
273
+ #
274
+ # @return [Concurrent::Promise] Promise object which holds the HTTP response.
275
+ #
276
+ def list_by_domain_async(resource_group_name, domain_name, filter:nil, top:nil, custom_headers:nil)
277
+ fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
278
+ fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
279
+ fail ArgumentError, 'domain_name is nil' if domain_name.nil?
280
+ fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
281
+
282
+
283
+ request_headers = {}
284
+ request_headers['Content-Type'] = 'application/json; charset=utf-8'
285
+
286
+ # Set Headers
287
+ request_headers['x-ms-client-request-id'] = SecureRandom.uuid
288
+ request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
289
+ path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.EventGrid/domains/{domainName}/topics'
290
+
291
+ request_url = @base_url || @client.base_url
292
+
293
+ options = {
294
+ middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
295
+ path_params: {'subscriptionId' => @client.subscription_id,'resourceGroupName' => resource_group_name,'domainName' => domain_name},
296
+ query_params: {'api-version' => @client.api_version,'$filter' => filter,'$top' => top},
297
+ headers: request_headers.merge(custom_headers || {}),
298
+ base_url: request_url
299
+ }
300
+ promise = @client.make_request_async(:get, path_template, options)
301
+
302
+ promise = promise.then do |result|
303
+ http_response = result.response
304
+ status_code = http_response.status
305
+ response_content = http_response.body
306
+ unless status_code == 200
307
+ error_model = JSON.load(response_content)
308
+ fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model)
309
+ end
310
+
311
+ result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
312
+ # Deserialize Response
313
+ if status_code == 200
314
+ begin
315
+ parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content)
316
+ result_mapper = Azure::EventGrid::Mgmt::V2019_02_01_preview::Models::DomainTopicsListResult.mapper()
317
+ result.body = @client.deserialize(result_mapper, parsed_response)
318
+ rescue Exception => e
319
+ fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result)
320
+ end
321
+ end
322
+
323
+ result
324
+ end
325
+
326
+ promise.execute
327
+ end
328
+
329
+ #
330
+ # Create or update a domain topic
331
+ #
332
+ # Asynchronously creates or updates a new domain topic with the specified
333
+ # parameters.
334
+ #
335
+ # @param resource_group_name [String] The name of the resource group within the
336
+ # user's subscription.
337
+ # @param domain_name [String] Name of the domain
338
+ # @param domain_topic_name [String] Name of the domain topic
339
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
340
+ # will be added to the HTTP request.
341
+ #
342
+ # @return [DomainTopic] operation results.
343
+ #
344
+ def begin_create_or_update(resource_group_name, domain_name, domain_topic_name, custom_headers:nil)
345
+ response = begin_create_or_update_async(resource_group_name, domain_name, domain_topic_name, custom_headers:custom_headers).value!
346
+ response.body unless response.nil?
347
+ end
348
+
349
+ #
350
+ # Create or update a domain topic
351
+ #
352
+ # Asynchronously creates or updates a new domain topic with the specified
353
+ # parameters.
354
+ #
355
+ # @param resource_group_name [String] The name of the resource group within the
356
+ # user's subscription.
357
+ # @param domain_name [String] Name of the domain
358
+ # @param domain_topic_name [String] Name of the domain topic
359
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
360
+ # will be added to the HTTP request.
361
+ #
362
+ # @return [MsRestAzure::AzureOperationResponse] HTTP response information.
363
+ #
364
+ def begin_create_or_update_with_http_info(resource_group_name, domain_name, domain_topic_name, custom_headers:nil)
365
+ begin_create_or_update_async(resource_group_name, domain_name, domain_topic_name, custom_headers:custom_headers).value!
366
+ end
367
+
368
+ #
369
+ # Create or update a domain topic
370
+ #
371
+ # Asynchronously creates or updates a new domain topic with the specified
372
+ # parameters.
373
+ #
374
+ # @param resource_group_name [String] The name of the resource group within the
375
+ # user's subscription.
376
+ # @param domain_name [String] Name of the domain
377
+ # @param domain_topic_name [String] Name of the domain topic
378
+ # @param [Hash{String => String}] A hash of custom headers that will be added
379
+ # to the HTTP request.
380
+ #
381
+ # @return [Concurrent::Promise] Promise object which holds the HTTP response.
382
+ #
383
+ def begin_create_or_update_async(resource_group_name, domain_name, domain_topic_name, custom_headers:nil)
384
+ fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
385
+ fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
386
+ fail ArgumentError, 'domain_name is nil' if domain_name.nil?
387
+ fail ArgumentError, 'domain_topic_name is nil' if domain_topic_name.nil?
388
+ fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
389
+
390
+
391
+ request_headers = {}
392
+ request_headers['Content-Type'] = 'application/json; charset=utf-8'
393
+
394
+ # Set Headers
395
+ request_headers['x-ms-client-request-id'] = SecureRandom.uuid
396
+ request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
397
+ path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.EventGrid/domains/{domainName}/topics/{domainTopicName}'
398
+
399
+ request_url = @base_url || @client.base_url
400
+
401
+ options = {
402
+ middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
403
+ path_params: {'subscriptionId' => @client.subscription_id,'resourceGroupName' => resource_group_name,'domainName' => domain_name,'domainTopicName' => domain_topic_name},
404
+ query_params: {'api-version' => @client.api_version},
405
+ headers: request_headers.merge(custom_headers || {}),
406
+ base_url: request_url
407
+ }
408
+ promise = @client.make_request_async(:put, path_template, options)
409
+
410
+ promise = promise.then do |result|
411
+ http_response = result.response
412
+ status_code = http_response.status
413
+ response_content = http_response.body
414
+ unless status_code == 201
415
+ error_model = JSON.load(response_content)
416
+ fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model)
417
+ end
418
+
419
+ result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
420
+ # Deserialize Response
421
+ if status_code == 201
422
+ begin
423
+ parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content)
424
+ result_mapper = Azure::EventGrid::Mgmt::V2019_02_01_preview::Models::DomainTopic.mapper()
425
+ result.body = @client.deserialize(result_mapper, parsed_response)
426
+ rescue Exception => e
427
+ fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result)
428
+ end
429
+ end
430
+
431
+ result
432
+ end
433
+
434
+ promise.execute
435
+ end
436
+
437
+ #
438
+ # Delete a domain topic
439
+ #
440
+ # Delete existing domain topic
441
+ #
442
+ # @param resource_group_name [String] The name of the resource group within the
443
+ # user's subscription.
444
+ # @param domain_name [String] Name of the domain
445
+ # @param domain_topic_name [String] Name of the domain topic
446
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
447
+ # will be added to the HTTP request.
448
+ #
449
+ #
450
+ def begin_delete(resource_group_name, domain_name, domain_topic_name, custom_headers:nil)
451
+ response = begin_delete_async(resource_group_name, domain_name, domain_topic_name, custom_headers:custom_headers).value!
452
+ nil
453
+ end
454
+
455
+ #
456
+ # Delete a domain topic
457
+ #
458
+ # Delete existing domain topic
459
+ #
460
+ # @param resource_group_name [String] The name of the resource group within the
461
+ # user's subscription.
462
+ # @param domain_name [String] Name of the domain
463
+ # @param domain_topic_name [String] Name of the domain topic
464
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
465
+ # will be added to the HTTP request.
466
+ #
467
+ # @return [MsRestAzure::AzureOperationResponse] HTTP response information.
468
+ #
469
+ def begin_delete_with_http_info(resource_group_name, domain_name, domain_topic_name, custom_headers:nil)
470
+ begin_delete_async(resource_group_name, domain_name, domain_topic_name, custom_headers:custom_headers).value!
471
+ end
472
+
473
+ #
474
+ # Delete a domain topic
475
+ #
476
+ # Delete existing domain topic
477
+ #
478
+ # @param resource_group_name [String] The name of the resource group within the
479
+ # user's subscription.
480
+ # @param domain_name [String] Name of the domain
481
+ # @param domain_topic_name [String] Name of the domain topic
482
+ # @param [Hash{String => String}] A hash of custom headers that will be added
483
+ # to the HTTP request.
484
+ #
485
+ # @return [Concurrent::Promise] Promise object which holds the HTTP response.
486
+ #
487
+ def begin_delete_async(resource_group_name, domain_name, domain_topic_name, custom_headers:nil)
488
+ fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
489
+ fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
490
+ fail ArgumentError, 'domain_name is nil' if domain_name.nil?
491
+ fail ArgumentError, 'domain_topic_name is nil' if domain_topic_name.nil?
492
+ fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
493
+
494
+
495
+ request_headers = {}
496
+ request_headers['Content-Type'] = 'application/json; charset=utf-8'
497
+
498
+ # Set Headers
499
+ request_headers['x-ms-client-request-id'] = SecureRandom.uuid
500
+ request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
501
+ path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.EventGrid/domains/{domainName}/topics/{domainTopicName}'
502
+
503
+ request_url = @base_url || @client.base_url
504
+
505
+ options = {
506
+ middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
507
+ path_params: {'subscriptionId' => @client.subscription_id,'resourceGroupName' => resource_group_name,'domainName' => domain_name,'domainTopicName' => domain_topic_name},
508
+ query_params: {'api-version' => @client.api_version},
509
+ headers: request_headers.merge(custom_headers || {}),
510
+ base_url: request_url
511
+ }
512
+ promise = @client.make_request_async(:delete, path_template, options)
513
+
514
+ promise = promise.then do |result|
515
+ http_response = result.response
516
+ status_code = http_response.status
517
+ response_content = http_response.body
518
+ unless status_code == 202 || status_code == 204
519
+ error_model = JSON.load(response_content)
520
+ fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model)
521
+ end
522
+
523
+ result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
524
+
525
+ result
526
+ end
527
+
528
+ promise.execute
529
+ end
530
+
531
+ #
532
+ # List domain topics.
533
+ #
534
+ # List all the topics in a domain.
535
+ #
536
+ # @param next_page_link [String] The NextLink from the previous successful call
537
+ # to List operation.
538
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
539
+ # will be added to the HTTP request.
540
+ #
541
+ # @return [DomainTopicsListResult] operation results.
542
+ #
543
+ def list_by_domain_next(next_page_link, custom_headers:nil)
544
+ response = list_by_domain_next_async(next_page_link, custom_headers:custom_headers).value!
545
+ response.body unless response.nil?
546
+ end
547
+
548
+ #
549
+ # List domain topics.
550
+ #
551
+ # List all the topics in a domain.
552
+ #
553
+ # @param next_page_link [String] The NextLink from the previous successful call
554
+ # to List operation.
555
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
556
+ # will be added to the HTTP request.
557
+ #
558
+ # @return [MsRestAzure::AzureOperationResponse] HTTP response information.
559
+ #
560
+ def list_by_domain_next_with_http_info(next_page_link, custom_headers:nil)
561
+ list_by_domain_next_async(next_page_link, custom_headers:custom_headers).value!
562
+ end
563
+
564
+ #
565
+ # List domain topics.
566
+ #
567
+ # List all the topics in a domain.
568
+ #
569
+ # @param next_page_link [String] The NextLink from the previous successful call
570
+ # to List operation.
571
+ # @param [Hash{String => String}] A hash of custom headers that will be added
572
+ # to the HTTP request.
573
+ #
574
+ # @return [Concurrent::Promise] Promise object which holds the HTTP response.
575
+ #
576
+ def list_by_domain_next_async(next_page_link, custom_headers:nil)
577
+ fail ArgumentError, 'next_page_link is nil' if next_page_link.nil?
578
+
579
+
580
+ request_headers = {}
581
+ request_headers['Content-Type'] = 'application/json; charset=utf-8'
582
+
583
+ # Set Headers
584
+ request_headers['x-ms-client-request-id'] = SecureRandom.uuid
585
+ request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
586
+ path_template = '{nextLink}'
587
+
588
+ request_url = @base_url || @client.base_url
589
+
590
+ options = {
591
+ middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
592
+ skip_encoding_path_params: {'nextLink' => next_page_link},
593
+ headers: request_headers.merge(custom_headers || {}),
594
+ base_url: request_url
595
+ }
596
+ promise = @client.make_request_async(:get, path_template, options)
597
+
598
+ promise = promise.then do |result|
599
+ http_response = result.response
600
+ status_code = http_response.status
601
+ response_content = http_response.body
602
+ unless status_code == 200
603
+ error_model = JSON.load(response_content)
604
+ fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model)
605
+ end
606
+
607
+ result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
608
+ # Deserialize Response
609
+ if status_code == 200
610
+ begin
611
+ parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content)
612
+ result_mapper = Azure::EventGrid::Mgmt::V2019_02_01_preview::Models::DomainTopicsListResult.mapper()
613
+ result.body = @client.deserialize(result_mapper, parsed_response)
614
+ rescue Exception => e
615
+ fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result)
616
+ end
617
+ end
618
+
619
+ result
620
+ end
621
+
622
+ promise.execute
623
+ end
624
+
625
+ #
626
+ # List domain topics.
627
+ #
628
+ # List all the topics in a domain.
629
+ #
630
+ # @param resource_group_name [String] The name of the resource group within the
631
+ # user's subscription.
632
+ # @param domain_name [String] Domain name.
633
+ # @param filter [String] Filter the results using OData syntax.
634
+ # @param top [Integer] The number of results to return.
635
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
636
+ # will be added to the HTTP request.
637
+ #
638
+ # @return [DomainTopicsListResult] which provide lazy access to pages of the
639
+ # response.
640
+ #
641
+ def list_by_domain_as_lazy(resource_group_name, domain_name, filter:nil, top:nil, custom_headers:nil)
642
+ response = list_by_domain_async(resource_group_name, domain_name, filter:filter, top:top, custom_headers:custom_headers).value!
643
+ unless response.nil?
644
+ page = response.body
645
+ page.next_method = Proc.new do |next_page_link|
646
+ list_by_domain_next_async(next_page_link, custom_headers:custom_headers)
647
+ end
648
+ page
649
+ end
650
+ end
651
+
652
+ end
653
+ end