@azure/arm-postgresql-flexible 8.1.0-alpha.20250718.1 → 8.1.0-alpha.20250721.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (251) hide show
  1. package/dist/browser/lroImpl.js +7 -3
  2. package/dist/browser/lroImpl.js.map +1 -1
  3. package/dist/browser/models/mappers.js +395 -183
  4. package/dist/browser/models/mappers.js.map +1 -1
  5. package/dist/browser/operations/administrators.js +45 -52
  6. package/dist/browser/operations/administrators.js.map +1 -1
  7. package/dist/browser/operations/backups.js +45 -52
  8. package/dist/browser/operations/backups.js.map +1 -1
  9. package/dist/browser/operations/checkNameAvailability.js +1 -0
  10. package/dist/browser/operations/checkNameAvailability.js.map +1 -1
  11. package/dist/browser/operations/checkNameAvailabilityWithLocation.js +1 -0
  12. package/dist/browser/operations/checkNameAvailabilityWithLocation.js.map +1 -1
  13. package/dist/browser/operations/configurations.js +45 -52
  14. package/dist/browser/operations/configurations.js.map +1 -1
  15. package/dist/browser/operations/databases.js +45 -52
  16. package/dist/browser/operations/databases.js.map +1 -1
  17. package/dist/browser/operations/firewallRules.js +45 -52
  18. package/dist/browser/operations/firewallRules.js.map +1 -1
  19. package/dist/browser/operations/flexibleServer.js +12 -6
  20. package/dist/browser/operations/flexibleServer.js.map +1 -1
  21. package/dist/browser/operations/getPrivateDnsZoneSuffix.js +1 -0
  22. package/dist/browser/operations/getPrivateDnsZoneSuffix.js.map +1 -1
  23. package/dist/browser/operations/locationBasedCapabilities.js +23 -40
  24. package/dist/browser/operations/locationBasedCapabilities.js.map +1 -1
  25. package/dist/browser/operations/logFiles.js +23 -40
  26. package/dist/browser/operations/logFiles.js.map +1 -1
  27. package/dist/browser/operations/ltrBackupOperations.js +23 -40
  28. package/dist/browser/operations/ltrBackupOperations.js.map +1 -1
  29. package/dist/browser/operations/migrations.js +23 -40
  30. package/dist/browser/operations/migrations.js.map +1 -1
  31. package/dist/browser/operations/operations.js +23 -40
  32. package/dist/browser/operations/operations.js.map +1 -1
  33. package/dist/browser/operations/privateEndpointConnectionOperations.js +23 -12
  34. package/dist/browser/operations/privateEndpointConnectionOperations.js.map +1 -1
  35. package/dist/browser/operations/privateEndpointConnections.js +23 -40
  36. package/dist/browser/operations/privateEndpointConnections.js.map +1 -1
  37. package/dist/browser/operations/privateLinkResources.js +23 -40
  38. package/dist/browser/operations/privateLinkResources.js.map +1 -1
  39. package/dist/browser/operations/quotaUsages.js +23 -40
  40. package/dist/browser/operations/quotaUsages.js.map +1 -1
  41. package/dist/browser/operations/replicas.js +10 -27
  42. package/dist/browser/operations/replicas.js.map +1 -1
  43. package/dist/browser/operations/serverCapabilities.js +23 -40
  44. package/dist/browser/operations/serverCapabilities.js.map +1 -1
  45. package/dist/browser/operations/serverThreatProtectionSettings.js +34 -46
  46. package/dist/browser/operations/serverThreatProtectionSettings.js.map +1 -1
  47. package/dist/browser/operations/servers.js +111 -115
  48. package/dist/browser/operations/servers.js.map +1 -1
  49. package/dist/browser/operations/tuningConfiguration.js +89 -103
  50. package/dist/browser/operations/tuningConfiguration.js.map +1 -1
  51. package/dist/browser/operations/tuningIndex.js +23 -40
  52. package/dist/browser/operations/tuningIndex.js.map +1 -1
  53. package/dist/browser/operations/tuningOptions.js +23 -40
  54. package/dist/browser/operations/tuningOptions.js.map +1 -1
  55. package/dist/browser/operations/virtualEndpoints.js +56 -58
  56. package/dist/browser/operations/virtualEndpoints.js.map +1 -1
  57. package/dist/browser/operations/virtualNetworkSubnetUsage.js +1 -0
  58. package/dist/browser/operations/virtualNetworkSubnetUsage.js.map +1 -1
  59. package/dist/browser/pagingHelper.js +2 -4
  60. package/dist/browser/pagingHelper.js.map +1 -1
  61. package/dist/browser/postgreSQLManagementFlexibleServerClient.js +39 -5
  62. package/dist/browser/postgreSQLManagementFlexibleServerClient.js.map +1 -1
  63. package/dist/commonjs/lroImpl.js +7 -3
  64. package/dist/commonjs/lroImpl.js.map +1 -1
  65. package/dist/commonjs/models/mappers.js +395 -183
  66. package/dist/commonjs/models/mappers.js.map +1 -1
  67. package/dist/commonjs/operations/administrators.js +45 -51
  68. package/dist/commonjs/operations/administrators.js.map +1 -1
  69. package/dist/commonjs/operations/backups.js +45 -51
  70. package/dist/commonjs/operations/backups.js.map +1 -1
  71. package/dist/commonjs/operations/checkNameAvailability.js +1 -0
  72. package/dist/commonjs/operations/checkNameAvailability.js.map +1 -1
  73. package/dist/commonjs/operations/checkNameAvailabilityWithLocation.js +1 -0
  74. package/dist/commonjs/operations/checkNameAvailabilityWithLocation.js.map +1 -1
  75. package/dist/commonjs/operations/configurations.js +45 -51
  76. package/dist/commonjs/operations/configurations.js.map +1 -1
  77. package/dist/commonjs/operations/databases.js +45 -51
  78. package/dist/commonjs/operations/databases.js.map +1 -1
  79. package/dist/commonjs/operations/firewallRules.js +45 -51
  80. package/dist/commonjs/operations/firewallRules.js.map +1 -1
  81. package/dist/commonjs/operations/flexibleServer.js +12 -6
  82. package/dist/commonjs/operations/flexibleServer.js.map +1 -1
  83. package/dist/commonjs/operations/getPrivateDnsZoneSuffix.js +1 -0
  84. package/dist/commonjs/operations/getPrivateDnsZoneSuffix.js.map +1 -1
  85. package/dist/commonjs/operations/locationBasedCapabilities.js +23 -39
  86. package/dist/commonjs/operations/locationBasedCapabilities.js.map +1 -1
  87. package/dist/commonjs/operations/logFiles.js +23 -39
  88. package/dist/commonjs/operations/logFiles.js.map +1 -1
  89. package/dist/commonjs/operations/ltrBackupOperations.js +23 -39
  90. package/dist/commonjs/operations/ltrBackupOperations.js.map +1 -1
  91. package/dist/commonjs/operations/migrations.js +23 -39
  92. package/dist/commonjs/operations/migrations.js.map +1 -1
  93. package/dist/commonjs/operations/operations.js +23 -39
  94. package/dist/commonjs/operations/operations.js.map +1 -1
  95. package/dist/commonjs/operations/privateEndpointConnectionOperations.js +23 -12
  96. package/dist/commonjs/operations/privateEndpointConnectionOperations.js.map +1 -1
  97. package/dist/commonjs/operations/privateEndpointConnections.js +23 -39
  98. package/dist/commonjs/operations/privateEndpointConnections.js.map +1 -1
  99. package/dist/commonjs/operations/privateLinkResources.js +23 -39
  100. package/dist/commonjs/operations/privateLinkResources.js.map +1 -1
  101. package/dist/commonjs/operations/quotaUsages.js +23 -39
  102. package/dist/commonjs/operations/quotaUsages.js.map +1 -1
  103. package/dist/commonjs/operations/replicas.js +10 -26
  104. package/dist/commonjs/operations/replicas.js.map +1 -1
  105. package/dist/commonjs/operations/serverCapabilities.js +23 -39
  106. package/dist/commonjs/operations/serverCapabilities.js.map +1 -1
  107. package/dist/commonjs/operations/serverThreatProtectionSettings.js +34 -45
  108. package/dist/commonjs/operations/serverThreatProtectionSettings.js.map +1 -1
  109. package/dist/commonjs/operations/servers.js +111 -114
  110. package/dist/commonjs/operations/servers.js.map +1 -1
  111. package/dist/commonjs/operations/tuningConfiguration.js +89 -102
  112. package/dist/commonjs/operations/tuningConfiguration.js.map +1 -1
  113. package/dist/commonjs/operations/tuningIndex.js +23 -39
  114. package/dist/commonjs/operations/tuningIndex.js.map +1 -1
  115. package/dist/commonjs/operations/tuningOptions.js +23 -39
  116. package/dist/commonjs/operations/tuningOptions.js.map +1 -1
  117. package/dist/commonjs/operations/virtualEndpoints.js +56 -57
  118. package/dist/commonjs/operations/virtualEndpoints.js.map +1 -1
  119. package/dist/commonjs/operations/virtualNetworkSubnetUsage.js +1 -0
  120. package/dist/commonjs/operations/virtualNetworkSubnetUsage.js.map +1 -1
  121. package/dist/commonjs/pagingHelper.js +2 -4
  122. package/dist/commonjs/pagingHelper.js.map +1 -1
  123. package/dist/commonjs/postgreSQLManagementFlexibleServerClient.js +39 -5
  124. package/dist/commonjs/postgreSQLManagementFlexibleServerClient.js.map +1 -1
  125. package/dist/commonjs/tsdoc-metadata.json +11 -11
  126. package/dist/esm/lroImpl.js +7 -3
  127. package/dist/esm/lroImpl.js.map +1 -1
  128. package/dist/esm/models/mappers.js +395 -183
  129. package/dist/esm/models/mappers.js.map +1 -1
  130. package/dist/esm/operations/administrators.js +45 -52
  131. package/dist/esm/operations/administrators.js.map +1 -1
  132. package/dist/esm/operations/backups.js +45 -52
  133. package/dist/esm/operations/backups.js.map +1 -1
  134. package/dist/esm/operations/checkNameAvailability.js +1 -0
  135. package/dist/esm/operations/checkNameAvailability.js.map +1 -1
  136. package/dist/esm/operations/checkNameAvailabilityWithLocation.js +1 -0
  137. package/dist/esm/operations/checkNameAvailabilityWithLocation.js.map +1 -1
  138. package/dist/esm/operations/configurations.js +45 -52
  139. package/dist/esm/operations/configurations.js.map +1 -1
  140. package/dist/esm/operations/databases.js +45 -52
  141. package/dist/esm/operations/databases.js.map +1 -1
  142. package/dist/esm/operations/firewallRules.js +45 -52
  143. package/dist/esm/operations/firewallRules.js.map +1 -1
  144. package/dist/esm/operations/flexibleServer.js +12 -6
  145. package/dist/esm/operations/flexibleServer.js.map +1 -1
  146. package/dist/esm/operations/getPrivateDnsZoneSuffix.js +1 -0
  147. package/dist/esm/operations/getPrivateDnsZoneSuffix.js.map +1 -1
  148. package/dist/esm/operations/locationBasedCapabilities.js +23 -40
  149. package/dist/esm/operations/locationBasedCapabilities.js.map +1 -1
  150. package/dist/esm/operations/logFiles.js +23 -40
  151. package/dist/esm/operations/logFiles.js.map +1 -1
  152. package/dist/esm/operations/ltrBackupOperations.js +23 -40
  153. package/dist/esm/operations/ltrBackupOperations.js.map +1 -1
  154. package/dist/esm/operations/migrations.js +23 -40
  155. package/dist/esm/operations/migrations.js.map +1 -1
  156. package/dist/esm/operations/operations.js +23 -40
  157. package/dist/esm/operations/operations.js.map +1 -1
  158. package/dist/esm/operations/privateEndpointConnectionOperations.js +23 -12
  159. package/dist/esm/operations/privateEndpointConnectionOperations.js.map +1 -1
  160. package/dist/esm/operations/privateEndpointConnections.js +23 -40
  161. package/dist/esm/operations/privateEndpointConnections.js.map +1 -1
  162. package/dist/esm/operations/privateLinkResources.js +23 -40
  163. package/dist/esm/operations/privateLinkResources.js.map +1 -1
  164. package/dist/esm/operations/quotaUsages.js +23 -40
  165. package/dist/esm/operations/quotaUsages.js.map +1 -1
  166. package/dist/esm/operations/replicas.js +10 -27
  167. package/dist/esm/operations/replicas.js.map +1 -1
  168. package/dist/esm/operations/serverCapabilities.js +23 -40
  169. package/dist/esm/operations/serverCapabilities.js.map +1 -1
  170. package/dist/esm/operations/serverThreatProtectionSettings.js +34 -46
  171. package/dist/esm/operations/serverThreatProtectionSettings.js.map +1 -1
  172. package/dist/esm/operations/servers.js +111 -115
  173. package/dist/esm/operations/servers.js.map +1 -1
  174. package/dist/esm/operations/tuningConfiguration.js +89 -103
  175. package/dist/esm/operations/tuningConfiguration.js.map +1 -1
  176. package/dist/esm/operations/tuningIndex.js +23 -40
  177. package/dist/esm/operations/tuningIndex.js.map +1 -1
  178. package/dist/esm/operations/tuningOptions.js +23 -40
  179. package/dist/esm/operations/tuningOptions.js.map +1 -1
  180. package/dist/esm/operations/virtualEndpoints.js +56 -58
  181. package/dist/esm/operations/virtualEndpoints.js.map +1 -1
  182. package/dist/esm/operations/virtualNetworkSubnetUsage.js +1 -0
  183. package/dist/esm/operations/virtualNetworkSubnetUsage.js.map +1 -1
  184. package/dist/esm/pagingHelper.js +2 -4
  185. package/dist/esm/pagingHelper.js.map +1 -1
  186. package/dist/esm/postgreSQLManagementFlexibleServerClient.js +39 -5
  187. package/dist/esm/postgreSQLManagementFlexibleServerClient.js.map +1 -1
  188. package/dist/react-native/lroImpl.js +7 -3
  189. package/dist/react-native/lroImpl.js.map +1 -1
  190. package/dist/react-native/models/mappers.js +395 -183
  191. package/dist/react-native/models/mappers.js.map +1 -1
  192. package/dist/react-native/operations/administrators.js +45 -52
  193. package/dist/react-native/operations/administrators.js.map +1 -1
  194. package/dist/react-native/operations/backups.js +45 -52
  195. package/dist/react-native/operations/backups.js.map +1 -1
  196. package/dist/react-native/operations/checkNameAvailability.js +1 -0
  197. package/dist/react-native/operations/checkNameAvailability.js.map +1 -1
  198. package/dist/react-native/operations/checkNameAvailabilityWithLocation.js +1 -0
  199. package/dist/react-native/operations/checkNameAvailabilityWithLocation.js.map +1 -1
  200. package/dist/react-native/operations/configurations.js +45 -52
  201. package/dist/react-native/operations/configurations.js.map +1 -1
  202. package/dist/react-native/operations/databases.js +45 -52
  203. package/dist/react-native/operations/databases.js.map +1 -1
  204. package/dist/react-native/operations/firewallRules.js +45 -52
  205. package/dist/react-native/operations/firewallRules.js.map +1 -1
  206. package/dist/react-native/operations/flexibleServer.js +12 -6
  207. package/dist/react-native/operations/flexibleServer.js.map +1 -1
  208. package/dist/react-native/operations/getPrivateDnsZoneSuffix.js +1 -0
  209. package/dist/react-native/operations/getPrivateDnsZoneSuffix.js.map +1 -1
  210. package/dist/react-native/operations/locationBasedCapabilities.js +23 -40
  211. package/dist/react-native/operations/locationBasedCapabilities.js.map +1 -1
  212. package/dist/react-native/operations/logFiles.js +23 -40
  213. package/dist/react-native/operations/logFiles.js.map +1 -1
  214. package/dist/react-native/operations/ltrBackupOperations.js +23 -40
  215. package/dist/react-native/operations/ltrBackupOperations.js.map +1 -1
  216. package/dist/react-native/operations/migrations.js +23 -40
  217. package/dist/react-native/operations/migrations.js.map +1 -1
  218. package/dist/react-native/operations/operations.js +23 -40
  219. package/dist/react-native/operations/operations.js.map +1 -1
  220. package/dist/react-native/operations/privateEndpointConnectionOperations.js +23 -12
  221. package/dist/react-native/operations/privateEndpointConnectionOperations.js.map +1 -1
  222. package/dist/react-native/operations/privateEndpointConnections.js +23 -40
  223. package/dist/react-native/operations/privateEndpointConnections.js.map +1 -1
  224. package/dist/react-native/operations/privateLinkResources.js +23 -40
  225. package/dist/react-native/operations/privateLinkResources.js.map +1 -1
  226. package/dist/react-native/operations/quotaUsages.js +23 -40
  227. package/dist/react-native/operations/quotaUsages.js.map +1 -1
  228. package/dist/react-native/operations/replicas.js +10 -27
  229. package/dist/react-native/operations/replicas.js.map +1 -1
  230. package/dist/react-native/operations/serverCapabilities.js +23 -40
  231. package/dist/react-native/operations/serverCapabilities.js.map +1 -1
  232. package/dist/react-native/operations/serverThreatProtectionSettings.js +34 -46
  233. package/dist/react-native/operations/serverThreatProtectionSettings.js.map +1 -1
  234. package/dist/react-native/operations/servers.js +111 -115
  235. package/dist/react-native/operations/servers.js.map +1 -1
  236. package/dist/react-native/operations/tuningConfiguration.js +89 -103
  237. package/dist/react-native/operations/tuningConfiguration.js.map +1 -1
  238. package/dist/react-native/operations/tuningIndex.js +23 -40
  239. package/dist/react-native/operations/tuningIndex.js.map +1 -1
  240. package/dist/react-native/operations/tuningOptions.js +23 -40
  241. package/dist/react-native/operations/tuningOptions.js.map +1 -1
  242. package/dist/react-native/operations/virtualEndpoints.js +56 -58
  243. package/dist/react-native/operations/virtualEndpoints.js.map +1 -1
  244. package/dist/react-native/operations/virtualNetworkSubnetUsage.js +1 -0
  245. package/dist/react-native/operations/virtualNetworkSubnetUsage.js.map +1 -1
  246. package/dist/react-native/pagingHelper.js +2 -4
  247. package/dist/react-native/pagingHelper.js.map +1 -1
  248. package/dist/react-native/postgreSQLManagementFlexibleServerClient.js +39 -5
  249. package/dist/react-native/postgreSQLManagementFlexibleServerClient.js.map +1 -1
  250. package/package.json +2 -2
  251. package/review/arm-postgresql-flexible-node.api.md +2723 -2723
@@ -1 +1 @@
1
- {"version":3,"file":"privateEndpointConnectionOperations.js","sourceRoot":"","sources":["../../../src/operations/privateEndpointConnectionOperations.ts"],"names":[],"mappings":";AAAA;;;;;;GAMG;;;;AAGH,uEAAiD;AACjD,sEAAgD;AAChD,4EAAsD;AAGtD,8CAAmD;AACnD,8CAA8C;AAS9C,uEAAuE;AACvE,MAAa,uCAAuC;IAKlD;;;OAGG;IACH,YAAY,MAAgD;QAC1D,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC;IACvB,CAAC;IAED;;;;;;;OAOG;IACH,KAAK,CAAC,WAAW,CACf,iBAAyB,EACzB,UAAkB,EAClB,6BAAqC,EACrC,UAAqC,EACrC,OAAuD;QAOvD,MAAM,mBAAmB,GAAG,KAAK,EAC/B,IAAmC,EACnC,IAA8B,E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,gBAAgB,EAAE,CAAC,UAAU,CAAC,MAAM,CAAC;IACrC,UAAU;CACX,CAAC","sourcesContent":["/*\n * Copyright (c) Microsoft Corporation.\n * Licensed under the MIT License.\n *\n * Code generated by Microsoft (R) AutoRest Code Generator.\n * Changes may cause incorrect behavior and will be lost if the code is regenerated.\n */\n\nimport type { PrivateEndpointConnectionOperations } from \"../operationsInterfaces/index.js\";\nimport * as coreClient from \"@azure/core-client\";\nimport * as Mappers from \"../models/mappers.js\";\nimport * as Parameters from \"../models/parameters.js\";\nimport type { PostgreSQLManagementFlexibleServerClient } from \"../postgreSQLManagementFlexibleServerClient.js\";\nimport type { SimplePollerLike, OperationState } from \"@azure/core-lro\";\nimport { createHttpPoller } from \"@azure/core-lro\";\nimport { createLroSpec } from \"../lroImpl.js\";\nimport type {\n PrivateEndpointConnection,\n PrivateEndpointConnectionUpdateOptionalParams,\n PrivateEndpointConnectionUpdateResponse,\n PrivateEndpointConnectionDeleteOptionalParams,\n PrivateEndpointConnectionDeleteResponse,\n} from \"../models/index.js\";\n\n/** Class containing PrivateEndpointConnectionOperations operations. */\nexport class PrivateEndpointConnectionOperationsImpl\n implements PrivateEndpointConnectionOperations\n{\n private readonly client: PostgreSQLManagementFlexibleServerClient;\n\n /**\n * Initialize a new instance of the class PrivateEndpointConnectionOperations class.\n * @param client Reference to the service client\n */\n constructor(client: PostgreSQLManagementFlexibleServerClient) {\n this.client = client;\n }\n\n /**\n * Approve or reject a private endpoint connection with a given name.\n * @param resourceGroupName The name of the resource group. The name is case insensitive.\n * @param serverName The name of the server.\n * @param privateEndpointConnectionName The name of the private endpoint connection.\n * @param parameters The required parameters for updating private endpoint connection.\n * @param options The options parameters.\n */\n async beginUpdate(\n resourceGroupName: string,\n serverName: string,\n privateEndpointConnectionName: string,\n parameters: PrivateEndpointConnection,\n options?: PrivateEndpointConnectionUpdateOptionalParams,\n ): Promise<\n SimplePollerLike<\n OperationState<PrivateEndpointConnectionUpdateResponse>,\n PrivateEndpointConnectionUpdateResponse\n >\n > {\n const directSendOperation = async (\n args: coreClient.OperationArguments,\n spec: coreClient.OperationSpec,\n ): Promise<PrivateEndpointConnectionUpdateResponse> => {\n return this.client.sendOperationRequest(args, spec);\n };\n const sendOperationFn = async (\n args: coreClient.OperationArguments,\n spec: coreClient.OperationSpec,\n ) => {\n let currentRawResponse: coreClient.FullOperationResponse | undefined = undefined;\n const providedCallback = args.options?.onResponse;\n const callback: coreClient.RawResponseCallback = (\n rawResponse: coreClient.FullOperationResponse,\n flatResponse: unknown,\n ) => {\n currentRawResponse = rawResponse;\n providedCallback?.(rawResponse, flatResponse);\n };\n const updatedArgs = {\n ...args,\n options: {\n ...args.options,\n onResponse: callback,\n },\n };\n const flatResponse = await directSendOperation(updatedArgs, spec);\n return {\n flatResponse,\n rawResponse: {\n statusCode: currentRawResponse!.status,\n body: currentRawResponse!.parsedBody,\n headers: currentRawResponse!.headers.toJSON(),\n },\n };\n };\n\n const lro = createLroSpec({\n sendOperationFn,\n args: {\n resourceGroupName,\n serverName,\n privateEndpointConnectionName,\n parameters,\n options,\n },\n spec: updateOperationSpec,\n });\n const poller = await createHttpPoller<\n PrivateEndpointConnectionUpdateResponse,\n OperationState<PrivateEndpointConnectionUpdateResponse>\n >(lro, {\n restoreFrom: options?.resumeFrom,\n intervalInMs: options?.updateIntervalInMs,\n });\n await poller.poll();\n return poller;\n }\n\n /**\n * Approve or reject a private endpoint connection with a given name.\n * @param resourceGroupName The name of the resource group. The name is case insensitive.\n * @param serverName The name of the server.\n * @param privateEndpointConnectionName The name of the private endpoint connection.\n * @param parameters The required parameters for updating private endpoint connection.\n * @param options The options parameters.\n */\n async beginUpdateAndWait(\n resourceGroupName: string,\n serverName: string,\n privateEndpointConnectionName: string,\n parameters: PrivateEndpointConnection,\n options?: PrivateEndpointConnectionUpdateOptionalParams,\n ): Promise<PrivateEndpointConnectionUpdateResponse> {\n const poller = await this.beginUpdate(\n resourceGroupName,\n serverName,\n privateEndpointConnectionName,\n parameters,\n options,\n );\n return poller.pollUntilDone();\n }\n\n /**\n * Deletes a private endpoint connection with a given name.\n * @param resourceGroupName The name of the resource group. The name is case insensitive.\n * @param serverName The name of the server.\n * @param privateEndpointConnectionName The name of the private endpoint connection.\n * @param options The options parameters.\n */\n async beginDelete(\n resourceGroupName: string,\n serverName: string,\n privateEndpointConnectionName: string,\n options?: PrivateEndpointConnectionDeleteOptionalParams,\n ): Promise<\n SimplePollerLike<\n OperationState<PrivateEndpointConnectionDeleteResponse>,\n PrivateEndpointConnectionDeleteResponse\n >\n > {\n const directSendOperation = async (\n args: coreClient.OperationArguments,\n spec: coreClient.OperationSpec,\n ): Promise<PrivateEndpointConnectionDeleteResponse> => {\n return this.client.sendOperationRequest(args, spec);\n };\n const sendOperationFn = async (\n args: coreClient.OperationArguments,\n spec: coreClient.OperationSpec,\n ) => {\n let currentRawResponse: coreClient.FullOperationResponse | undefined = undefined;\n const providedCallback = args.options?.onResponse;\n const callback: coreClient.RawResponseCallback = (\n rawResponse: coreClient.FullOperationResponse,\n flatResponse: unknown,\n ) => {\n currentRawResponse = rawResponse;\n providedCallback?.(rawResponse, flatResponse);\n };\n const updatedArgs = {\n ...args,\n options: {\n ...args.options,\n onResponse: callback,\n },\n };\n const flatResponse = await directSendOperation(updatedArgs, spec);\n return {\n flatResponse,\n rawResponse: {\n statusCode: currentRawResponse!.status,\n body: currentRawResponse!.parsedBody,\n headers: currentRawResponse!.headers.toJSON(),\n },\n };\n };\n\n const lro = createLroSpec({\n sendOperationFn,\n args: {\n resourceGroupName,\n serverName,\n privateEndpointConnectionName,\n options,\n },\n spec: deleteOperationSpec,\n });\n const poller = await createHttpPoller<\n PrivateEndpointConnectionDeleteResponse,\n OperationState<PrivateEndpointConnectionDeleteResponse>\n >(lro, {\n restoreFrom: options?.resumeFrom,\n intervalInMs: options?.updateIntervalInMs,\n resourceLocationConfig: \"azure-async-operation\",\n });\n await poller.poll();\n return poller;\n }\n\n /**\n * Deletes a private endpoint connection with a given name.\n * @param resourceGroupName The name of the resource group. The name is case insensitive.\n * @param serverName The name of the server.\n * @param privateEndpointConnectionName The name of the private endpoint connection.\n * @param options The options parameters.\n */\n async beginDeleteAndWait(\n resourceGroupName: string,\n serverName: string,\n privateEndpointConnectionName: string,\n options?: PrivateEndpointConnectionDeleteOptionalParams,\n ): Promise<PrivateEndpointConnectionDeleteResponse> {\n const poller = await this.beginDelete(\n resourceGroupName,\n serverName,\n privateEndpointConnectionName,\n options,\n );\n return poller.pollUntilDone();\n }\n}\n// Operation Specifications\nconst serializer = coreClient.createSerializer(Mappers, /* isXml */ false);\n\nconst updateOperationSpec: coreClient.OperationSpec = {\n path: \"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL/flexibleServers/{serverName}/privateEndpointConnections/{privateEndpointConnectionName}\",\n httpMethod: \"PUT\",\n responses: {\n 200: {\n bodyMapper: Mappers.PrivateEndpointConnection,\n },\n 201: {\n bodyMapper: Mappers.PrivateEndpointConnection,\n },\n 202: {\n bodyMapper: Mappers.PrivateEndpointConnection,\n },\n 204: {\n bodyMapper: Mappers.PrivateEndpointConnection,\n },\n default: {\n bodyMapper: Mappers.ErrorResponse,\n },\n },\n requestBody: Parameters.parameters13,\n queryParameters: [Parameters.apiVersion],\n urlParameters: [\n Parameters.$host,\n Parameters.subscriptionId,\n Parameters.resourceGroupName,\n Parameters.serverName,\n Parameters.privateEndpointConnectionName,\n ],\n headerParameters: [Parameters.contentType, Parameters.accept],\n mediaType: \"json\",\n serializer,\n};\nconst deleteOperationSpec: coreClient.OperationSpec = {\n path: \"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL/flexibleServers/{serverName}/privateEndpointConnections/{privateEndpointConnectionName}\",\n httpMethod: \"DELETE\",\n responses: {\n 200: {\n headersMapper: Mappers.PrivateEndpointConnectionDeleteHeaders,\n },\n 201: {\n headersMapper: Mappers.PrivateEndpointConnectionDeleteHeaders,\n },\n 202: {\n headersMapper: Mappers.PrivateEndpointConnectionDeleteHeaders,\n },\n 204: {\n headersMapper: Mappers.PrivateEndpointConnectionDeleteHeaders,\n },\n default: {\n bodyMapper: Mappers.ErrorResponse,\n },\n },\n queryParameters: [Parameters.apiVersion],\n urlParameters: [\n Parameters.$host,\n Parameters.subscriptionId,\n Parameters.resourceGroupName,\n Parameters.serverName,\n Parameters.privateEndpointConnectionName,\n ],\n headerParameters: [Parameters.accept],\n serializer,\n};\n"]}
1
+ {"version":3,"file":"privateEndpointConnectionOperations.js","sourceRoot":"","sources":["../../../src/operations/privateEndpointConnectionOperations.ts"],"names":[],"mappings":";AAAA;;;;;;GAMG;;;;AAGH,uEAAiD;AACjD,sEAAgD;AAChD,4EAAsD;AAGtD,8CAAmD;AACnD,8CAA8C;AAS9C,uEAAuE;AACvE,MAAa,uCAAuC;IAGjC,MAAM,CAA2C;IAElE;;;OAGG;IACH,YAAY,MAAgD;QAC1D,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC;IACvB,CAAC;IAED;;;;;;;OAOG;IACH,KAAK,CAAC,WAAW,CACf,iBAAyB,EACzB,UAAkB,EAClB,6BAAqC,EACrC,UAAqC,EACrC,OAAuD;QAOvD,MAAM,mBAAmB,GAAG,KAAK,EAC/B,IAAmC,EACnC,IAA8B,EACoB,EAAE;YACpD,OAAO,IAAI,CAAC,MAAM,CAAC,oBAAoB,CAAC,IAAI,EAAE,IAAI,CAAC,CAAC;QACtD,CAAC,CAAC;QACF,MAAM,eAAe,GAAG,KAAK,EAC3B,IAAmC,EACnC,IAA8B,EAC9B,EAAE;YACF,IAAI,kBAAkB,GAAiD,SAAS,CAAC;YACjF,MAAM,gBAAgB,GAAG,IAAI,CAAC,OAAO,EAAE,UAAU,CAAC;YAClD,MAAM,QAAQ,GAAmC,CAC/C,WAA6C,EAC7C,YAAqB,EACrB,EAAE;gBACF,kBAAkB,GAAG,WAAW,CAAC;gBACjC,gBAAgB,EAAE,CAAC,WAAW,EAAE,YAAY,C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U,CAAC,WAAW,EAAE,UAAU,CAAC,MAAM,CAAC;IAC7D,SAAS,EAAE,MAAM;IACjB,UAAU;CACX,CAAC;AACF,MAAM,mBAAmB,GAA6B;IACpD,IAAI,EAAE,gMAAgM;IACtM,UAAU,EAAE,QAAQ;IACpB,SAAS,EAAE;QACT,GAAG,EAAE;YACH,aAAa,EAAE,OAAO,CAAC,sCAAsC;SAC9D;QACD,GAAG,EAAE;YACH,aAAa,EAAE,OAAO,CAAC,sCAAsC;SAC9D;QACD,GAAG,EAAE;YACH,aAAa,EAAE,OAAO,CAAC,sCAAsC;SAC9D;QACD,GAAG,EAAE;YACH,aAAa,EAAE,OAAO,CAAC,sCAAsC;SAC9D;QACD,OAAO,EAAE;YACP,UAAU,EAAE,OAAO,CAAC,aAAa;SAClC;KACF;IACD,eAAe,EAAE,CAAC,UAAU,CAAC,UAAU,CAAC;IACxC,aAAa,EAAE;QACb,UAAU,CAAC,KAAK;QAChB,UAAU,CAAC,cAAc;QACzB,UAAU,CAAC,iBAAiB;QAC5B,UAAU,CAAC,UAAU;QACrB,UAAU,CAAC,6BAA6B;KACzC;IACD,gBAAgB,EAAE,CAAC,UAAU,CAAC,MAAM,CAAC;IACrC,UAAU;CACX,CAAC","sourcesContent":["/*\n * Copyright (c) Microsoft Corporation.\n * Licensed under the MIT License.\n *\n * Code generated by Microsoft (R) AutoRest Code Generator.\n * Changes may cause incorrect behavior and will be lost if the code is regenerated.\n */\n\nimport type { PrivateEndpointConnectionOperations } from \"../operationsInterfaces/index.js\";\nimport * as coreClient from \"@azure/core-client\";\nimport * as Mappers from \"../models/mappers.js\";\nimport * as Parameters from \"../models/parameters.js\";\nimport type { PostgreSQLManagementFlexibleServerClient } from \"../postgreSQLManagementFlexibleServerClient.js\";\nimport type { SimplePollerLike, OperationState } from \"@azure/core-lro\";\nimport { createHttpPoller } from \"@azure/core-lro\";\nimport { createLroSpec } from \"../lroImpl.js\";\nimport type {\n PrivateEndpointConnection,\n PrivateEndpointConnectionUpdateOptionalParams,\n PrivateEndpointConnectionUpdateResponse,\n PrivateEndpointConnectionDeleteOptionalParams,\n PrivateEndpointConnectionDeleteResponse,\n} from \"../models/index.js\";\n\n/** Class containing PrivateEndpointConnectionOperations operations. */\nexport class PrivateEndpointConnectionOperationsImpl\n implements PrivateEndpointConnectionOperations\n{\n private readonly client: PostgreSQLManagementFlexibleServerClient;\n\n /**\n * Initialize a new instance of the class PrivateEndpointConnectionOperations class.\n * @param client Reference to the service client\n */\n constructor(client: PostgreSQLManagementFlexibleServerClient) {\n this.client = client;\n }\n\n /**\n * Approve or reject a private endpoint connection with a given name.\n * @param resourceGroupName The name of the resource group. The name is case insensitive.\n * @param serverName The name of the server.\n * @param privateEndpointConnectionName The name of the private endpoint connection.\n * @param parameters The required parameters for updating private endpoint connection.\n * @param options The options parameters.\n */\n async beginUpdate(\n resourceGroupName: string,\n serverName: string,\n privateEndpointConnectionName: string,\n parameters: PrivateEndpointConnection,\n options?: PrivateEndpointConnectionUpdateOptionalParams,\n ): Promise<\n SimplePollerLike<\n OperationState<PrivateEndpointConnectionUpdateResponse>,\n PrivateEndpointConnectionUpdateResponse\n >\n > {\n const directSendOperation = async (\n args: coreClient.OperationArguments,\n spec: coreClient.OperationSpec,\n ): Promise<PrivateEndpointConnectionUpdateResponse> => {\n return this.client.sendOperationRequest(args, spec);\n };\n const sendOperationFn = async (\n args: coreClient.OperationArguments,\n spec: coreClient.OperationSpec,\n ) => {\n let currentRawResponse: coreClient.FullOperationResponse | undefined = undefined;\n const providedCallback = args.options?.onResponse;\n const callback: coreClient.RawResponseCallback = (\n rawResponse: coreClient.FullOperationResponse,\n flatResponse: unknown,\n ) => {\n currentRawResponse = rawResponse;\n providedCallback?.(rawResponse, flatResponse);\n };\n const updatedArgs = {\n ...args,\n options: {\n ...args.options,\n onResponse: callback,\n },\n };\n const flatResponse = await directSendOperation(updatedArgs, spec);\n return {\n flatResponse,\n rawResponse: {\n statusCode: currentRawResponse!.status,\n body: currentRawResponse!.parsedBody,\n headers: currentRawResponse!.headers.toJSON(),\n },\n };\n };\n\n const lro = createLroSpec({\n sendOperationFn,\n args: {\n resourceGroupName,\n serverName,\n privateEndpointConnectionName,\n parameters,\n options,\n },\n spec: updateOperationSpec,\n });\n const poller = await createHttpPoller<\n PrivateEndpointConnectionUpdateResponse,\n OperationState<PrivateEndpointConnectionUpdateResponse>\n >(lro, {\n restoreFrom: options?.resumeFrom,\n intervalInMs: options?.updateIntervalInMs,\n });\n await poller.poll();\n return poller;\n }\n\n /**\n * Approve or reject a private endpoint connection with a given name.\n * @param resourceGroupName The name of the resource group. The name is case insensitive.\n * @param serverName The name of the server.\n * @param privateEndpointConnectionName The name of the private endpoint connection.\n * @param parameters The required parameters for updating private endpoint connection.\n * @param options The options parameters.\n */\n async beginUpdateAndWait(\n resourceGroupName: string,\n serverName: string,\n privateEndpointConnectionName: string,\n parameters: PrivateEndpointConnection,\n options?: PrivateEndpointConnectionUpdateOptionalParams,\n ): Promise<PrivateEndpointConnectionUpdateResponse> {\n const poller = await this.beginUpdate(\n resourceGroupName,\n serverName,\n privateEndpointConnectionName,\n parameters,\n options,\n );\n return poller.pollUntilDone();\n }\n\n /**\n * Deletes a private endpoint connection with a given name.\n * @param resourceGroupName The name of the resource group. The name is case insensitive.\n * @param serverName The name of the server.\n * @param privateEndpointConnectionName The name of the private endpoint connection.\n * @param options The options parameters.\n */\n async beginDelete(\n resourceGroupName: string,\n serverName: string,\n privateEndpointConnectionName: string,\n options?: PrivateEndpointConnectionDeleteOptionalParams,\n ): Promise<\n SimplePollerLike<\n OperationState<PrivateEndpointConnectionDeleteResponse>,\n PrivateEndpointConnectionDeleteResponse\n >\n > {\n const directSendOperation = async (\n args: coreClient.OperationArguments,\n spec: coreClient.OperationSpec,\n ): Promise<PrivateEndpointConnectionDeleteResponse> => {\n return this.client.sendOperationRequest(args, spec);\n };\n const sendOperationFn = async (\n args: coreClient.OperationArguments,\n spec: coreClient.OperationSpec,\n ) => {\n let currentRawResponse: coreClient.FullOperationResponse | undefined = undefined;\n const providedCallback = args.options?.onResponse;\n const callback: coreClient.RawResponseCallback = (\n rawResponse: coreClient.FullOperationResponse,\n flatResponse: unknown,\n ) => {\n currentRawResponse = rawResponse;\n providedCallback?.(rawResponse, flatResponse);\n };\n const updatedArgs = {\n ...args,\n options: {\n ...args.options,\n onResponse: callback,\n },\n };\n const flatResponse = await directSendOperation(updatedArgs, spec);\n return {\n flatResponse,\n rawResponse: {\n statusCode: currentRawResponse!.status,\n body: currentRawResponse!.parsedBody,\n headers: currentRawResponse!.headers.toJSON(),\n },\n };\n };\n\n const lro = createLroSpec({\n sendOperationFn,\n args: {\n resourceGroupName,\n serverName,\n privateEndpointConnectionName,\n options,\n },\n spec: deleteOperationSpec,\n });\n const poller = await createHttpPoller<\n PrivateEndpointConnectionDeleteResponse,\n OperationState<PrivateEndpointConnectionDeleteResponse>\n >(lro, {\n restoreFrom: options?.resumeFrom,\n intervalInMs: options?.updateIntervalInMs,\n resourceLocationConfig: \"azure-async-operation\",\n });\n await poller.poll();\n return poller;\n }\n\n /**\n * Deletes a private endpoint connection with a given name.\n * @param resourceGroupName The name of the resource group. The name is case insensitive.\n * @param serverName The name of the server.\n * @param privateEndpointConnectionName The name of the private endpoint connection.\n * @param options The options parameters.\n */\n async beginDeleteAndWait(\n resourceGroupName: string,\n serverName: string,\n privateEndpointConnectionName: string,\n options?: PrivateEndpointConnectionDeleteOptionalParams,\n ): Promise<PrivateEndpointConnectionDeleteResponse> {\n const poller = await this.beginDelete(\n resourceGroupName,\n serverName,\n privateEndpointConnectionName,\n options,\n );\n return poller.pollUntilDone();\n }\n}\n// Operation Specifications\nconst serializer = coreClient.createSerializer(Mappers, /* isXml */ false);\n\nconst updateOperationSpec: coreClient.OperationSpec = {\n path: \"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL/flexibleServers/{serverName}/privateEndpointConnections/{privateEndpointConnectionName}\",\n httpMethod: \"PUT\",\n responses: {\n 200: {\n bodyMapper: Mappers.PrivateEndpointConnection,\n },\n 201: {\n bodyMapper: Mappers.PrivateEndpointConnection,\n },\n 202: {\n bodyMapper: Mappers.PrivateEndpointConnection,\n },\n 204: {\n bodyMapper: Mappers.PrivateEndpointConnection,\n },\n default: {\n bodyMapper: Mappers.ErrorResponse,\n },\n },\n requestBody: Parameters.parameters13,\n queryParameters: [Parameters.apiVersion],\n urlParameters: [\n Parameters.$host,\n Parameters.subscriptionId,\n Parameters.resourceGroupName,\n Parameters.serverName,\n Parameters.privateEndpointConnectionName,\n ],\n headerParameters: [Parameters.contentType, Parameters.accept],\n mediaType: \"json\",\n serializer,\n};\nconst deleteOperationSpec: coreClient.OperationSpec = {\n path: \"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL/flexibleServers/{serverName}/privateEndpointConnections/{privateEndpointConnectionName}\",\n httpMethod: \"DELETE\",\n responses: {\n 200: {\n headersMapper: Mappers.PrivateEndpointConnectionDeleteHeaders,\n },\n 201: {\n headersMapper: Mappers.PrivateEndpointConnectionDeleteHeaders,\n },\n 202: {\n headersMapper: Mappers.PrivateEndpointConnectionDeleteHeaders,\n },\n 204: {\n headersMapper: Mappers.PrivateEndpointConnectionDeleteHeaders,\n },\n default: {\n bodyMapper: Mappers.ErrorResponse,\n },\n },\n queryParameters: [Parameters.apiVersion],\n urlParameters: [\n Parameters.$host,\n Parameters.subscriptionId,\n Parameters.resourceGroupName,\n Parameters.serverName,\n Parameters.privateEndpointConnectionName,\n ],\n headerParameters: [Parameters.accept],\n serializer,\n};\n"]}
@@ -16,6 +16,7 @@ const Parameters = tslib_1.__importStar(require("../models/parameters.js"));
16
16
  /// <reference lib="esnext.asynciterable" />
17
17
  /** Class containing PrivateEndpointConnections operations. */
18
18
  class PrivateEndpointConnectionsImpl {
19
+ client;
19
20
  /**
20
21
  * Initialize a new instance of the class PrivateEndpointConnections class.
21
22
  * @param client Reference to the service client
@@ -39,52 +40,35 @@ class PrivateEndpointConnectionsImpl {
39
40
  return this;
40
41
  },
41
42
  byPage: (settings) => {
42
- if (settings === null || settings === void 0 ? void 0 : settings.maxPageSize) {
43
+ if (settings?.maxPageSize) {
43
44
  throw new Error("maxPageSize is not supported by this operation.");
44
45
  }
45
46
  return this.listByServerPagingPage(resourceGroupName, serverName, options, settings);
46
47
  },
47
48
  };
48
49
  }
49
- listByServerPagingPage(resourceGroupName, serverName, options, settings) {
50
- return tslib_1.__asyncGenerator(this, arguments, function* listByServerPagingPage_1() {
51
- let result;
52
- let continuationToken = settings === null || settings === void 0 ? void 0 : settings.continuationToken;
53
- if (!continuationToken) {
54
- result = yield tslib_1.__await(this._listByServer(resourceGroupName, serverName, options));
55
- const page = result.value || [];
56
- continuationToken = result.nextLink;
57
- (0, pagingHelper_js_1.setContinuationToken)(page, continuationToken);
58
- yield yield tslib_1.__await(page);
59
- }
60
- while (continuationToken) {
61
- result = yield tslib_1.__await(this._listByServerNext(resourceGroupName, serverName, continuationToken, options));
62
- continuationToken = result.nextLink;
63
- const page = result.value || [];
64
- (0, pagingHelper_js_1.setContinuationToken)(page, continuationToken);
65
- yield yield tslib_1.__await(page);
66
- }
67
- });
50
+ async *listByServerPagingPage(resourceGroupName, serverName, options, settings) {
51
+ let result;
52
+ let continuationToken = settings?.continuationToken;
53
+ if (!continuationToken) {
54
+ result = await this._listByServer(resourceGroupName, serverName, options);
55
+ const page = result.value || [];
56
+ continuationToken = result.nextLink;
57
+ (0, pagingHelper_js_1.setContinuationToken)(page, continuationToken);
58
+ yield page;
59
+ }
60
+ while (continuationToken) {
61
+ result = await this._listByServerNext(resourceGroupName, serverName, continuationToken, options);
62
+ continuationToken = result.nextLink;
63
+ const page = result.value || [];
64
+ (0, pagingHelper_js_1.setContinuationToken)(page, continuationToken);
65
+ yield page;
66
+ }
68
67
  }
69
- listByServerPagingAll(resourceGroupName, serverName, options) {
70
- return tslib_1.__asyncGenerator(this, arguments, function* listByServerPagingAll_1() {
71
- var _a, e_1, _b, _c;
72
- try {
73
- for (var _d = true, _e = tslib_1.__asyncValues(this.listByServerPagingPage(resourceGroupName, serverName, options)), _f; _f = yield tslib_1.__await(_e.next()), _a = _f.done, !_a; _d = true) {
74
- _c = _f.value;
75
- _d = false;
76
- const page = _c;
77
- yield tslib_1.__await(yield* tslib_1.__asyncDelegator(tslib_1.__asyncValues(page)));
78
- }
79
- }
80
- catch (e_1_1) { e_1 = { error: e_1_1 }; }
81
- finally {
82
- try {
83
- if (!_d && !_a && (_b = _e.return)) yield tslib_1.__await(_b.call(_e));
84
- }
85
- finally { if (e_1) throw e_1.error; }
86
- }
87
- });
68
+ async *listByServerPagingAll(resourceGroupName, serverName, options) {
69
+ for await (const page of this.listByServerPagingPage(resourceGroupName, serverName, options)) {
70
+ yield* page;
71
+ }
88
72
  }
89
73
  /**
90
74
  * Gets a private endpoint connection.
@@ -1 +1 @@
1
- {"version":3,"file":"privateEndpointConnections.js","sourceRoot":"","sources":["../../../src/operations/privateEndpointConnections.ts"],"names":[],"mappings":";AAAA;;;;;;GAMG;;;;AAGH,wDAA0D;AAE1D,uEAAiD;AACjD,sEAAgD;AAChD,4EAAsD;AAYtD,4CAA4C;AAC5C,8DAA8D;AAC9D,MAAa,8BAA8B;IAGzC;;;OAGG;IACH,YAAY,MAAgD;QAC1D,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC;IACvB,CAAC;IAED;;;;;OAKG;IACI,YAAY,CACjB,iBAAyB,EACzB,UAAkB,EAClB,OAA8D;QAE9D,MAAM,IAAI,GAAG,IAAI,CAAC,qBAAqB,CAAC,iBAAiB,EAAE,UAAU,EAAE,OAAO,CAAC,CAAC;QAChF,OAAO;YACL,IAAI;gBACF,OAAO,IAAI,CAAC,IAAI,EAAE,CAAC;YACrB,CAAC;YACD,CAAC,MAAM,CAAC,aAAa,CAAC;gBACpB,OAAO,IAAI,CAAC;YACd,CAAC;YACD,MAAM,EAAE,CAAC,QAAuB,EAAE,EAAE;gBAClC,IAAI,QA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X,CAAC","sourcesContent":["/*\n * Copyright (c) Microsoft Corporation.\n * Licensed under the MIT License.\n *\n * Code generated by Microsoft (R) AutoRest Code Generator.\n * Changes may cause incorrect behavior and will be lost if the code is regenerated.\n */\n\nimport type { PagedAsyncIterableIterator, PageSettings } from \"@azure/core-paging\";\nimport { setContinuationToken } from \"../pagingHelper.js\";\nimport type { PrivateEndpointConnections } from \"../operationsInterfaces/index.js\";\nimport * as coreClient from \"@azure/core-client\";\nimport * as Mappers from \"../models/mappers.js\";\nimport * as Parameters from \"../models/parameters.js\";\nimport type { PostgreSQLManagementFlexibleServerClient } from \"../postgreSQLManagementFlexibleServerClient.js\";\nimport type {\n PrivateEndpointConnection,\n PrivateEndpointConnectionsListByServerNextOptionalParams,\n PrivateEndpointConnectionsListByServerOptionalParams,\n PrivateEndpointConnectionsListByServerResponse,\n PrivateEndpointConnectionsGetOptionalParams,\n PrivateEndpointConnectionsGetResponse,\n PrivateEndpointConnectionsListByServerNextResponse,\n} from \"../models/index.js\";\n\n/// <reference lib=\"esnext.asynciterable\" />\n/** Class containing PrivateEndpointConnections operations. */\nexport class PrivateEndpointConnectionsImpl implements PrivateEndpointConnections {\n private readonly client: PostgreSQLManagementFlexibleServerClient;\n\n /**\n * Initialize a new instance of the class PrivateEndpointConnections class.\n * @param client Reference to the service client\n */\n constructor(client: PostgreSQLManagementFlexibleServerClient) {\n this.client = client;\n }\n\n /**\n * Gets all private endpoint connections on a server.\n * @param resourceGroupName The name of the resource group. The name is case insensitive.\n * @param serverName The name of the server.\n * @param options The options parameters.\n */\n public listByServer(\n resourceGroupName: string,\n serverName: string,\n options?: PrivateEndpointConnectionsListByServerOptionalParams,\n ): PagedAsyncIterableIterator<PrivateEndpointConnection> {\n const iter = this.listByServerPagingAll(resourceGroupName, serverName, options);\n return {\n next() {\n return iter.next();\n },\n [Symbol.asyncIterator]() {\n return this;\n },\n byPage: (settings?: PageSettings) => {\n if (settings?.maxPageSize) {\n throw new Error(\"maxPageSize is not supported by this operation.\");\n }\n return this.listByServerPagingPage(resourceGroupName, serverName, options, settings);\n },\n };\n }\n\n private async *listByServerPagingPage(\n resourceGroupName: string,\n serverName: string,\n options?: PrivateEndpointConnectionsListByServerOptionalParams,\n settings?: PageSettings,\n ): AsyncIterableIterator<PrivateEndpointConnection[]> {\n let result: PrivateEndpointConnectionsListByServerResponse;\n let continuationToken = settings?.continuationToken;\n if (!continuationToken) {\n result = await this._listByServer(resourceGroupName, serverName, options);\n const page = result.value || [];\n continuationToken = result.nextLink;\n setContinuationToken(page, continuationToken);\n yield page;\n }\n while (continuationToken) {\n result = await this._listByServerNext(\n resourceGroupName,\n serverName,\n continuationToken,\n options,\n );\n continuationToken = result.nextLink;\n const page = result.value || [];\n setContinuationToken(page, continuationToken);\n yield page;\n }\n }\n\n private async *listByServerPagingAll(\n resourceGroupName: string,\n serverName: string,\n options?: PrivateEndpointConnectionsListByServerOptionalParams,\n ): AsyncIterableIterator<PrivateEndpointConnection> {\n for await (const page of this.listByServerPagingPage(resourceGroupName, serverName, options)) {\n yield* page;\n }\n }\n\n /**\n * Gets a private endpoint connection.\n * @param resourceGroupName The name of the resource group. The name is case insensitive.\n * @param serverName The name of the server.\n * @param privateEndpointConnectionName The name of the private endpoint connection.\n * @param options The options parameters.\n */\n get(\n resourceGroupName: string,\n serverName: string,\n privateEndpointConnectionName: string,\n options?: PrivateEndpointConnectionsGetOptionalParams,\n ): Promise<PrivateEndpointConnectionsGetResponse> {\n return this.client.sendOperationRequest(\n { resourceGroupName, serverName, privateEndpointConnectionName, options },\n getOperationSpec,\n );\n }\n\n /**\n * Gets all private endpoint connections on a server.\n * @param resourceGroupName The name of the resource group. The name is case insensitive.\n * @param serverName The name of the server.\n * @param options The options parameters.\n */\n private _listByServer(\n resourceGroupName: string,\n serverName: string,\n options?: PrivateEndpointConnectionsListByServerOptionalParams,\n ): Promise<PrivateEndpointConnectionsListByServerResponse> {\n return this.client.sendOperationRequest(\n { resourceGroupName, serverName, options },\n listByServerOperationSpec,\n );\n }\n\n /**\n * ListByServerNext\n * @param resourceGroupName The name of the resource group. The name is case insensitive.\n * @param serverName The name of the server.\n * @param nextLink The nextLink from the previous successful call to the ListByServer method.\n * @param options The options parameters.\n */\n private _listByServerNext(\n resourceGroupName: string,\n serverName: string,\n nextLink: string,\n options?: PrivateEndpointConnectionsListByServerNextOptionalParams,\n ): Promise<PrivateEndpointConnectionsListByServerNextResponse> {\n return this.client.sendOperationRequest(\n { resourceGroupName, serverName, nextLink, options },\n listByServerNextOperationSpec,\n );\n }\n}\n// Operation Specifications\nconst serializer = coreClient.createSerializer(Mappers, /* isXml */ false);\n\nconst getOperationSpec: coreClient.OperationSpec = {\n path: \"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL/flexibleServers/{serverName}/privateEndpointConnections/{privateEndpointConnectionName}\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.PrivateEndpointConnection,\n },\n default: {\n bodyMapper: Mappers.ErrorResponse,\n },\n },\n queryParameters: [Parameters.apiVersion],\n urlParameters: [\n Parameters.$host,\n Parameters.subscriptionId,\n Parameters.resourceGroupName,\n Parameters.serverName,\n Parameters.privateEndpointConnectionName,\n ],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst listByServerOperationSpec: coreClient.OperationSpec = {\n path: \"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL/flexibleServers/{serverName}/privateEndpointConnections\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.PrivateEndpointConnectionListResult,\n },\n default: {\n bodyMapper: Mappers.ErrorResponse,\n },\n },\n queryParameters: [Parameters.apiVersion],\n urlParameters: [\n Parameters.$host,\n Parameters.subscriptionId,\n Parameters.resourceGroupName,\n Parameters.serverName,\n ],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst listByServerNextOperationSpec: coreClient.OperationSpec = {\n path: \"{nextLink}\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.PrivateEndpointConnectionListResult,\n },\n default: {\n bodyMapper: Mappers.ErrorResponse,\n },\n },\n urlParameters: [\n Parameters.$host,\n Parameters.subscriptionId,\n Parameters.resourceGroupName,\n Parameters.serverName,\n Parameters.nextLink,\n ],\n headerParameters: [Parameters.accept],\n serializer,\n};\n"]}
1
+ {"version":3,"file":"privateEndpointConnections.js","sourceRoot":"","sources":["../../../src/operations/privateEndpointConnections.ts"],"names":[],"mappings":";AAAA;;;;;;GAMG;;;;AAGH,wDAA0D;AAE1D,uEAAiD;AACjD,sEAAgD;AAChD,4EAAsD;AAYtD,4CAA4C;AAC5C,8DAA8D;AAC9D,MAAa,8BAA8B;IACxB,MAAM,CAA2C;IAElE;;;OAGG;IACH,YAAY,MAAgD;QAC1D,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC;IACvB,CAAC;IAED;;;;;OAKG;IACI,YAAY,CACjB,iBAAyB,EACzB,UAAkB,EAClB,OAA8D;QAE9D,MAAM,IAAI,GAAG,IAAI,CAAC,qBAAqB,CAAC,iBAAiB,EAAE,UAAU,EAAE,OAAO,CAAC,CAAC;QAChF,OAAO;YACL,IAAI;gBACF,OAAO,IAAI,CAAC,IAAI,EAAE,CAAC;YACrB,CAAC;YACD,CAAC,MAAM,CAAC,aAAa,CAAC;gBACpB,OAAO,IAAI,CAAC;YACd,CAAC;YACD,MAAM,EAAE,CAAC,QAAuB,EAAE,EAAE;gBAClC,IAAI,QAAQ,EAAE,WAAW,EAAE,CAAC;oBAC1B,MAAM,IAAI,KAAK,CAAC,iDAAiD,CAAC,CAAC;gBACrE,CAAC;gBACD,OAAO,IAAI,CAAC,sBAAsB,CAAC,iBAAiB,EAAE,UAAU,EAAE,OAAO,EAAE,QAAQ,CAAC,CAAC;YACvF,CAAC;SACF,CAAC;IACJ,CAAC;IAEO,KAAK,CAAC,CAAC,sBAAsB,CACnC,iBAAyB,EACzB,UAAkB,EAClB,OAA8D,EAC9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QACD,OAAO,EAAE;YACP,UAAU,EAAE,OAAO,CAAC,aAAa;SAClC;KACF;IACD,eAAe,EAAE,CAAC,UAAU,CAAC,UAAU,CAAC;IACxC,aAAa,EAAE;QACb,UAAU,CAAC,KAAK;QAChB,UAAU,CAAC,cAAc;QACzB,UAAU,CAAC,iBAAiB;QAC5B,UAAU,CAAC,UAAU;KACtB;IACD,gBAAgB,EAAE,CAAC,UAAU,CAAC,MAAM,CAAC;IACrC,UAAU;CACX,CAAC;AACF,MAAM,6BAA6B,GAA6B;IAC9D,IAAI,EAAE,YAAY;IAClB,UAAU,EAAE,KAAK;IACjB,SAAS,EAAE;QACT,GAAG,EAAE;YACH,UAAU,EAAE,OAAO,CAAC,mCAAmC;SACxD;QACD,OAAO,EAAE;YACP,UAAU,EAAE,OAAO,CAAC,aAAa;SAClC;KACF;IACD,aAAa,EAAE;QACb,UAAU,CAAC,KAAK;QAChB,UAAU,CAAC,cAAc;QACzB,UAAU,CAAC,iBAAiB;QAC5B,UAAU,CAAC,UAAU;QACrB,UAAU,CAAC,QAAQ;KACpB;IACD,gBAAgB,EAAE,CAAC,UAAU,CAAC,MAAM,CAAC;IACrC,UAAU;CACX,CAAC","sourcesContent":["/*\n * Copyright (c) Microsoft Corporation.\n * Licensed under the MIT License.\n *\n * Code generated by Microsoft (R) AutoRest Code Generator.\n * Changes may cause incorrect behavior and will be lost if the code is regenerated.\n */\n\nimport type { PagedAsyncIterableIterator, PageSettings } from \"@azure/core-paging\";\nimport { setContinuationToken } from \"../pagingHelper.js\";\nimport type { PrivateEndpointConnections } from \"../operationsInterfaces/index.js\";\nimport * as coreClient from \"@azure/core-client\";\nimport * as Mappers from \"../models/mappers.js\";\nimport * as Parameters from \"../models/parameters.js\";\nimport type { PostgreSQLManagementFlexibleServerClient } from \"../postgreSQLManagementFlexibleServerClient.js\";\nimport type {\n PrivateEndpointConnection,\n PrivateEndpointConnectionsListByServerNextOptionalParams,\n PrivateEndpointConnectionsListByServerOptionalParams,\n PrivateEndpointConnectionsListByServerResponse,\n PrivateEndpointConnectionsGetOptionalParams,\n PrivateEndpointConnectionsGetResponse,\n PrivateEndpointConnectionsListByServerNextResponse,\n} from \"../models/index.js\";\n\n/// <reference lib=\"esnext.asynciterable\" />\n/** Class containing PrivateEndpointConnections operations. */\nexport class PrivateEndpointConnectionsImpl implements PrivateEndpointConnections {\n private readonly client: PostgreSQLManagementFlexibleServerClient;\n\n /**\n * Initialize a new instance of the class PrivateEndpointConnections class.\n * @param client Reference to the service client\n */\n constructor(client: PostgreSQLManagementFlexibleServerClient) {\n this.client = client;\n }\n\n /**\n * Gets all private endpoint connections on a server.\n * @param resourceGroupName The name of the resource group. The name is case insensitive.\n * @param serverName The name of the server.\n * @param options The options parameters.\n */\n public listByServer(\n resourceGroupName: string,\n serverName: string,\n options?: PrivateEndpointConnectionsListByServerOptionalParams,\n ): PagedAsyncIterableIterator<PrivateEndpointConnection> {\n const iter = this.listByServerPagingAll(resourceGroupName, serverName, options);\n return {\n next() {\n return iter.next();\n },\n [Symbol.asyncIterator]() {\n return this;\n },\n byPage: (settings?: PageSettings) => {\n if (settings?.maxPageSize) {\n throw new Error(\"maxPageSize is not supported by this operation.\");\n }\n return this.listByServerPagingPage(resourceGroupName, serverName, options, settings);\n },\n };\n }\n\n private async *listByServerPagingPage(\n resourceGroupName: string,\n serverName: string,\n options?: PrivateEndpointConnectionsListByServerOptionalParams,\n settings?: PageSettings,\n ): AsyncIterableIterator<PrivateEndpointConnection[]> {\n let result: PrivateEndpointConnectionsListByServerResponse;\n let continuationToken = settings?.continuationToken;\n if (!continuationToken) {\n result = await this._listByServer(resourceGroupName, serverName, options);\n const page = result.value || [];\n continuationToken = result.nextLink;\n setContinuationToken(page, continuationToken);\n yield page;\n }\n while (continuationToken) {\n result = await this._listByServerNext(\n resourceGroupName,\n serverName,\n continuationToken,\n options,\n );\n continuationToken = result.nextLink;\n const page = result.value || [];\n setContinuationToken(page, continuationToken);\n yield page;\n }\n }\n\n private async *listByServerPagingAll(\n resourceGroupName: string,\n serverName: string,\n options?: PrivateEndpointConnectionsListByServerOptionalParams,\n ): AsyncIterableIterator<PrivateEndpointConnection> {\n for await (const page of this.listByServerPagingPage(resourceGroupName, serverName, options)) {\n yield* page;\n }\n }\n\n /**\n * Gets a private endpoint connection.\n * @param resourceGroupName The name of the resource group. The name is case insensitive.\n * @param serverName The name of the server.\n * @param privateEndpointConnectionName The name of the private endpoint connection.\n * @param options The options parameters.\n */\n get(\n resourceGroupName: string,\n serverName: string,\n privateEndpointConnectionName: string,\n options?: PrivateEndpointConnectionsGetOptionalParams,\n ): Promise<PrivateEndpointConnectionsGetResponse> {\n return this.client.sendOperationRequest(\n { resourceGroupName, serverName, privateEndpointConnectionName, options },\n getOperationSpec,\n );\n }\n\n /**\n * Gets all private endpoint connections on a server.\n * @param resourceGroupName The name of the resource group. The name is case insensitive.\n * @param serverName The name of the server.\n * @param options The options parameters.\n */\n private _listByServer(\n resourceGroupName: string,\n serverName: string,\n options?: PrivateEndpointConnectionsListByServerOptionalParams,\n ): Promise<PrivateEndpointConnectionsListByServerResponse> {\n return this.client.sendOperationRequest(\n { resourceGroupName, serverName, options },\n listByServerOperationSpec,\n );\n }\n\n /**\n * ListByServerNext\n * @param resourceGroupName The name of the resource group. The name is case insensitive.\n * @param serverName The name of the server.\n * @param nextLink The nextLink from the previous successful call to the ListByServer method.\n * @param options The options parameters.\n */\n private _listByServerNext(\n resourceGroupName: string,\n serverName: string,\n nextLink: string,\n options?: PrivateEndpointConnectionsListByServerNextOptionalParams,\n ): Promise<PrivateEndpointConnectionsListByServerNextResponse> {\n return this.client.sendOperationRequest(\n { resourceGroupName, serverName, nextLink, options },\n listByServerNextOperationSpec,\n );\n }\n}\n// Operation Specifications\nconst serializer = coreClient.createSerializer(Mappers, /* isXml */ false);\n\nconst getOperationSpec: coreClient.OperationSpec = {\n path: \"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL/flexibleServers/{serverName}/privateEndpointConnections/{privateEndpointConnectionName}\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.PrivateEndpointConnection,\n },\n default: {\n bodyMapper: Mappers.ErrorResponse,\n },\n },\n queryParameters: [Parameters.apiVersion],\n urlParameters: [\n Parameters.$host,\n Parameters.subscriptionId,\n Parameters.resourceGroupName,\n Parameters.serverName,\n Parameters.privateEndpointConnectionName,\n ],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst listByServerOperationSpec: coreClient.OperationSpec = {\n path: \"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL/flexibleServers/{serverName}/privateEndpointConnections\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.PrivateEndpointConnectionListResult,\n },\n default: {\n bodyMapper: Mappers.ErrorResponse,\n },\n },\n queryParameters: [Parameters.apiVersion],\n urlParameters: [\n Parameters.$host,\n Parameters.subscriptionId,\n Parameters.resourceGroupName,\n Parameters.serverName,\n ],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst listByServerNextOperationSpec: coreClient.OperationSpec = {\n path: \"{nextLink}\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.PrivateEndpointConnectionListResult,\n },\n default: {\n bodyMapper: Mappers.ErrorResponse,\n },\n },\n urlParameters: [\n Parameters.$host,\n Parameters.subscriptionId,\n Parameters.resourceGroupName,\n Parameters.serverName,\n Parameters.nextLink,\n ],\n headerParameters: [Parameters.accept],\n serializer,\n};\n"]}
@@ -16,6 +16,7 @@ const Parameters = tslib_1.__importStar(require("../models/parameters.js"));
16
16
  /// <reference lib="esnext.asynciterable" />
17
17
  /** Class containing PrivateLinkResources operations. */
18
18
  class PrivateLinkResourcesImpl {
19
+ client;
19
20
  /**
20
21
  * Initialize a new instance of the class PrivateLinkResources class.
21
22
  * @param client Reference to the service client
@@ -39,52 +40,35 @@ class PrivateLinkResourcesImpl {
39
40
  return this;
40
41
  },
41
42
  byPage: (settings) => {
42
- if (settings === null || settings === void 0 ? void 0 : settings.maxPageSize) {
43
+ if (settings?.maxPageSize) {
43
44
  throw new Error("maxPageSize is not supported by this operation.");
44
45
  }
45
46
  return this.listByServerPagingPage(resourceGroupName, serverName, options, settings);
46
47
  },
47
48
  };
48
49
  }
49
- listByServerPagingPage(resourceGroupName, serverName, options, settings) {
50
- return tslib_1.__asyncGenerator(this, arguments, function* listByServerPagingPage_1() {
51
- let result;
52
- let continuationToken = settings === null || settings === void 0 ? void 0 : settings.continuationToken;
53
- if (!continuationToken) {
54
- result = yield tslib_1.__await(this._listByServer(resourceGroupName, serverName, options));
55
- const page = result.value || [];
56
- continuationToken = result.nextLink;
57
- (0, pagingHelper_js_1.setContinuationToken)(page, continuationToken);
58
- yield yield tslib_1.__await(page);
59
- }
60
- while (continuationToken) {
61
- result = yield tslib_1.__await(this._listByServerNext(resourceGroupName, serverName, continuationToken, options));
62
- continuationToken = result.nextLink;
63
- const page = result.value || [];
64
- (0, pagingHelper_js_1.setContinuationToken)(page, continuationToken);
65
- yield yield tslib_1.__await(page);
66
- }
67
- });
50
+ async *listByServerPagingPage(resourceGroupName, serverName, options, settings) {
51
+ let result;
52
+ let continuationToken = settings?.continuationToken;
53
+ if (!continuationToken) {
54
+ result = await this._listByServer(resourceGroupName, serverName, options);
55
+ const page = result.value || [];
56
+ continuationToken = result.nextLink;
57
+ (0, pagingHelper_js_1.setContinuationToken)(page, continuationToken);
58
+ yield page;
59
+ }
60
+ while (continuationToken) {
61
+ result = await this._listByServerNext(resourceGroupName, serverName, continuationToken, options);
62
+ continuationToken = result.nextLink;
63
+ const page = result.value || [];
64
+ (0, pagingHelper_js_1.setContinuationToken)(page, continuationToken);
65
+ yield page;
66
+ }
68
67
  }
69
- listByServerPagingAll(resourceGroupName, serverName, options) {
70
- return tslib_1.__asyncGenerator(this, arguments, function* listByServerPagingAll_1() {
71
- var _a, e_1, _b, _c;
72
- try {
73
- for (var _d = true, _e = tslib_1.__asyncValues(this.listByServerPagingPage(resourceGroupName, serverName, options)), _f; _f = yield tslib_1.__await(_e.next()), _a = _f.done, !_a; _d = true) {
74
- _c = _f.value;
75
- _d = false;
76
- const page = _c;
77
- yield tslib_1.__await(yield* tslib_1.__asyncDelegator(tslib_1.__asyncValues(page)));
78
- }
79
- }
80
- catch (e_1_1) { e_1 = { error: e_1_1 }; }
81
- finally {
82
- try {
83
- if (!_d && !_a && (_b = _e.return)) yield tslib_1.__await(_b.call(_e));
84
- }
85
- finally { if (e_1) throw e_1.error; }
86
- }
87
- });
68
+ async *listByServerPagingAll(resourceGroupName, serverName, options) {
69
+ for await (const page of this.listByServerPagingPage(resourceGroupName, serverName, options)) {
70
+ yield* page;
71
+ }
88
72
  }
89
73
  /**
90
74
  * Gets the private link resources for PostgreSQL server.
@@ -1 +1 @@
1
- {"version":3,"file":"privateLinkResources.js","sourceRoot":"","sources":["../../../src/operations/privateLinkResources.ts"],"names":[],"mappings":";AAAA;;;;;;GAMG;;;;AAGH,wDAA0D;AAE1D,uEAAiD;AACjD,sEAAgD;AAChD,4EAAsD;AAYtD,4CAA4C;AAC5C,wDAAwD;AACxD,MAAa,wBAAwB;IAGnC;;;OAGG;IACH,YAAY,MAAgD;QAC1D,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC;IACvB,CAAC;IAED;;;;;OAKG;IACI,YAAY,CACjB,iBAAyB,EACzB,UAAkB,EAClB,OAAwD;QAExD,MAAM,IAAI,GAAG,IAAI,CAAC,qBAAqB,CAAC,iBAAiB,EAAE,UAAU,EAAE,OAAO,CAAC,CAAC;QAChF,OAAO;YACL,IAAI;gBACF,OAAO,IAAI,CAAC,IAAI,EAAE,CAAC;YACrB,CAAC;YACD,CAAC,MAAM,CAAC,aAAa,CAAC;gBACpB,OAAO,IAAI,CAAC;YACd,CAAC;YACD,MAAM,EAAE,CAAC,QAAuB,EAAE,EAAE;gBAClC,IAAI,QAAQ,aAAR,QAAQ,uBAAR,QAAQ,CAAE,WAA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ensed under the MIT License.\n *\n * Code generated by Microsoft (R) AutoRest Code Generator.\n * Changes may cause incorrect behavior and will be lost if the code is regenerated.\n */\n\nimport type { PagedAsyncIterableIterator, PageSettings } from \"@azure/core-paging\";\nimport { setContinuationToken } from \"../pagingHelper.js\";\nimport type { PrivateLinkResources } from \"../operationsInterfaces/index.js\";\nimport * as coreClient from \"@azure/core-client\";\nimport * as Mappers from \"../models/mappers.js\";\nimport * as Parameters from \"../models/parameters.js\";\nimport type { PostgreSQLManagementFlexibleServerClient } from \"../postgreSQLManagementFlexibleServerClient.js\";\nimport type {\n PrivateLinkResource,\n PrivateLinkResourcesListByServerNextOptionalParams,\n PrivateLinkResourcesListByServerOptionalParams,\n PrivateLinkResourcesListByServerResponse,\n PrivateLinkResourcesGetOptionalParams,\n PrivateLinkResourcesGetResponse,\n PrivateLinkResourcesListByServerNextResponse,\n} from \"../models/index.js\";\n\n/// <reference lib=\"esnext.asynciterable\" />\n/** Class containing PrivateLinkResources operations. */\nexport class PrivateLinkResourcesImpl implements PrivateLinkResources {\n private readonly client: PostgreSQLManagementFlexibleServerClient;\n\n /**\n * Initialize a new instance of the class PrivateLinkResources class.\n * @param client Reference to the service client\n */\n constructor(client: PostgreSQLManagementFlexibleServerClient) {\n this.client = client;\n }\n\n /**\n * Gets the private link resources for PostgreSQL server.\n * @param resourceGroupName The name of the resource group. The name is case insensitive.\n * @param serverName The name of the server.\n * @param options The options parameters.\n */\n public listByServer(\n resourceGroupName: string,\n serverName: string,\n options?: PrivateLinkResourcesListByServerOptionalParams,\n ): PagedAsyncIterableIterator<PrivateLinkResource> {\n const iter = this.listByServerPagingAll(resourceGroupName, serverName, options);\n return {\n next() {\n return iter.next();\n },\n [Symbol.asyncIterator]() {\n return this;\n },\n byPage: (settings?: PageSettings) => {\n if (settings?.maxPageSize) {\n throw new Error(\"maxPageSize is not supported by this operation.\");\n }\n return this.listByServerPagingPage(resourceGroupName, serverName, options, settings);\n },\n };\n }\n\n private async *listByServerPagingPage(\n resourceGroupName: string,\n serverName: string,\n options?: PrivateLinkResourcesListByServerOptionalParams,\n settings?: PageSettings,\n ): AsyncIterableIterator<PrivateLinkResource[]> {\n let result: PrivateLinkResourcesListByServerResponse;\n let continuationToken = settings?.continuationToken;\n if (!continuationToken) {\n result = await this._listByServer(resourceGroupName, serverName, options);\n const page = result.value || [];\n continuationToken = result.nextLink;\n setContinuationToken(page, continuationToken);\n yield page;\n }\n while (continuationToken) {\n result = await this._listByServerNext(\n resourceGroupName,\n serverName,\n continuationToken,\n options,\n );\n continuationToken = result.nextLink;\n const page = result.value || [];\n setContinuationToken(page, continuationToken);\n yield page;\n }\n }\n\n private async *listByServerPagingAll(\n resourceGroupName: string,\n serverName: string,\n options?: PrivateLinkResourcesListByServerOptionalParams,\n ): AsyncIterableIterator<PrivateLinkResource> {\n for await (const page of this.listByServerPagingPage(resourceGroupName, serverName, options)) {\n yield* page;\n }\n }\n\n /**\n * Gets the private link resources for PostgreSQL server.\n * @param resourceGroupName The name of the resource group. The name is case insensitive.\n * @param serverName The name of the server.\n * @param options The options parameters.\n */\n private _listByServer(\n resourceGroupName: string,\n serverName: string,\n options?: PrivateLinkResourcesListByServerOptionalParams,\n ): Promise<PrivateLinkResourcesListByServerResponse> {\n return this.client.sendOperationRequest(\n { resourceGroupName, serverName, options },\n listByServerOperationSpec,\n );\n }\n\n /**\n * Gets a private link resource for PostgreSQL server.\n * @param resourceGroupName The name of the resource group. The name is case insensitive.\n * @param serverName The name of the server.\n * @param groupName The name of the private link resource.\n * @param options The options parameters.\n */\n get(\n resourceGroupName: string,\n serverName: string,\n groupName: string,\n options?: PrivateLinkResourcesGetOptionalParams,\n ): Promise<PrivateLinkResourcesGetResponse> {\n return this.client.sendOperationRequest(\n { resourceGroupName, serverName, groupName, options },\n getOperationSpec,\n );\n }\n\n /**\n * ListByServerNext\n * @param resourceGroupName The name of the resource group. The name is case insensitive.\n * @param serverName The name of the server.\n * @param nextLink The nextLink from the previous successful call to the ListByServer method.\n * @param options The options parameters.\n */\n private _listByServerNext(\n resourceGroupName: string,\n serverName: string,\n nextLink: string,\n options?: PrivateLinkResourcesListByServerNextOptionalParams,\n ): Promise<PrivateLinkResourcesListByServerNextResponse> {\n return this.client.sendOperationRequest(\n { resourceGroupName, serverName, nextLink, options },\n listByServerNextOperationSpec,\n );\n }\n}\n// Operation Specifications\nconst serializer = coreClient.createSerializer(Mappers, /* isXml */ false);\n\nconst listByServerOperationSpec: coreClient.OperationSpec = {\n path: \"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL/flexibleServers/{serverName}/privateLinkResources\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.PrivateLinkResourceListResult,\n },\n default: {\n bodyMapper: Mappers.ErrorResponse,\n },\n },\n queryParameters: [Parameters.apiVersion],\n urlParameters: [\n Parameters.$host,\n Parameters.subscriptionId,\n Parameters.resourceGroupName,\n Parameters.serverName,\n ],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getOperationSpec: coreClient.OperationSpec = {\n path: \"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL/flexibleServers/{serverName}/privateLinkResources/{groupName}\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.PrivateLinkResource,\n },\n default: {\n bodyMapper: Mappers.ErrorResponse,\n },\n },\n queryParameters: [Parameters.apiVersion],\n urlParameters: [\n Parameters.$host,\n Parameters.subscriptionId,\n Parameters.resourceGroupName,\n Parameters.serverName,\n Parameters.groupName,\n ],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst listByServerNextOperationSpec: coreClient.OperationSpec = {\n path: \"{nextLink}\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.PrivateLinkResourceListResult,\n },\n default: {\n bodyMapper: Mappers.ErrorResponse,\n },\n },\n urlParameters: [\n Parameters.$host,\n Parameters.subscriptionId,\n Parameters.resourceGroupName,\n Parameters.serverName,\n Parameters.nextLink,\n ],\n headerParameters: [Parameters.accept],\n serializer,\n};\n"]}
1
+ {"version":3,"file":"privateLinkResources.js","sourceRoot":"","sources":["../../../src/operations/privateLinkResources.ts"],"names":[],"mappings":";AAAA;;;;;;GAMG;;;;AAGH,wDAA0D;AAE1D,uEAAiD;AACjD,sEAAgD;AAChD,4EAAsD;AAYtD,4CAA4C;AAC5C,wDAAwD;AACxD,MAAa,wBAAwB;IAClB,MAAM,CAA2C;IAElE;;;OAGG;IACH,YAAY,MAAgD;QAC1D,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC;IACvB,CAAC;IAED;;;;;OAKG;IACI,YAAY,CACjB,iBAAyB,EACzB,UAAkB,EAClB,OAAwD;QAExD,MAAM,IAAI,GAAG,IAAI,CAAC,qBAAqB,CAAC,iBAAiB,EAAE,UAAU,EAAE,OAAO,CAAC,CAAC;QAChF,OAAO;YACL,IAAI;gBACF,OAAO,IAAI,CAAC,IAAI,EAAE,CAAC;YACrB,CAAC;YACD,CAAC,MAAM,CAAC,aAAa,CAAC;gBACpB,OAAO,IAAI,CAAC;YACd,CAAC;YACD,MAAM,EAAE,CAAC,QAAuB,EAAE,EAAE;gBAClC,IAAI,QAAQ,EAAE,WAAW,EAAE,CAAC;oBAC1B,MAAM,IAAI,KAAK,CAAC,iDAAiD,CAAC,CAAC;gBACrE,CAAC;gBACD,OAAO,IAAI,CAAC,sBAAsB,CAAC,iBAAiB,EAAE,UAAU,EAAE,OAAO,EAAE,QAAQ,CAAC,CAAC;YACvF,CAAC;SACF,CAAC;IACJ,CAAC;IAEO,KAAK,CAAC,CAAC,sBAAsB,CACnC,iBAAyB,EACzB,UAAkB,EAClB,OAAwD,EACxD,QAAuB;QAEvB,IAAI,MAAgD,CAAC;QACrD,IAAI,iBAAiB,GAAG,QAAQ,EAAE,iBAAiB,CAAC;QACpD,IAAI,CAAC,iBAAiB,EAAE,CAAC;YACvB,MAAM,GAAG,MAAM,IAAI,CAAC,aAA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;QAC5B,UAAU,CAAC,UAAU;QACrB,UAAU,CAAC,SAAS;KACrB;IACD,gBAAgB,EAAE,CAAC,UAAU,CAAC,MAAM,CAAC;IACrC,UAAU;CACX,CAAC;AACF,MAAM,6BAA6B,GAA6B;IAC9D,IAAI,EAAE,YAAY;IAClB,UAAU,EAAE,KAAK;IACjB,SAAS,EAAE;QACT,GAAG,EAAE;YACH,UAAU,EAAE,OAAO,CAAC,6BAA6B;SAClD;QACD,OAAO,EAAE;YACP,UAAU,EAAE,OAAO,CAAC,aAAa;SAClC;KACF;IACD,aAAa,EAAE;QACb,UAAU,CAAC,KAAK;QAChB,UAAU,CAAC,cAAc;QACzB,UAAU,CAAC,iBAAiB;QAC5B,UAAU,CAAC,UAAU;QACrB,UAAU,CAAC,QAAQ;KACpB;IACD,gBAAgB,EAAE,CAAC,UAAU,CAAC,MAAM,CAAC;IACrC,UAAU;CACX,CAAC","sourcesContent":["/*\n * Copyright (c) Microsoft Corporation.\n * Licensed under the MIT License.\n *\n * Code generated by Microsoft (R) AutoRest Code Generator.\n * Changes may cause incorrect behavior and will be lost if the code is regenerated.\n */\n\nimport type { PagedAsyncIterableIterator, PageSettings } from \"@azure/core-paging\";\nimport { setContinuationToken } from \"../pagingHelper.js\";\nimport type { PrivateLinkResources } from \"../operationsInterfaces/index.js\";\nimport * as coreClient from \"@azure/core-client\";\nimport * as Mappers from \"../models/mappers.js\";\nimport * as Parameters from \"../models/parameters.js\";\nimport type { PostgreSQLManagementFlexibleServerClient } from \"../postgreSQLManagementFlexibleServerClient.js\";\nimport type {\n PrivateLinkResource,\n PrivateLinkResourcesListByServerNextOptionalParams,\n PrivateLinkResourcesListByServerOptionalParams,\n PrivateLinkResourcesListByServerResponse,\n PrivateLinkResourcesGetOptionalParams,\n PrivateLinkResourcesGetResponse,\n PrivateLinkResourcesListByServerNextResponse,\n} from \"../models/index.js\";\n\n/// <reference lib=\"esnext.asynciterable\" />\n/** Class containing PrivateLinkResources operations. */\nexport class PrivateLinkResourcesImpl implements PrivateLinkResources {\n private readonly client: PostgreSQLManagementFlexibleServerClient;\n\n /**\n * Initialize a new instance of the class PrivateLinkResources class.\n * @param client Reference to the service client\n */\n constructor(client: PostgreSQLManagementFlexibleServerClient) {\n this.client = client;\n }\n\n /**\n * Gets the private link resources for PostgreSQL server.\n * @param resourceGroupName The name of the resource group. The name is case insensitive.\n * @param serverName The name of the server.\n * @param options The options parameters.\n */\n public listByServer(\n resourceGroupName: string,\n serverName: string,\n options?: PrivateLinkResourcesListByServerOptionalParams,\n ): PagedAsyncIterableIterator<PrivateLinkResource> {\n const iter = this.listByServerPagingAll(resourceGroupName, serverName, options);\n return {\n next() {\n return iter.next();\n },\n [Symbol.asyncIterator]() {\n return this;\n },\n byPage: (settings?: PageSettings) => {\n if (settings?.maxPageSize) {\n throw new Error(\"maxPageSize is not supported by this operation.\");\n }\n return this.listByServerPagingPage(resourceGroupName, serverName, options, settings);\n },\n };\n }\n\n private async *listByServerPagingPage(\n resourceGroupName: string,\n serverName: string,\n options?: PrivateLinkResourcesListByServerOptionalParams,\n settings?: PageSettings,\n ): AsyncIterableIterator<PrivateLinkResource[]> {\n let result: PrivateLinkResourcesListByServerResponse;\n let continuationToken = settings?.continuationToken;\n if (!continuationToken) {\n result = await this._listByServer(resourceGroupName, serverName, options);\n const page = result.value || [];\n continuationToken = result.nextLink;\n setContinuationToken(page, continuationToken);\n yield page;\n }\n while (continuationToken) {\n result = await this._listByServerNext(\n resourceGroupName,\n serverName,\n continuationToken,\n options,\n );\n continuationToken = result.nextLink;\n const page = result.value || [];\n setContinuationToken(page, continuationToken);\n yield page;\n }\n }\n\n private async *listByServerPagingAll(\n resourceGroupName: string,\n serverName: string,\n options?: PrivateLinkResourcesListByServerOptionalParams,\n ): AsyncIterableIterator<PrivateLinkResource> {\n for await (const page of this.listByServerPagingPage(resourceGroupName, serverName, options)) {\n yield* page;\n }\n }\n\n /**\n * Gets the private link resources for PostgreSQL server.\n * @param resourceGroupName The name of the resource group. The name is case insensitive.\n * @param serverName The name of the server.\n * @param options The options parameters.\n */\n private _listByServer(\n resourceGroupName: string,\n serverName: string,\n options?: PrivateLinkResourcesListByServerOptionalParams,\n ): Promise<PrivateLinkResourcesListByServerResponse> {\n return this.client.sendOperationRequest(\n { resourceGroupName, serverName, options },\n listByServerOperationSpec,\n );\n }\n\n /**\n * Gets a private link resource for PostgreSQL server.\n * @param resourceGroupName The name of the resource group. The name is case insensitive.\n * @param serverName The name of the server.\n * @param groupName The name of the private link resource.\n * @param options The options parameters.\n */\n get(\n resourceGroupName: string,\n serverName: string,\n groupName: string,\n options?: PrivateLinkResourcesGetOptionalParams,\n ): Promise<PrivateLinkResourcesGetResponse> {\n return this.client.sendOperationRequest(\n { resourceGroupName, serverName, groupName, options },\n getOperationSpec,\n );\n }\n\n /**\n * ListByServerNext\n * @param resourceGroupName The name of the resource group. The name is case insensitive.\n * @param serverName The name of the server.\n * @param nextLink The nextLink from the previous successful call to the ListByServer method.\n * @param options The options parameters.\n */\n private _listByServerNext(\n resourceGroupName: string,\n serverName: string,\n nextLink: string,\n options?: PrivateLinkResourcesListByServerNextOptionalParams,\n ): Promise<PrivateLinkResourcesListByServerNextResponse> {\n return this.client.sendOperationRequest(\n { resourceGroupName, serverName, nextLink, options },\n listByServerNextOperationSpec,\n );\n }\n}\n// Operation Specifications\nconst serializer = coreClient.createSerializer(Mappers, /* isXml */ false);\n\nconst listByServerOperationSpec: coreClient.OperationSpec = {\n path: \"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL/flexibleServers/{serverName}/privateLinkResources\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.PrivateLinkResourceListResult,\n },\n default: {\n bodyMapper: Mappers.ErrorResponse,\n },\n },\n queryParameters: [Parameters.apiVersion],\n urlParameters: [\n Parameters.$host,\n Parameters.subscriptionId,\n Parameters.resourceGroupName,\n Parameters.serverName,\n ],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getOperationSpec: coreClient.OperationSpec = {\n path: \"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL/flexibleServers/{serverName}/privateLinkResources/{groupName}\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.PrivateLinkResource,\n },\n default: {\n bodyMapper: Mappers.ErrorResponse,\n },\n },\n queryParameters: [Parameters.apiVersion],\n urlParameters: [\n Parameters.$host,\n Parameters.subscriptionId,\n Parameters.resourceGroupName,\n Parameters.serverName,\n Parameters.groupName,\n ],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst listByServerNextOperationSpec: coreClient.OperationSpec = {\n path: \"{nextLink}\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.PrivateLinkResourceListResult,\n },\n default: {\n bodyMapper: Mappers.ErrorResponse,\n },\n },\n urlParameters: [\n Parameters.$host,\n Parameters.subscriptionId,\n Parameters.resourceGroupName,\n Parameters.serverName,\n Parameters.nextLink,\n ],\n headerParameters: [Parameters.accept],\n serializer,\n};\n"]}
@@ -16,6 +16,7 @@ const Parameters = tslib_1.__importStar(require("../models/parameters.js"));
16
16
  /// <reference lib="esnext.asynciterable" />
17
17
  /** Class containing QuotaUsages operations. */
18
18
  class QuotaUsagesImpl {
19
+ client;
19
20
  /**
20
21
  * Initialize a new instance of the class QuotaUsages class.
21
22
  * @param client Reference to the service client
@@ -38,52 +39,35 @@ class QuotaUsagesImpl {
38
39
  return this;
39
40
  },
40
41
  byPage: (settings) => {
41
- if (settings === null || settings === void 0 ? void 0 : settings.maxPageSize) {
42
+ if (settings?.maxPageSize) {
42
43
  throw new Error("maxPageSize is not supported by this operation.");
43
44
  }
44
45
  return this.listPagingPage(locationName, options, settings);
45
46
  },
46
47
  };
47
48
  }
48
- listPagingPage(locationName, options, settings) {
49
- return tslib_1.__asyncGenerator(this, arguments, function* listPagingPage_1() {
50
- let result;
51
- let continuationToken = settings === null || settings === void 0 ? void 0 : settings.continuationToken;
52
- if (!continuationToken) {
53
- result = yield tslib_1.__await(this._list(locationName, options));
54
- const page = result.value || [];
55
- continuationToken = result.nextLink;
56
- (0, pagingHelper_js_1.setContinuationToken)(page, continuationToken);
57
- yield yield tslib_1.__await(page);
58
- }
59
- while (continuationToken) {
60
- result = yield tslib_1.__await(this._listNext(locationName, continuationToken, options));
61
- continuationToken = result.nextLink;
62
- const page = result.value || [];
63
- (0, pagingHelper_js_1.setContinuationToken)(page, continuationToken);
64
- yield yield tslib_1.__await(page);
65
- }
66
- });
49
+ async *listPagingPage(locationName, options, settings) {
50
+ let result;
51
+ let continuationToken = settings?.continuationToken;
52
+ if (!continuationToken) {
53
+ result = await this._list(locationName, options);
54
+ const page = result.value || [];
55
+ continuationToken = result.nextLink;
56
+ (0, pagingHelper_js_1.setContinuationToken)(page, continuationToken);
57
+ yield page;
58
+ }
59
+ while (continuationToken) {
60
+ result = await this._listNext(locationName, continuationToken, options);
61
+ continuationToken = result.nextLink;
62
+ const page = result.value || [];
63
+ (0, pagingHelper_js_1.setContinuationToken)(page, continuationToken);
64
+ yield page;
65
+ }
67
66
  }
68
- listPagingAll(locationName, options) {
69
- return tslib_1.__asyncGenerator(this, arguments, function* listPagingAll_1() {
70
- var _a, e_1, _b, _c;
71
- try {
72
- for (var _d = true, _e = tslib_1.__asyncValues(this.listPagingPage(locationName, options)), _f; _f = yield tslib_1.__await(_e.next()), _a = _f.done, !_a; _d = true) {
73
- _c = _f.value;
74
- _d = false;
75
- const page = _c;
76
- yield tslib_1.__await(yield* tslib_1.__asyncDelegator(tslib_1.__asyncValues(page)));
77
- }
78
- }
79
- catch (e_1_1) { e_1 = { error: e_1_1 }; }
80
- finally {
81
- try {
82
- if (!_d && !_a && (_b = _e.return)) yield tslib_1.__await(_b.call(_e));
83
- }
84
- finally { if (e_1) throw e_1.error; }
85
- }
86
- });
67
+ async *listPagingAll(locationName, options) {
68
+ for await (const page of this.listPagingPage(locationName, options)) {
69
+ yield* page;
70
+ }
87
71
  }
88
72
  /**
89
73
  * Get quota usages at specified location in a given subscription.
@@ -1 +1 @@
1
- {"version":3,"file":"quotaUsages.js","sourceRoot":"","sources":["../../../src/operations/quotaUsages.ts"],"names":[],"mappings":";AAAA;;;;;;GAMG;;;;AAGH,wDAA0D;AAE1D,uEAAiD;AACjD,sEAAgD;AAChD,4EAAsD;AAUtD,4CAA4C;AAC5C,+CAA+C;AAC/C,MAAa,eAAe;IAG1B;;;OAGG;IACH,YAAY,MAAgD;QAC1D,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC;IACvB,CAAC;IAED;;;;OAIG;IACI,IAAI,CACT,YAAoB,EACpB,OAAuC;QAEvC,MAAM,IAAI,GAAG,IAAI,CAAC,aAAa,CAAC,YAAY,EAAE,OAAO,CAAC,CAAC;QACvD,OAAO;YACL,IAAI;gBACF,OAAO,IAAI,CAAC,IAAI,EAAE,CAAC;YACrB,CAAC;YACD,CAAC,MAAM,CAAC,aAAa,CAAC;gBACpB,OAAO,IAAI,CAAC;YACd,CAAC;YACD,MAAM,EAAE,CAAC,QAAuB,EAAE,EAAE;gBAClC,IAAI,QAAQ,aAAR,QAAQ,uBAAR,QAAQ,CAAE,WAAW,EAAE,CAAC;oBAC1B,MAAM,IAAI,KAAK,CAAC,iDAAiD,CAAC,CAAC;gBACrE,CAAC;gBACD,OAAO,IAAI,CAAC,cAAc,CAAC,YAAY,EAAE,OAAO,EAAE,QAAQ,CAAC,CAAC;YAC9D,CAAC;SACF,CAAC;IACJ,CAAC;IAEc,cAAc,CAC3B,YAAoB,EACpB,OAAuC,EACvC,QAAuB;;YAEvB,IAAI,MAA+B,CAAC;YACpC,IAAI,iBAAiB,GAAG,QAAQ,aAAR,QAAQ,uBAAR,QAAQ,CAAE,iBAAiB,CAAC;YACpD,IAAI,CAAC,iBAAiB,EAAE,CAAC;gBACvB,MAAM,GAAG,sBAAM,IAAI,CAAC,KAAK,CAAC,YAAY,EAAE,OAAO,CAAC,CAAA,CAAC;gBAC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,EACnC,qBAAqB,CACtB,CAAC;IACJ,CAAC;CACF;AAjGD,0CAiGC;AACD,2BAA2B;AAC3B,MAAM,UAAU,GAAG,UAAU,CAAC,gBAAgB,CAAC,OAAO,EAAE,WAAW,CAAC,KAAK,CAAC,CAAC;AAE3E,MAAM,iBAAiB,GAA6B;IAClD,IAAI,EAAE,kIAAkI;IACxI,UAAU,EAAE,KAAK;IACjB,SAAS,EAAE;QACT,GAAG,EAAE;YACH,UAAU,EAAE,OAAO,CAAC,qBAAqB;SAC1C;QACD,OAAO,EAAE;YACP,UAAU,EAAE,OAAO,CAAC,aAAa;SAClC;KACF;IACD,eAAe,EAAE,CAAC,UAAU,CAAC,UAAU,CAAC;IACxC,aAAa,EAAE,CAAC,UAAU,CAAC,KAAK,EAAE,UAAU,CAAC,cAAc,EAAE,UAAU,CAAC,YAAY,CAAC;IACrF,gBAAgB,EAAE,CAAC,UAAU,CAAC,MAAM,CAAC;IACrC,UAAU;CACX,CAAC;AACF,MAAM,qBAAqB,GAA6B;IACtD,IAAI,EAAE,YAAY;IAClB,UAAU,EAAE,KAAK;IACjB,SAAS,EAAE;QACT,GAAG,EAAE;YACH,UAAU,EAAE,OAAO,CAAC,qBAAqB;SAC1C;QACD,OAAO,EAAE;YACP,UAAU,EAAE,OAAO,CAAC,aAAa;SAClC;KACF;IACD,aAAa,EAAE;QACb,UAAU,CAAC,KAAK;QAChB,UAAU,CAAC,cAAc;QACzB,UAAU,CAAC,QAAQ;QACnB,UAAU,CAAC,YAAY;KACxB;IACD,gBAAgB,EAAE,CAAC,UAAU,CAAC,MAAM,CAAC;IACrC,UAAU;CACX,CAAC","sourcesContent":["/*\n * Copyright (c) Microsoft Corporation.\n * Licensed under the MIT License.\n *\n * Code generated by Microsoft (R) AutoRest Code Generator.\n * Changes may cause incorrect behavior and will be lost if the code is regenerated.\n */\n\nimport type { PagedAsyncIterableIterator, PageSettings } from \"@azure/core-paging\";\nimport { setContinuationToken } from \"../pagingHelper.js\";\nimport type { QuotaUsages } from \"../operationsInterfaces/index.js\";\nimport * as coreClient from \"@azure/core-client\";\nimport * as Mappers from \"../models/mappers.js\";\nimport * as Parameters from \"../models/parameters.js\";\nimport type { PostgreSQLManagementFlexibleServerClient } from \"../postgreSQLManagementFlexibleServerClient.js\";\nimport type {\n QuotaUsage,\n QuotaUsagesListNextOptionalParams,\n QuotaUsagesListOptionalParams,\n QuotaUsagesListResponse,\n QuotaUsagesListNextResponse,\n} from \"../models/index.js\";\n\n/// <reference lib=\"esnext.asynciterable\" />\n/** Class containing QuotaUsages operations. */\nexport class QuotaUsagesImpl implements QuotaUsages {\n private readonly client: PostgreSQLManagementFlexibleServerClient;\n\n /**\n * Initialize a new instance of the class QuotaUsages class.\n * @param client Reference to the service client\n */\n constructor(client: PostgreSQLManagementFlexibleServerClient) {\n this.client = client;\n }\n\n /**\n * Get quota usages at specified location in a given subscription.\n * @param locationName The name of the location.\n * @param options The options parameters.\n */\n public list(\n locationName: string,\n options?: QuotaUsagesListOptionalParams,\n ): PagedAsyncIterableIterator<QuotaUsage> {\n const iter = this.listPagingAll(locationName, options);\n return {\n next() {\n return iter.next();\n },\n [Symbol.asyncIterator]() {\n return this;\n },\n byPage: (settings?: PageSettings) => {\n if (settings?.maxPageSize) {\n throw new Error(\"maxPageSize is not supported by this operation.\");\n }\n return this.listPagingPage(locationName, options, settings);\n },\n };\n }\n\n private async *listPagingPage(\n locationName: string,\n options?: QuotaUsagesListOptionalParams,\n settings?: PageSettings,\n ): AsyncIterableIterator<QuotaUsage[]> {\n let result: QuotaUsagesListResponse;\n let continuationToken = settings?.continuationToken;\n if (!continuationToken) {\n result = await this._list(locationName, options);\n const page = result.value || [];\n continuationToken = result.nextLink;\n setContinuationToken(page, continuationToken);\n yield page;\n }\n while (continuationToken) {\n result = await this._listNext(locationName, continuationToken, options);\n continuationToken = result.nextLink;\n const page = result.value || [];\n setContinuationToken(page, continuationToken);\n yield page;\n }\n }\n\n private async *listPagingAll(\n locationName: string,\n options?: QuotaUsagesListOptionalParams,\n ): AsyncIterableIterator<QuotaUsage> {\n for await (const page of this.listPagingPage(locationName, options)) {\n yield* page;\n }\n }\n\n /**\n * Get quota usages at specified location in a given subscription.\n * @param locationName The name of the location.\n * @param options The options parameters.\n */\n private _list(\n locationName: string,\n options?: QuotaUsagesListOptionalParams,\n ): Promise<QuotaUsagesListResponse> {\n return this.client.sendOperationRequest({ locationName, options }, listOperationSpec);\n }\n\n /**\n * ListNext\n * @param locationName The name of the location.\n * @param nextLink The nextLink from the previous successful call to the List method.\n * @param options The options parameters.\n */\n private _listNext(\n locationName: string,\n nextLink: string,\n options?: QuotaUsagesListNextOptionalParams,\n ): Promise<QuotaUsagesListNextResponse> {\n return this.client.sendOperationRequest(\n { locationName, nextLink, options },\n listNextOperationSpec,\n );\n }\n}\n// Operation Specifications\nconst serializer = coreClient.createSerializer(Mappers, /* isXml */ false);\n\nconst listOperationSpec: coreClient.OperationSpec = {\n path: \"/subscriptions/{subscriptionId}/providers/Microsoft.DBforPostgreSQL/locations/{locationName}/resourceType/flexibleServers/usages\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.QuotaUsagesListResult,\n },\n default: {\n bodyMapper: Mappers.ErrorResponse,\n },\n },\n queryParameters: [Parameters.apiVersion],\n urlParameters: [Parameters.$host, Parameters.subscriptionId, Parameters.locationName],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst listNextOperationSpec: coreClient.OperationSpec = {\n path: \"{nextLink}\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.QuotaUsagesListResult,\n },\n default: {\n bodyMapper: Mappers.ErrorResponse,\n },\n },\n urlParameters: [\n Parameters.$host,\n Parameters.subscriptionId,\n Parameters.nextLink,\n Parameters.locationName,\n ],\n headerParameters: [Parameters.accept],\n serializer,\n};\n"]}
1
+ {"version":3,"file":"quotaUsages.js","sourceRoot":"","sources":["../../../src/operations/quotaUsages.ts"],"names":[],"mappings":";AAAA;;;;;;GAMG;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P,UAAU,EAAE,OAAO,CAAC,aAAa;SAClC;KACF;IACD,eAAe,EAAE,CAAC,UAAU,CAAC,UAAU,CAAC;IACxC,aAAa,EAAE,CAAC,UAAU,CAAC,KAAK,EAAE,UAAU,CAAC,cAAc,EAAE,UAAU,CAAC,YAAY,CAAC;IACrF,gBAAgB,EAAE,CAAC,UAAU,CAAC,MAAM,CAAC;IACrC,UAAU;CACX,CAAC;AACF,MAAM,qBAAqB,GAA6B;IACtD,IAAI,EAAE,YAAY;IAClB,UAAU,EAAE,KAAK;IACjB,SAAS,EAAE;QACT,GAAG,EAAE;YACH,UAAU,EAAE,OAAO,CAAC,qBAAqB;SAC1C;QACD,OAAO,EAAE;YACP,UAAU,EAAE,OAAO,CAAC,aAAa;SAClC;KACF;IACD,aAAa,EAAE;QACb,UAAU,CAAC,KAAK;QAChB,UAAU,CAAC,cAAc;QACzB,UAAU,CAAC,QAAQ;QACnB,UAAU,CAAC,YAAY;KACxB;IACD,gBAAgB,EAAE,CAAC,UAAU,CAAC,MAAM,CAAC;IACrC,UAAU;CACX,CAAC","sourcesContent":["/*\n * Copyright (c) Microsoft Corporation.\n * Licensed under the MIT License.\n *\n * Code generated by Microsoft (R) AutoRest Code Generator.\n * Changes may cause incorrect behavior and will be lost if the code is regenerated.\n */\n\nimport type { PagedAsyncIterableIterator, PageSettings } from \"@azure/core-paging\";\nimport { setContinuationToken } from \"../pagingHelper.js\";\nimport type { QuotaUsages } from \"../operationsInterfaces/index.js\";\nimport * as coreClient from \"@azure/core-client\";\nimport * as Mappers from \"../models/mappers.js\";\nimport * as Parameters from \"../models/parameters.js\";\nimport type { PostgreSQLManagementFlexibleServerClient } from \"../postgreSQLManagementFlexibleServerClient.js\";\nimport type {\n QuotaUsage,\n QuotaUsagesListNextOptionalParams,\n QuotaUsagesListOptionalParams,\n QuotaUsagesListResponse,\n QuotaUsagesListNextResponse,\n} from \"../models/index.js\";\n\n/// <reference lib=\"esnext.asynciterable\" />\n/** Class containing QuotaUsages operations. */\nexport class QuotaUsagesImpl implements QuotaUsages {\n private readonly client: PostgreSQLManagementFlexibleServerClient;\n\n /**\n * Initialize a new instance of the class QuotaUsages class.\n * @param client Reference to the service client\n */\n constructor(client: PostgreSQLManagementFlexibleServerClient) {\n this.client = client;\n }\n\n /**\n * Get quota usages at specified location in a given subscription.\n * @param locationName The name of the location.\n * @param options The options parameters.\n */\n public list(\n locationName: string,\n options?: QuotaUsagesListOptionalParams,\n ): PagedAsyncIterableIterator<QuotaUsage> {\n const iter = this.listPagingAll(locationName, options);\n return {\n next() {\n return iter.next();\n },\n [Symbol.asyncIterator]() {\n return this;\n },\n byPage: (settings?: PageSettings) => {\n if (settings?.maxPageSize) {\n throw new Error(\"maxPageSize is not supported by this operation.\");\n }\n return this.listPagingPage(locationName, options, settings);\n },\n };\n }\n\n private async *listPagingPage(\n locationName: string,\n options?: QuotaUsagesListOptionalParams,\n settings?: PageSettings,\n ): AsyncIterableIterator<QuotaUsage[]> {\n let result: QuotaUsagesListResponse;\n let continuationToken = settings?.continuationToken;\n if (!continuationToken) {\n result = await this._list(locationName, options);\n const page = result.value || [];\n continuationToken = result.nextLink;\n setContinuationToken(page, continuationToken);\n yield page;\n }\n while (continuationToken) {\n result = await this._listNext(locationName, continuationToken, options);\n continuationToken = result.nextLink;\n const page = result.value || [];\n setContinuationToken(page, continuationToken);\n yield page;\n }\n }\n\n private async *listPagingAll(\n locationName: string,\n options?: QuotaUsagesListOptionalParams,\n ): AsyncIterableIterator<QuotaUsage> {\n for await (const page of this.listPagingPage(locationName, options)) {\n yield* page;\n }\n }\n\n /**\n * Get quota usages at specified location in a given subscription.\n * @param locationName The name of the location.\n * @param options The options parameters.\n */\n private _list(\n locationName: string,\n options?: QuotaUsagesListOptionalParams,\n ): Promise<QuotaUsagesListResponse> {\n return this.client.sendOperationRequest({ locationName, options }, listOperationSpec);\n }\n\n /**\n * ListNext\n * @param locationName The name of the location.\n * @param nextLink The nextLink from the previous successful call to the List method.\n * @param options The options parameters.\n */\n private _listNext(\n locationName: string,\n nextLink: string,\n options?: QuotaUsagesListNextOptionalParams,\n ): Promise<QuotaUsagesListNextResponse> {\n return this.client.sendOperationRequest(\n { locationName, nextLink, options },\n listNextOperationSpec,\n );\n }\n}\n// Operation Specifications\nconst serializer = coreClient.createSerializer(Mappers, /* isXml */ false);\n\nconst listOperationSpec: coreClient.OperationSpec = {\n path: \"/subscriptions/{subscriptionId}/providers/Microsoft.DBforPostgreSQL/locations/{locationName}/resourceType/flexibleServers/usages\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.QuotaUsagesListResult,\n },\n default: {\n bodyMapper: Mappers.ErrorResponse,\n },\n },\n queryParameters: [Parameters.apiVersion],\n urlParameters: [Parameters.$host, Parameters.subscriptionId, Parameters.locationName],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst listNextOperationSpec: coreClient.OperationSpec = {\n path: \"{nextLink}\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.QuotaUsagesListResult,\n },\n default: {\n bodyMapper: Mappers.ErrorResponse,\n },\n },\n urlParameters: [\n Parameters.$host,\n Parameters.subscriptionId,\n Parameters.nextLink,\n Parameters.locationName,\n ],\n headerParameters: [Parameters.accept],\n serializer,\n};\n"]}
@@ -15,6 +15,7 @@ const Parameters = tslib_1.__importStar(require("../models/parameters.js"));
15
15
  /// <reference lib="esnext.asynciterable" />
16
16
  /** Class containing Replicas operations. */
17
17
  class ReplicasImpl {
18
+ client;
18
19
  /**
19
20
  * Initialize a new instance of the class Replicas class.
20
21
  * @param client Reference to the service client
@@ -38,39 +39,22 @@ class ReplicasImpl {
38
39
  return this;
39
40
  },
40
41
  byPage: (settings) => {
41
- if (settings === null || settings === void 0 ? void 0 : settings.maxPageSize) {
42
+ if (settings?.maxPageSize) {
42
43
  throw new Error("maxPageSize is not supported by this operation.");
43
44
  }
44
45
  return this.listByServerPagingPage(resourceGroupName, serverName, options, settings);
45
46
  },
46
47
  };
47
48
  }
48
- listByServerPagingPage(resourceGroupName, serverName, options, _settings) {
49
- return tslib_1.__asyncGenerator(this, arguments, function* listByServerPagingPage_1() {
50
- let result;
51
- result = yield tslib_1.__await(this._listByServer(resourceGroupName, serverName, options));
52
- yield yield tslib_1.__await(result.value || []);
53
- });
49
+ async *listByServerPagingPage(resourceGroupName, serverName, options, _settings) {
50
+ let result;
51
+ result = await this._listByServer(resourceGroupName, serverName, options);
52
+ yield result.value || [];
54
53
  }
55
- listByServerPagingAll(resourceGroupName, serverName, options) {
56
- return tslib_1.__asyncGenerator(this, arguments, function* listByServerPagingAll_1() {
57
- var _a, e_1, _b, _c;
58
- try {
59
- for (var _d = true, _e = tslib_1.__asyncValues(this.listByServerPagingPage(resourceGroupName, serverName, options)), _f; _f = yield tslib_1.__await(_e.next()), _a = _f.done, !_a; _d = true) {
60
- _c = _f.value;
61
- _d = false;
62
- const page = _c;
63
- yield tslib_1.__await(yield* tslib_1.__asyncDelegator(tslib_1.__asyncValues(page)));
64
- }
65
- }
66
- catch (e_1_1) { e_1 = { error: e_1_1 }; }
67
- finally {
68
- try {
69
- if (!_d && !_a && (_b = _e.return)) yield tslib_1.__await(_b.call(_e));
70
- }
71
- finally { if (e_1) throw e_1.error; }
72
- }
73
- });
54
+ async *listByServerPagingAll(resourceGroupName, serverName, options) {
55
+ for await (const page of this.listByServerPagingPage(resourceGroupName, serverName, options)) {
56
+ yield* page;
57
+ }
74
58
  }
75
59
  /**
76
60
  * List all the replicas for a given server.
@@ -1 +1 @@
1
- {"version":3,"file":"replicas.js","sourceRoot":"","sources":["../../../src/operations/replicas.ts"],"names":[],"mappings":";AAAA;;;;;;GAMG;;;;AAIH,uEAAiD;AACjD,sEAAgD;AAChD,4EAAsD;AAQtD,4CAA4C;AAC5C,4CAA4C;AAC5C,MAAa,YAAY;IAGvB;;;OAGG;IACH,YAAY,MAAgD;QAC1D,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC;IACvB,CAAC;IAED;;;;;OAKG;IACI,Y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AAA;IAED;;;;;OAKG;IACK,aAAa,CACnB,iBAAyB,EACzB,UAAkB,EAClB,OAA4C;QAE5C,OAAO,IAAI,CAAC,MAAM,CAAC,oBAAoB,CACrC,EAAE,iBAAiB,EAAE,UAAU,EAAE,OAAO,EAAE,EAC1C,yBAAyB,CAC1B,CAAC;IACJ,CAAC;CACF;AA5ED,oCA4EC;AACD,2BAA2B;AAC3B,MAAM,UAAU,GAAG,UAAU,CAAC,gBAAgB,CAAC,OAAO,EAAE,WAAW,CAAC,KAAK,CAAC,CAAC;AAE3E,MAAM,yBAAyB,GAA6B;IAC1D,IAAI,EAAE,8IAA8I;IACpJ,UAAU,EAAE,KAAK;IACjB,SAAS,EAAE;QACT,GAAG,EAAE;YACH,UAAU,EAAE,OAAO,CAAC,gBAAgB;SACrC;QACD,OAAO,EAAE;YACP,UAAU,EAAE,OAAO,CAAC,aAAa;SAClC;KACF;IACD,eAAe,EAAE,CAAC,UAAU,CAAC,UAAU,CAAC;IACxC,aAAa,EAAE;QACb,UAAU,CAAC,KAAK;QAChB,UAAU,CAAC,cAAc;QACzB,UAAU,CAAC,iBAAiB;QAC5B,UAAU,CAAC,UAAU;KACtB;IACD,gBAAgB,EAAE,CAAC,UAAU,CAAC,MAAM,CAAC;IACrC,UAAU;CACX,CAAC","sourcesContent":["/*\n * Copyright (c) Microsoft Corporation.\n * Licensed under the MIT License.\n *\n * Code generated by Microsoft (R) AutoRest Code Generator.\n * Changes may cause incorrect behavior and will be lost if the code is regenerated.\n */\n\nimport type { PagedAsyncIterableIterator, PageSettings } from \"@azure/core-paging\";\nimport type { Replicas } from \"../operationsInterfaces/index.js\";\nimport * as coreClient from \"@azure/core-client\";\nimport * as Mappers from \"../models/mappers.js\";\nimport * as Parameters from \"../models/parameters.js\";\nimport type { PostgreSQLManagementFlexibleServerClient } from \"../postgreSQLManagementFlexibleServerClient.js\";\nimport type {\n Server,\n ReplicasListByServerOptionalParams,\n ReplicasListByServerResponse,\n} from \"../models/index.js\";\n\n/// <reference lib=\"esnext.asynciterable\" />\n/** Class containing Replicas operations. */\nexport class ReplicasImpl implements Replicas {\n private readonly client: PostgreSQLManagementFlexibleServerClient;\n\n /**\n * Initialize a new instance of the class Replicas class.\n * @param client Reference to the service client\n */\n constructor(client: PostgreSQLManagementFlexibleServerClient) {\n this.client = client;\n }\n\n /**\n * List all the replicas for a given server.\n * @param resourceGroupName The name of the resource group. The name is case insensitive.\n * @param serverName The name of the server.\n * @param options The options parameters.\n */\n public listByServer(\n resourceGroupName: string,\n serverName: string,\n options?: ReplicasListByServerOptionalParams,\n ): PagedAsyncIterableIterator<Server> {\n const iter = this.listByServerPagingAll(resourceGroupName, serverName, options);\n return {\n next() {\n return iter.next();\n },\n [Symbol.asyncIterator]() {\n return this;\n },\n byPage: (settings?: PageSettings) => {\n if (settings?.maxPageSize) {\n throw new Error(\"maxPageSize is not supported by this operation.\");\n }\n return this.listByServerPagingPage(resourceGroupName, serverName, options, settings);\n },\n };\n }\n\n private async *listByServerPagingPage(\n resourceGroupName: string,\n serverName: string,\n options?: ReplicasListByServerOptionalParams,\n _settings?: PageSettings,\n ): AsyncIterableIterator<Server[]> {\n let result: ReplicasListByServerResponse;\n result = await this._listByServer(resourceGroupName, serverName, options);\n yield result.value || [];\n }\n\n private async *listByServerPagingAll(\n resourceGroupName: string,\n serverName: string,\n options?: ReplicasListByServerOptionalParams,\n ): AsyncIterableIterator<Server> {\n for await (const page of this.listByServerPagingPage(resourceGroupName, serverName, options)) {\n yield* page;\n }\n }\n\n /**\n * List all the replicas for a given server.\n * @param resourceGroupName The name of the resource group. The name is case insensitive.\n * @param serverName The name of the server.\n * @param options The options parameters.\n */\n private _listByServer(\n resourceGroupName: string,\n serverName: string,\n options?: ReplicasListByServerOptionalParams,\n ): Promise<ReplicasListByServerResponse> {\n return this.client.sendOperationRequest(\n { resourceGroupName, serverName, options },\n listByServerOperationSpec,\n );\n }\n}\n// Operation Specifications\nconst serializer = coreClient.createSerializer(Mappers, /* isXml */ false);\n\nconst listByServerOperationSpec: coreClient.OperationSpec = {\n path: \"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL/flexibleServers/{serverName}/replicas\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.ServerListResult,\n },\n default: {\n bodyMapper: Mappers.ErrorResponse,\n },\n },\n queryParameters: [Parameters.apiVersion],\n urlParameters: [\n Parameters.$host,\n Parameters.subscriptionId,\n Parameters.resourceGroupName,\n Parameters.serverName,\n ],\n headerParameters: [Parameters.accept],\n serializer,\n};\n"]}
1
+ {"version":3,"file":"replicas.js","sourceRoot":"","sources":["../../../src/operations/replicas.ts"],"names":[],"mappings":";AAAA;;;;;;GAMG;;;;AAIH,uEAAiD;AACjD,sEAAgD;AAChD,4EAAsD;AAQtD,4CAA4C;AAC5C,4CAA4C;AAC5C,MAAa,YAAY;IACN,MAAM,CAA2C;IAElE;;;OAGG;IACH,YAAY,MAAgD;QAC1D,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC;IACvB,CAAC;IAED;;;;;OAKG;IACI,YAAY,CACjB,iBAAyB,EACzB,UAAkB,EAClB,OAA4C;QAE5C,MAAM,IAAI,GAAG,IAAI,CAAC,qBAAqB,CAAC,iBAAiB,EAAE,UAAU,EAAE,OAAO,CAAC,CAAC;QAChF,OAAO;YACL,IAAI;gBACF,OAAO,IAAI,CAAC,IAAI,EAAE,CAAC;YACrB,CAAC;YACD,CAAC,MAAM,CAAC,aAAa,CAAC;gBACpB,OAAO,IAAI,CAAC;YACd,CAAC;YACD,MAAM,EAAE,CAAC,QAAuB,EAAE,EAAE;gBAClC,IAAI,QAAQ,EAAE,WAAW,EAAE,CAAC;oBAC1B,MAAM,IAAI,KAAK,CAAC,iDAAiD,CAAC,CAAC;gBACrE,CAAC;gBACD,OAAO,IAAI,CAAC,sBAAsB,CAAC,iBAAiB,EAAE,UAAU,EAAE,OAAO,EAAE,QAAQ,CAAC,CAAC;YACvF,CAAC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AAiB;QAC5B,UAAU,CAAC,UAAU;KACtB;IACD,gBAAgB,EAAE,CAAC,UAAU,CAAC,MAAM,CAAC;IACrC,UAAU;CACX,CAAC","sourcesContent":["/*\n * Copyright (c) Microsoft Corporation.\n * Licensed under the MIT License.\n *\n * Code generated by Microsoft (R) AutoRest Code Generator.\n * Changes may cause incorrect behavior and will be lost if the code is regenerated.\n */\n\nimport type { PagedAsyncIterableIterator, PageSettings } from \"@azure/core-paging\";\nimport type { Replicas } from \"../operationsInterfaces/index.js\";\nimport * as coreClient from \"@azure/core-client\";\nimport * as Mappers from \"../models/mappers.js\";\nimport * as Parameters from \"../models/parameters.js\";\nimport type { PostgreSQLManagementFlexibleServerClient } from \"../postgreSQLManagementFlexibleServerClient.js\";\nimport type {\n Server,\n ReplicasListByServerOptionalParams,\n ReplicasListByServerResponse,\n} from \"../models/index.js\";\n\n/// <reference lib=\"esnext.asynciterable\" />\n/** Class containing Replicas operations. */\nexport class ReplicasImpl implements Replicas {\n private readonly client: PostgreSQLManagementFlexibleServerClient;\n\n /**\n * Initialize a new instance of the class Replicas class.\n * @param client Reference to the service client\n */\n constructor(client: PostgreSQLManagementFlexibleServerClient) {\n this.client = client;\n }\n\n /**\n * List all the replicas for a given server.\n * @param resourceGroupName The name of the resource group. The name is case insensitive.\n * @param serverName The name of the server.\n * @param options The options parameters.\n */\n public listByServer(\n resourceGroupName: string,\n serverName: string,\n options?: ReplicasListByServerOptionalParams,\n ): PagedAsyncIterableIterator<Server> {\n const iter = this.listByServerPagingAll(resourceGroupName, serverName, options);\n return {\n next() {\n return iter.next();\n },\n [Symbol.asyncIterator]() {\n return this;\n },\n byPage: (settings?: PageSettings) => {\n if (settings?.maxPageSize) {\n throw new Error(\"maxPageSize is not supported by this operation.\");\n }\n return this.listByServerPagingPage(resourceGroupName, serverName, options, settings);\n },\n };\n }\n\n private async *listByServerPagingPage(\n resourceGroupName: string,\n serverName: string,\n options?: ReplicasListByServerOptionalParams,\n _settings?: PageSettings,\n ): AsyncIterableIterator<Server[]> {\n let result: ReplicasListByServerResponse;\n result = await this._listByServer(resourceGroupName, serverName, options);\n yield result.value || [];\n }\n\n private async *listByServerPagingAll(\n resourceGroupName: string,\n serverName: string,\n options?: ReplicasListByServerOptionalParams,\n ): AsyncIterableIterator<Server> {\n for await (const page of this.listByServerPagingPage(resourceGroupName, serverName, options)) {\n yield* page;\n }\n }\n\n /**\n * List all the replicas for a given server.\n * @param resourceGroupName The name of the resource group. The name is case insensitive.\n * @param serverName The name of the server.\n * @param options The options parameters.\n */\n private _listByServer(\n resourceGroupName: string,\n serverName: string,\n options?: ReplicasListByServerOptionalParams,\n ): Promise<ReplicasListByServerResponse> {\n return this.client.sendOperationRequest(\n { resourceGroupName, serverName, options },\n listByServerOperationSpec,\n );\n }\n}\n// Operation Specifications\nconst serializer = coreClient.createSerializer(Mappers, /* isXml */ false);\n\nconst listByServerOperationSpec: coreClient.OperationSpec = {\n path: \"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL/flexibleServers/{serverName}/replicas\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.ServerListResult,\n },\n default: {\n bodyMapper: Mappers.ErrorResponse,\n },\n },\n queryParameters: [Parameters.apiVersion],\n urlParameters: [\n Parameters.$host,\n Parameters.subscriptionId,\n Parameters.resourceGroupName,\n Parameters.serverName,\n ],\n headerParameters: [Parameters.accept],\n serializer,\n};\n"]}