From 1f44675193543b3d938953686ff2c9728fe6124a Mon Sep 17 00:00:00 2001 From: Azure SDK for Python bot Date: Wed, 1 Aug 2018 00:34:40 +0000 Subject: [PATCH 1/2] Generated from 6162973ef0993464a1806f8db5ca913f0fa5d6c8 WebApps - Add BackupName to replace non-ARM-compliant Name property on Backup API models --- .../appservice/v2018_02_01/BackupItem.java | 4 +-- .../appservice/v2018_02_01/BackupRequest.java | 5 ++++ .../implementation/BackupItemImpl.java | 4 +-- .../implementation/BackupItemInner.java | 10 +++---- .../implementation/BackupRequestImpl.java | 5 ++++ .../implementation/BackupRequestInner.java | 26 +++++++++++++++++++ 6 files changed, 45 insertions(+), 9 deletions(-) diff --git a/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/BackupItem.java b/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/BackupItem.java index 2e187093296af..3ec6734c969fa 100644 --- a/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/BackupItem.java +++ b/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/BackupItem.java @@ -27,9 +27,9 @@ public interface BackupItem extends HasInner, Indexable, Refres Integer backupId(); /** - * @return the backupItemName value. + * @return the backupName value. */ - String backupItemName(); + String backupName(); /** * @return the blobName value. diff --git a/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/BackupRequest.java b/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/BackupRequest.java index 9abce3c796a20..360067ff27a63 100644 --- a/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/BackupRequest.java +++ b/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/BackupRequest.java @@ -18,6 +18,11 @@ * Type representing BackupRequest. */ public interface BackupRequest extends HasInner, HasManager { + /** + * @return the backupName value. + */ + String backupName(); + /** * @return the backupSchedule value. */ diff --git a/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/implementation/BackupItemImpl.java b/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/implementation/BackupItemImpl.java index d8e13e76677c6..9a0f0212d15f4 100644 --- a/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/implementation/BackupItemImpl.java +++ b/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/implementation/BackupItemImpl.java @@ -49,8 +49,8 @@ public Integer backupId() { } @Override - public String backupItemName() { - return this.inner().backupItemName(); + public String backupName() { + return this.inner().backupName(); } @Override diff --git a/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/implementation/BackupItemInner.java b/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/implementation/BackupItemInner.java index f318e8d6103d0..2f6772c5ef8f7 100644 --- a/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/implementation/BackupItemInner.java +++ b/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/implementation/BackupItemInner.java @@ -42,8 +42,8 @@ public class BackupItemInner extends ProxyOnlyResource { /** * Name of this backup. */ - @JsonProperty(value = "properties.name", access = JsonProperty.Access.WRITE_ONLY) - private String backupItemName; + @JsonProperty(value = "properties.backupName", access = JsonProperty.Access.WRITE_ONLY) + private String backupName; /** * Backup status. Possible values include: 'InProgress', 'Failed', @@ -138,10 +138,10 @@ public String blobName() { /** * Get name of this backup. * - * @return the backupItemName value + * @return the backupName value */ - public String backupItemName() { - return this.backupItemName; + public String backupName() { + return this.backupName; } /** diff --git a/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/implementation/BackupRequestImpl.java b/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/implementation/BackupRequestImpl.java index b5045b977f38e..9ba81549824ac 100644 --- a/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/implementation/BackupRequestImpl.java +++ b/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/implementation/BackupRequestImpl.java @@ -26,6 +26,11 @@ public CertificateRegistrationManager manager() { return this.manager; } + @Override + public String backupName() { + return this.inner().backupName(); + } + @Override public BackupSchedule backupSchedule() { return this.inner().backupSchedule(); diff --git a/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/implementation/BackupRequestInner.java b/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/implementation/BackupRequestInner.java index e761a1d8b2cb1..581fe11bb33dd 100644 --- a/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/implementation/BackupRequestInner.java +++ b/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/implementation/BackupRequestInner.java @@ -20,6 +20,12 @@ */ @JsonFlatten public class BackupRequestInner extends ProxyOnlyResource { + /** + * Name of the backup. + */ + @JsonProperty(value = "properties.backupName") + private String backupName; + /** * True if the backup schedule is enabled (must be included in that case), * false if the backup schedule should be disabled. @@ -45,6 +51,26 @@ public class BackupRequestInner extends ProxyOnlyResource { @JsonProperty(value = "properties.databases") private List databases; + /** + * Get name of the backup. + * + * @return the backupName value + */ + public String backupName() { + return this.backupName; + } + + /** + * Set name of the backup. + * + * @param backupName the backupName value to set + * @return the BackupRequestInner object itself. + */ + public BackupRequestInner withBackupName(String backupName) { + this.backupName = backupName; + return this; + } + /** * Get true if the backup schedule is enabled (must be included in that case), false if the backup schedule should be disabled. * From 86b3fdefe1f3ac69e260ba966f774adf766a4bf7 Mon Sep 17 00:00:00 2001 From: Azure SDK for Python bot Date: Tue, 14 Aug 2018 21:49:22 +0000 Subject: [PATCH 2/2] Generated from c8664a06cff19844eb381ad410872b34cba23b27 Revert breaking change to BackupItem. BackupItemName property will be fine in place of BackupName for now. --- .../v2018_02_01/AzureStorageInfoValue.java | 13 +- .../appservice/v2018_02_01/BackupItem.java | 4 +- .../CsmPublishingProfileOptions.java | 26 + .../appservice/v2018_02_01/SiteConfig.java | 27 + .../v2018_02_01/SiteConfigResource.java | 6 + .../v2018_02_01/SlotConfigNamesResource.java | 5 + .../appservice/v2018_02_01/WebApps.java | 55 +- .../implementation/BackupItemImpl.java | 4 +- .../implementation/BackupItemInner.java | 10 +- .../SiteConfigResourceImpl.java | 7 + .../SiteConfigResourceInner.java | 28 + .../SlotConfigNamesResourceImpl.java | 5 + .../SlotConfigNamesResourceInner.java | 26 + .../implementation/WebAppsImpl.java | 58 +- .../implementation/WebAppsInner.java | 670 ++++++++++++------ 15 files changed, 685 insertions(+), 259 deletions(-) diff --git a/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/AzureStorageInfoValue.java b/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/AzureStorageInfoValue.java index da5b89782f8be..4cf1e5f2abf71 100644 --- a/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/AzureStorageInfoValue.java +++ b/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/AzureStorageInfoValue.java @@ -48,7 +48,7 @@ public class AzureStorageInfoValue { * State of the storage account. Possible values include: 'Ok', * 'InvalidCredentials', 'InvalidShare'. */ - @JsonProperty(value = "state") + @JsonProperty(value = "state", access = JsonProperty.Access.WRITE_ONLY) private AzureStorageState state; /** @@ -160,15 +160,4 @@ public AzureStorageState state() { return this.state; } - /** - * Set state of the storage account. Possible values include: 'Ok', 'InvalidCredentials', 'InvalidShare'. - * - * @param state the state value to set - * @return the AzureStorageInfoValue object itself. - */ - public AzureStorageInfoValue withState(AzureStorageState state) { - this.state = state; - return this; - } - } diff --git a/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/BackupItem.java b/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/BackupItem.java index 3ec6734c969fa..2e187093296af 100644 --- a/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/BackupItem.java +++ b/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/BackupItem.java @@ -27,9 +27,9 @@ public interface BackupItem extends HasInner, Indexable, Refres Integer backupId(); /** - * @return the backupName value. + * @return the backupItemName value. */ - String backupName(); + String backupItemName(); /** * @return the blobName value. diff --git a/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/CsmPublishingProfileOptions.java b/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/CsmPublishingProfileOptions.java index 9d6f9e7e6eb62..3c1d6d2b006a2 100644 --- a/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/CsmPublishingProfileOptions.java +++ b/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/CsmPublishingProfileOptions.java @@ -23,6 +23,12 @@ public class CsmPublishingProfileOptions { @JsonProperty(value = "format") private PublishingProfileFormat format; + /** + * Include the DisasterRecover endpoint if true. + */ + @JsonProperty(value = "includeDisasterRecoveryEndpoints") + private Boolean includeDisasterRecoveryEndpoints; + /** * Get name of the format. Valid values are: FileZilla3 @@ -49,4 +55,24 @@ public CsmPublishingProfileOptions withFormat(PublishingProfileFormat format) { return this; } + /** + * Get include the DisasterRecover endpoint if true. + * + * @return the includeDisasterRecoveryEndpoints value + */ + public Boolean includeDisasterRecoveryEndpoints() { + return this.includeDisasterRecoveryEndpoints; + } + + /** + * Set include the DisasterRecover endpoint if true. + * + * @param includeDisasterRecoveryEndpoints the includeDisasterRecoveryEndpoints value to set + * @return the CsmPublishingProfileOptions object itself. + */ + public CsmPublishingProfileOptions withIncludeDisasterRecoveryEndpoints(Boolean includeDisasterRecoveryEndpoints) { + this.includeDisasterRecoveryEndpoints = includeDisasterRecoveryEndpoints; + return this; + } + } diff --git a/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/SiteConfig.java b/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/SiteConfig.java index a0501c8e645e7..c36b338ac1476 100644 --- a/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/SiteConfig.java +++ b/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/SiteConfig.java @@ -10,6 +10,7 @@ import java.util.List; import org.joda.time.DateTime; +import java.util.Map; import com.microsoft.azure.management.appservice.v2018_02_01.implementation.PushSettingsInner; import com.fasterxml.jackson.annotation.JsonProperty; @@ -123,6 +124,12 @@ public class SiteConfig { @JsonProperty(value = "appSettings") private List appSettings; + /** + * User-provided Azure storage accounts. + */ + @JsonProperty(value = "azureStorageAccounts") + private Map azureStorageAccounts; + /** * Connection strings. */ @@ -674,6 +681,26 @@ public SiteConfig withAppSettings(List appSettings) { return this; } + /** + * Get user-provided Azure storage accounts. + * + * @return the azureStorageAccounts value + */ + public Map azureStorageAccounts() { + return this.azureStorageAccounts; + } + + /** + * Set user-provided Azure storage accounts. + * + * @param azureStorageAccounts the azureStorageAccounts value to set + * @return the SiteConfig object itself. + */ + public SiteConfig withAzureStorageAccounts(Map azureStorageAccounts) { + this.azureStorageAccounts = azureStorageAccounts; + return this; + } + /** * Get connection strings. * diff --git a/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/SiteConfigResource.java b/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/SiteConfigResource.java index 3f74dd3ca954d..aa5dd7d05142c 100644 --- a/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/SiteConfigResource.java +++ b/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/SiteConfigResource.java @@ -13,6 +13,7 @@ import com.microsoft.azure.management.appservice.v2018_02_01.implementation.CertificateRegistrationManager; import com.microsoft.azure.management.appservice.v2018_02_01.implementation.SiteConfigResourceInner; import java.util.List; +import java.util.Map; import com.microsoft.azure.management.appservice.v2018_02_01.implementation.PushSettingsInner; import org.joda.time.DateTime; @@ -55,6 +56,11 @@ public interface SiteConfigResource extends HasInner, H */ String autoSwapSlotName(); + /** + * @return the azureStorageAccounts value. + */ + Map azureStorageAccounts(); + /** * @return the connectionStrings value. */ diff --git a/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/SlotConfigNamesResource.java b/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/SlotConfigNamesResource.java index 44ab65222eda1..40c8aa5a96d15 100644 --- a/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/SlotConfigNamesResource.java +++ b/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/SlotConfigNamesResource.java @@ -23,6 +23,11 @@ public interface SlotConfigNamesResource extends HasInner appSettingNames(); + /** + * @return the azureStorageConfigNames value. + */ + List azureStorageConfigNames(); + /** * @return the connectionStringNames value. */ diff --git a/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/WebApps.java b/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/WebApps.java index 7038632bc9e72..fea43d4e3cf28 100644 --- a/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/WebApps.java +++ b/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/WebApps.java @@ -19,6 +19,7 @@ import com.microsoft.azure.management.appservice.v2018_02_01.implementation.RelayServiceConnectionEntityInner; import com.microsoft.azure.management.appservice.v2018_02_01.BackupItem; import com.microsoft.azure.management.appservice.v2018_02_01.implementation.SiteAuthSettingsInner; +import com.microsoft.azure.management.appservice.v2018_02_01.implementation.AzureStoragePropertyDictionaryResourceInner; import com.microsoft.azure.management.appservice.v2018_02_01.implementation.ConnectionStringDictionaryInner; import com.microsoft.azure.management.appservice.v2018_02_01.implementation.SiteLogsConfigInner; import com.microsoft.azure.management.appservice.v2018_02_01.implementation.PushSettingsInner; @@ -576,10 +577,11 @@ public interface WebApps { * * @param resourceGroupName Name of the resource group to which the resource belongs. * @param name Name of the app. + * @param publishingProfileOptions Specifies publishingProfileOptions for publishing profile. For example, use {"format": "FileZilla3"} to get a FileZilla publishing profile. * @throws IllegalArgumentException thrown if parameters fail the validation * @return the observable for the request */ - Completable listPublishingProfileXmlWithSecretsAsync(String resourceGroupName, String name); + Completable listPublishingProfileXmlWithSecretsAsync(String resourceGroupName, String name, CsmPublishingProfileOptions publishingProfileOptions); /** * Resets the configuration settings of the current slot if they were previously modified by calling the API with POST. @@ -930,6 +932,54 @@ public interface WebApps { */ Observable getAuthSettingsSlotAsync(String resourceGroupName, String name, String slot); + /** + * Updates the Azure storage account configurations of an app. + * Updates the Azure storage account configurations of an app. + * + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the app. + * @param azureStorageAccounts Azure storage accounts of the app. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable updateAzureStorageAccountsAsync(String resourceGroupName, String name, AzureStoragePropertyDictionaryResourceInner azureStorageAccounts); + + /** + * Gets the Azure storage account configurations of an app. + * Gets the Azure storage account configurations of an app. + * + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the app. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable listAzureStorageAccountsAsync(String resourceGroupName, String name); + + /** + * Updates the Azure storage account configurations of an app. + * Updates the Azure storage account configurations of an app. + * + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the app. + * @param slot Name of the deployment slot. If a slot is not specified, the API will update the Azure storage account configurations for the production slot. + * @param azureStorageAccounts Azure storage accounts of the app. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable updateAzureStorageAccountsSlotAsync(String resourceGroupName, String name, String slot, AzureStoragePropertyDictionaryResourceInner azureStorageAccounts); + + /** + * Gets the Azure storage account configurations of an app. + * Gets the Azure storage account configurations of an app. + * + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the app. + * @param slot Name of the deployment slot. If a slot is not specified, the API will update the Azure storage account configurations for the production slot. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable listAzureStorageAccountsSlotAsync(String resourceGroupName, String name, String slot); + /** * Replaces the connection strings of an app. * Replaces the connection strings of an app. @@ -3347,10 +3397,11 @@ public interface WebApps { * @param resourceGroupName Name of the resource group to which the resource belongs. * @param name Name of the app. * @param slot Name of the deployment slot. If a slot is not specified, the API will get the publishing profile for the production slot. + * @param publishingProfileOptions Specifies publishingProfileOptions for publishing profile. For example, use {"format": "FileZilla3"} to get a FileZilla publishing profile. * @throws IllegalArgumentException thrown if parameters fail the validation * @return the observable for the request */ - Completable listPublishingProfileXmlWithSecretsSlotAsync(String resourceGroupName, String name, String slot); + Completable listPublishingProfileXmlWithSecretsSlotAsync(String resourceGroupName, String name, String slot, CsmPublishingProfileOptions publishingProfileOptions); /** * Resets the configuration settings of the current slot if they were previously modified by calling the API with POST. diff --git a/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/implementation/BackupItemImpl.java b/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/implementation/BackupItemImpl.java index 9a0f0212d15f4..d8e13e76677c6 100644 --- a/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/implementation/BackupItemImpl.java +++ b/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/implementation/BackupItemImpl.java @@ -49,8 +49,8 @@ public Integer backupId() { } @Override - public String backupName() { - return this.inner().backupName(); + public String backupItemName() { + return this.inner().backupItemName(); } @Override diff --git a/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/implementation/BackupItemInner.java b/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/implementation/BackupItemInner.java index 2f6772c5ef8f7..f318e8d6103d0 100644 --- a/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/implementation/BackupItemInner.java +++ b/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/implementation/BackupItemInner.java @@ -42,8 +42,8 @@ public class BackupItemInner extends ProxyOnlyResource { /** * Name of this backup. */ - @JsonProperty(value = "properties.backupName", access = JsonProperty.Access.WRITE_ONLY) - private String backupName; + @JsonProperty(value = "properties.name", access = JsonProperty.Access.WRITE_ONLY) + private String backupItemName; /** * Backup status. Possible values include: 'InProgress', 'Failed', @@ -138,10 +138,10 @@ public String blobName() { /** * Get name of this backup. * - * @return the backupName value + * @return the backupItemName value */ - public String backupName() { - return this.backupName; + public String backupItemName() { + return this.backupItemName; } /** diff --git a/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/implementation/SiteConfigResourceImpl.java b/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/implementation/SiteConfigResourceImpl.java index 7077b3ece345a..65f6282a60909 100644 --- a/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/implementation/SiteConfigResourceImpl.java +++ b/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/implementation/SiteConfigResourceImpl.java @@ -14,6 +14,8 @@ import java.util.List; import com.microsoft.azure.management.appservice.v2018_02_01.NameValuePair; import com.microsoft.azure.management.appservice.v2018_02_01.AutoHealRules; +import java.util.Map; +import com.microsoft.azure.management.appservice.v2018_02_01.AzureStorageInfoValue; import com.microsoft.azure.management.appservice.v2018_02_01.ConnStringInfo; import com.microsoft.azure.management.appservice.v2018_02_01.CorsSettings; import com.microsoft.azure.management.appservice.v2018_02_01.Experiments; @@ -76,6 +78,11 @@ public String autoSwapSlotName() { return this.inner().autoSwapSlotName(); } + @Override + public Map azureStorageAccounts() { + return this.inner().azureStorageAccounts(); + } + @Override public List connectionStrings() { return this.inner().connectionStrings(); diff --git a/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/implementation/SiteConfigResourceInner.java b/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/implementation/SiteConfigResourceInner.java index 85ede7cd7286e..647109a1712d6 100644 --- a/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/implementation/SiteConfigResourceInner.java +++ b/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/implementation/SiteConfigResourceInner.java @@ -11,6 +11,8 @@ import java.util.List; import org.joda.time.DateTime; import com.microsoft.azure.management.appservice.v2018_02_01.NameValuePair; +import java.util.Map; +import com.microsoft.azure.management.appservice.v2018_02_01.AzureStorageInfoValue; import com.microsoft.azure.management.appservice.v2018_02_01.ConnStringInfo; import com.microsoft.azure.management.appservice.v2018_02_01.SiteMachineKey; import com.microsoft.azure.management.appservice.v2018_02_01.HandlerMapping; @@ -141,6 +143,12 @@ public class SiteConfigResourceInner extends ProxyOnlyResource { @JsonProperty(value = "properties.appSettings") private List appSettings; + /** + * User-provided Azure storage accounts. + */ + @JsonProperty(value = "properties.azureStorageAccounts") + private Map azureStorageAccounts; + /** * Connection strings. */ @@ -692,6 +700,26 @@ public SiteConfigResourceInner withAppSettings(List appSettings) return this; } + /** + * Get user-provided Azure storage accounts. + * + * @return the azureStorageAccounts value + */ + public Map azureStorageAccounts() { + return this.azureStorageAccounts; + } + + /** + * Set user-provided Azure storage accounts. + * + * @param azureStorageAccounts the azureStorageAccounts value to set + * @return the SiteConfigResourceInner object itself. + */ + public SiteConfigResourceInner withAzureStorageAccounts(Map azureStorageAccounts) { + this.azureStorageAccounts = azureStorageAccounts; + return this; + } + /** * Get connection strings. * diff --git a/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/implementation/SlotConfigNamesResourceImpl.java b/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/implementation/SlotConfigNamesResourceImpl.java index 78f2a61c18aa5..c9780717ed85f 100644 --- a/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/implementation/SlotConfigNamesResourceImpl.java +++ b/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/implementation/SlotConfigNamesResourceImpl.java @@ -29,6 +29,11 @@ public List appSettingNames() { return this.inner().appSettingNames(); } + @Override + public List azureStorageConfigNames() { + return this.inner().azureStorageConfigNames(); + } + @Override public List connectionStringNames() { return this.inner().connectionStringNames(); diff --git a/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/implementation/SlotConfigNamesResourceInner.java b/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/implementation/SlotConfigNamesResourceInner.java index 88c96aaf291e2..543d8e0e344ee 100644 --- a/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/implementation/SlotConfigNamesResourceInner.java +++ b/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/implementation/SlotConfigNamesResourceInner.java @@ -30,6 +30,12 @@ public class SlotConfigNamesResourceInner extends ProxyOnlyResource { @JsonProperty(value = "properties.appSettingNames") private List appSettingNames; + /** + * List of external Azure storage account identifiers. + */ + @JsonProperty(value = "properties.azureStorageConfigNames") + private List azureStorageConfigNames; + /** * Get list of connection string names. * @@ -70,4 +76,24 @@ public SlotConfigNamesResourceInner withAppSettingNames(List appSettingN return this; } + /** + * Get list of external Azure storage account identifiers. + * + * @return the azureStorageConfigNames value + */ + public List azureStorageConfigNames() { + return this.azureStorageConfigNames; + } + + /** + * Set list of external Azure storage account identifiers. + * + * @param azureStorageConfigNames the azureStorageConfigNames value to set + * @return the SlotConfigNamesResourceInner object itself. + */ + public SlotConfigNamesResourceInner withAzureStorageConfigNames(List azureStorageConfigNames) { + this.azureStorageConfigNames = azureStorageConfigNames; + return this; + } + } diff --git a/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/implementation/WebAppsImpl.java b/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/implementation/WebAppsImpl.java index ae9c7c9f449a4..d8d7a17fd3949 100644 --- a/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/implementation/WebAppsImpl.java +++ b/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/implementation/WebAppsImpl.java @@ -33,9 +33,11 @@ import com.microsoft.azure.management.appservice.v2018_02_01.CsmSlotEntity; import com.microsoft.azure.management.appservice.v2018_02_01.StorageMigrationOptions; import com.microsoft.azure.management.appservice.v2018_02_01.MigrateMySqlRequest; +import com.microsoft.azure.management.appservice.v2018_02_01.CsmPublishingProfileOptions; import com.microsoft.azure.management.appservice.v2018_02_01.DeletedAppRestoreRequest; import com.microsoft.azure.management.appservice.v2018_02_01.SnapshotRestoreRequest; import com.microsoft.azure.management.appservice.v2018_02_01.SiteAuthSettings; +import com.microsoft.azure.management.appservice.v2018_02_01.AzureStoragePropertyDictionaryResource; import com.microsoft.azure.management.appservice.v2018_02_01.ConnectionStringDictionary; import com.microsoft.azure.management.appservice.v2018_02_01.SiteLogsConfig; import com.microsoft.azure.management.appservice.v2018_02_01.User; @@ -863,9 +865,9 @@ public Completable getProcessDumpAsync(String resourceGroupName, String name, St } @Override - public Completable listPublishingProfileXmlWithSecretsAsync(String resourceGroupName, String name) { + public Completable listPublishingProfileXmlWithSecretsAsync(String resourceGroupName, String name, CsmPublishingProfileOptions publishingProfileOptions) { WebAppsInner client = this.inner(); - return client.listPublishingProfileXmlWithSecretsAsync(resourceGroupName, name).toCompletable(); + return client.listPublishingProfileXmlWithSecretsAsync(resourceGroupName, name, publishingProfileOptions).toCompletable(); } @Override @@ -1150,6 +1152,54 @@ public SiteAuthSettings call(SiteAuthSettingsInner inner) { }); } + @Override + public Observable updateAzureStorageAccountsAsync(String resourceGroupName, String name, AzureStoragePropertyDictionaryResourceInner azureStorageAccounts) { + WebAppsInner client = this.inner(); + return client.updateAzureStorageAccountsAsync(resourceGroupName, name, azureStorageAccounts) + .map(new Func1() { + @Override + public AzureStoragePropertyDictionaryResource call(AzureStoragePropertyDictionaryResourceInner inner) { + return new AzureStoragePropertyDictionaryResourceImpl(inner, manager()); + } + }); + } + + @Override + public Observable listAzureStorageAccountsAsync(String resourceGroupName, String name) { + WebAppsInner client = this.inner(); + return client.listAzureStorageAccountsAsync(resourceGroupName, name) + .map(new Func1() { + @Override + public AzureStoragePropertyDictionaryResource call(AzureStoragePropertyDictionaryResourceInner inner) { + return new AzureStoragePropertyDictionaryResourceImpl(inner, manager()); + } + }); + } + + @Override + public Observable updateAzureStorageAccountsSlotAsync(String resourceGroupName, String name, String slot, AzureStoragePropertyDictionaryResourceInner azureStorageAccounts) { + WebAppsInner client = this.inner(); + return client.updateAzureStorageAccountsSlotAsync(resourceGroupName, name, slot, azureStorageAccounts) + .map(new Func1() { + @Override + public AzureStoragePropertyDictionaryResource call(AzureStoragePropertyDictionaryResourceInner inner) { + return new AzureStoragePropertyDictionaryResourceImpl(inner, manager()); + } + }); + } + + @Override + public Observable listAzureStorageAccountsSlotAsync(String resourceGroupName, String name, String slot) { + WebAppsInner client = this.inner(); + return client.listAzureStorageAccountsSlotAsync(resourceGroupName, name, slot) + .map(new Func1() { + @Override + public AzureStoragePropertyDictionaryResource call(AzureStoragePropertyDictionaryResourceInner inner) { + return new AzureStoragePropertyDictionaryResourceImpl(inner, manager()); + } + }); + } + @Override public Observable updateConnectionStringsAsync(String resourceGroupName, String name, ConnectionStringDictionaryInner connectionStrings) { WebAppsInner client = this.inner(); @@ -3449,9 +3499,9 @@ public Completable getProcessDumpSlotAsync(String resourceGroupName, String name } @Override - public Completable listPublishingProfileXmlWithSecretsSlotAsync(String resourceGroupName, String name, String slot) { + public Completable listPublishingProfileXmlWithSecretsSlotAsync(String resourceGroupName, String name, String slot, CsmPublishingProfileOptions publishingProfileOptions) { WebAppsInner client = this.inner(); - return client.listPublishingProfileXmlWithSecretsSlotAsync(resourceGroupName, name, slot).toCompletable(); + return client.listPublishingProfileXmlWithSecretsSlotAsync(resourceGroupName, name, slot, publishingProfileOptions).toCompletable(); } @Override diff --git a/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/implementation/WebAppsInner.java b/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/implementation/WebAppsInner.java index b19645f446cd3..10a0ec7e73f94 100644 --- a/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/implementation/WebAppsInner.java +++ b/appservice/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/implementation/WebAppsInner.java @@ -23,7 +23,6 @@ import com.microsoft.azure.management.appservice.v2018_02_01.MigrateMySqlRequest; import com.microsoft.azure.management.appservice.v2018_02_01.MSDeploy; import com.microsoft.azure.management.appservice.v2018_02_01.PremierAddOnPatchResource; -import com.microsoft.azure.management.appservice.v2018_02_01.PublishingProfileFormat; import com.microsoft.azure.management.appservice.v2018_02_01.SitePatchResource; import com.microsoft.azure.management.appservice.v2018_02_01.SnapshotRestoreRequest; import com.microsoft.azure.management.appservice.v2018_02_01.StorageMigrationOptions; @@ -163,6 +162,14 @@ interface WebAppsService { @POST("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/config/authsettings/list") Observable> getAuthSettings(@Path("resourceGroupName") String resourceGroupName, @Path("name") String name, @Path("subscriptionId") String subscriptionId, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.appservice.v2018_02_01.WebApps updateAzureStorageAccounts" }) + @PUT("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/config/azurestorageaccounts") + Observable> updateAzureStorageAccounts(@Path("resourceGroupName") String resourceGroupName, @Path("name") String name, @Path("subscriptionId") String subscriptionId, @Body AzureStoragePropertyDictionaryResourceInner azureStorageAccounts, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.appservice.v2018_02_01.WebApps listAzureStorageAccounts" }) + @POST("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/config/azurestorageaccounts/list") + Observable> listAzureStorageAccounts(@Path("resourceGroupName") String resourceGroupName, @Path("name") String name, @Path("subscriptionId") String subscriptionId, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.appservice.v2018_02_01.WebApps updateBackupConfiguration" }) @PUT("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/config/backup") Observable> updateBackupConfiguration(@Path("resourceGroupName") String resourceGroupName, @Path("name") String name, @Path("subscriptionId") String subscriptionId, @Body BackupRequestInner request, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); @@ -634,7 +641,7 @@ interface WebAppsService { @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.appservice.v2018_02_01.WebApps listPublishingProfileXmlWithSecrets" }) @POST("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/publishxml") @Streaming - Observable> listPublishingProfileXmlWithSecrets(@Path("resourceGroupName") String resourceGroupName, @Path("name") String name, @Path("subscriptionId") String subscriptionId, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Body CsmPublishingProfileOptions publishingProfileOptions, @Header("User-Agent") String userAgent); + Observable> listPublishingProfileXmlWithSecrets(@Path("resourceGroupName") String resourceGroupName, @Path("name") String name, @Path("subscriptionId") String subscriptionId, @Body CsmPublishingProfileOptions publishingProfileOptions, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.appservice.v2018_02_01.WebApps resetProductionSlotConfig" }) @POST("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/resetSlotConfig") @@ -768,6 +775,14 @@ interface WebAppsService { @POST("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/authsettings/list") Observable> getAuthSettingsSlot(@Path("resourceGroupName") String resourceGroupName, @Path("name") String name, @Path("slot") String slot, @Path("subscriptionId") String subscriptionId, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.appservice.v2018_02_01.WebApps updateAzureStorageAccountsSlot" }) + @PUT("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/azurestorageaccounts") + Observable> updateAzureStorageAccountsSlot(@Path("resourceGroupName") String resourceGroupName, @Path("name") String name, @Path("slot") String slot, @Path("subscriptionId") String subscriptionId, @Body AzureStoragePropertyDictionaryResourceInner azureStorageAccounts, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.appservice.v2018_02_01.WebApps listAzureStorageAccountsSlot" }) + @POST("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/azurestorageaccounts/list") + Observable> listAzureStorageAccountsSlot(@Path("resourceGroupName") String resourceGroupName, @Path("name") String name, @Path("slot") String slot, @Path("subscriptionId") String subscriptionId, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.appservice.v2018_02_01.WebApps updateBackupConfigurationSlot" }) @PUT("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/backup") Observable> updateBackupConfigurationSlot(@Path("resourceGroupName") String resourceGroupName, @Path("name") String name, @Path("slot") String slot, @Path("subscriptionId") String subscriptionId, @Body BackupRequestInner request, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); @@ -1215,7 +1230,7 @@ interface WebAppsService { @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.appservice.v2018_02_01.WebApps listPublishingProfileXmlWithSecretsSlot" }) @POST("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/publishxml") @Streaming - Observable> listPublishingProfileXmlWithSecretsSlot(@Path("resourceGroupName") String resourceGroupName, @Path("name") String name, @Path("slot") String slot, @Path("subscriptionId") String subscriptionId, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Body CsmPublishingProfileOptions publishingProfileOptions, @Header("User-Agent") String userAgent); + Observable> listPublishingProfileXmlWithSecretsSlot(@Path("resourceGroupName") String resourceGroupName, @Path("name") String name, @Path("slot") String slot, @Path("subscriptionId") String subscriptionId, @Body CsmPublishingProfileOptions publishingProfileOptions, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.appservice.v2018_02_01.WebApps resetSlotConfigurationSlot" }) @POST("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/resetSlotConfig") @@ -4131,6 +4146,194 @@ private ServiceResponse getAuthSettingsDelegate(Response< .build(response); } + /** + * Updates the Azure storage account configurations of an app. + * Updates the Azure storage account configurations of an app. + * + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the app. + * @param azureStorageAccounts Azure storage accounts of the app. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws DefaultErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the AzureStoragePropertyDictionaryResourceInner object if successful. + */ + public AzureStoragePropertyDictionaryResourceInner updateAzureStorageAccounts(String resourceGroupName, String name, AzureStoragePropertyDictionaryResourceInner azureStorageAccounts) { + return updateAzureStorageAccountsWithServiceResponseAsync(resourceGroupName, name, azureStorageAccounts).toBlocking().single().body(); + } + + /** + * Updates the Azure storage account configurations of an app. + * Updates the Azure storage account configurations of an app. + * + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the app. + * @param azureStorageAccounts Azure storage accounts of the app. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture updateAzureStorageAccountsAsync(String resourceGroupName, String name, AzureStoragePropertyDictionaryResourceInner azureStorageAccounts, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(updateAzureStorageAccountsWithServiceResponseAsync(resourceGroupName, name, azureStorageAccounts), serviceCallback); + } + + /** + * Updates the Azure storage account configurations of an app. + * Updates the Azure storage account configurations of an app. + * + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the app. + * @param azureStorageAccounts Azure storage accounts of the app. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the AzureStoragePropertyDictionaryResourceInner object + */ + public Observable updateAzureStorageAccountsAsync(String resourceGroupName, String name, AzureStoragePropertyDictionaryResourceInner azureStorageAccounts) { + return updateAzureStorageAccountsWithServiceResponseAsync(resourceGroupName, name, azureStorageAccounts).map(new Func1, AzureStoragePropertyDictionaryResourceInner>() { + @Override + public AzureStoragePropertyDictionaryResourceInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Updates the Azure storage account configurations of an app. + * Updates the Azure storage account configurations of an app. + * + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the app. + * @param azureStorageAccounts Azure storage accounts of the app. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the AzureStoragePropertyDictionaryResourceInner object + */ + public Observable> updateAzureStorageAccountsWithServiceResponseAsync(String resourceGroupName, String name, AzureStoragePropertyDictionaryResourceInner azureStorageAccounts) { + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (name == null) { + throw new IllegalArgumentException("Parameter name is required and cannot be null."); + } + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (azureStorageAccounts == null) { + throw new IllegalArgumentException("Parameter azureStorageAccounts is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + Validator.validate(azureStorageAccounts); + return service.updateAzureStorageAccounts(resourceGroupName, name, this.client.subscriptionId(), azureStorageAccounts, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = updateAzureStorageAccountsDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse updateAzureStorageAccountsDelegate(Response response) throws DefaultErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(DefaultErrorResponseException.class) + .build(response); + } + + /** + * Gets the Azure storage account configurations of an app. + * Gets the Azure storage account configurations of an app. + * + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the app. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws DefaultErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the AzureStoragePropertyDictionaryResourceInner object if successful. + */ + public AzureStoragePropertyDictionaryResourceInner listAzureStorageAccounts(String resourceGroupName, String name) { + return listAzureStorageAccountsWithServiceResponseAsync(resourceGroupName, name).toBlocking().single().body(); + } + + /** + * Gets the Azure storage account configurations of an app. + * Gets the Azure storage account configurations of an app. + * + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the app. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture listAzureStorageAccountsAsync(String resourceGroupName, String name, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(listAzureStorageAccountsWithServiceResponseAsync(resourceGroupName, name), serviceCallback); + } + + /** + * Gets the Azure storage account configurations of an app. + * Gets the Azure storage account configurations of an app. + * + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the app. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the AzureStoragePropertyDictionaryResourceInner object + */ + public Observable listAzureStorageAccountsAsync(String resourceGroupName, String name) { + return listAzureStorageAccountsWithServiceResponseAsync(resourceGroupName, name).map(new Func1, AzureStoragePropertyDictionaryResourceInner>() { + @Override + public AzureStoragePropertyDictionaryResourceInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Gets the Azure storage account configurations of an app. + * Gets the Azure storage account configurations of an app. + * + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the app. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the AzureStoragePropertyDictionaryResourceInner object + */ + public Observable> listAzureStorageAccountsWithServiceResponseAsync(String resourceGroupName, String name) { + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (name == null) { + throw new IllegalArgumentException("Parameter name is required and cannot be null."); + } + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.listAzureStorageAccounts(resourceGroupName, name, this.client.subscriptionId(), this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = listAzureStorageAccountsDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse listAzureStorageAccountsDelegate(Response response) throws DefaultErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(DefaultErrorResponseException.class) + .build(response); + } + /** * Updates the backup configuration of an app. * Updates the backup configuration of an app. @@ -16319,13 +16522,14 @@ private ServiceResponse deletePublicCertificateDelegate(Response listPublishingProfileXmlWithSecretsAsync(String resourceGroupName, String name, final ServiceCallback serviceCallback) { - return ServiceFuture.fromResponse(listPublishingProfileXmlWithSecretsWithServiceResponseAsync(resourceGroupName, name), serviceCallback); + public ServiceFuture listPublishingProfileXmlWithSecretsAsync(String resourceGroupName, String name, CsmPublishingProfileOptions publishingProfileOptions, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(listPublishingProfileXmlWithSecretsWithServiceResponseAsync(resourceGroupName, name, publishingProfileOptions), serviceCallback); } /** @@ -16348,11 +16553,12 @@ public ServiceFuture listPublishingProfileXmlWithSecretsAsync(Strin * * @param resourceGroupName Name of the resource group to which the resource belongs. * @param name Name of the app. + * @param publishingProfileOptions Specifies publishingProfileOptions for publishing profile. For example, use {"format": "FileZilla3"} to get a FileZilla publishing profile. * @throws IllegalArgumentException thrown if parameters fail the validation * @return the observable to the InputStream object */ - public Observable listPublishingProfileXmlWithSecretsAsync(String resourceGroupName, String name) { - return listPublishingProfileXmlWithSecretsWithServiceResponseAsync(resourceGroupName, name).map(new Func1, InputStream>() { + public Observable listPublishingProfileXmlWithSecretsAsync(String resourceGroupName, String name, CsmPublishingProfileOptions publishingProfileOptions) { + return listPublishingProfileXmlWithSecretsWithServiceResponseAsync(resourceGroupName, name, publishingProfileOptions).map(new Func1, InputStream>() { @Override public InputStream call(ServiceResponse response) { return response.body(); @@ -16366,10 +16572,11 @@ public InputStream call(ServiceResponse response) { * * @param resourceGroupName Name of the resource group to which the resource belongs. * @param name Name of the app. + * @param publishingProfileOptions Specifies publishingProfileOptions for publishing profile. For example, use {"format": "FileZilla3"} to get a FileZilla publishing profile. * @throws IllegalArgumentException thrown if parameters fail the validation * @return the observable to the InputStream object */ - public Observable> listPublishingProfileXmlWithSecretsWithServiceResponseAsync(String resourceGroupName, String name) { + public Observable> listPublishingProfileXmlWithSecretsWithServiceResponseAsync(String resourceGroupName, String name, CsmPublishingProfileOptions publishingProfileOptions) { if (resourceGroupName == null) { throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); } @@ -16379,114 +16586,14 @@ public Observable> listPublishingProfileXmlWithSecr if (this.client.subscriptionId() == null) { throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); } - if (this.client.apiVersion() == null) { - throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); - } - final PublishingProfileFormat format = null; - CsmPublishingProfileOptions publishingProfileOptions = new CsmPublishingProfileOptions(); - publishingProfileOptions.withFormat(null); - return service.listPublishingProfileXmlWithSecrets(resourceGroupName, name, this.client.subscriptionId(), this.client.apiVersion(), this.client.acceptLanguage(), publishingProfileOptions, this.client.userAgent()) - .flatMap(new Func1, Observable>>() { - @Override - public Observable> call(Response response) { - try { - ServiceResponse clientResponse = listPublishingProfileXmlWithSecretsDelegate(response); - return Observable.just(clientResponse); - } catch (Throwable t) { - return Observable.error(t); - } - } - }); - } - - /** - * Gets the publishing profile for an app (or deployment slot, if specified). - * Gets the publishing profile for an app (or deployment slot, if specified). - * - * @param resourceGroupName Name of the resource group to which the resource belongs. - * @param name Name of the app. - * @param format Name of the format. Valid values are: - FileZilla3 - WebDeploy -- default - Ftp. Possible values include: 'FileZilla3', 'WebDeploy', 'Ftp' - * @throws IllegalArgumentException thrown if parameters fail the validation - * @throws DefaultErrorResponseException thrown if the request is rejected by server - * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent - * @return the InputStream object if successful. - */ - public InputStream listPublishingProfileXmlWithSecrets(String resourceGroupName, String name, PublishingProfileFormat format) { - return listPublishingProfileXmlWithSecretsWithServiceResponseAsync(resourceGroupName, name, format).toBlocking().single().body(); - } - - /** - * Gets the publishing profile for an app (or deployment slot, if specified). - * Gets the publishing profile for an app (or deployment slot, if specified). - * - * @param resourceGroupName Name of the resource group to which the resource belongs. - * @param name Name of the app. - * @param format Name of the format. Valid values are: - FileZilla3 - WebDeploy -- default - Ftp. Possible values include: 'FileZilla3', 'WebDeploy', 'Ftp' - * @param serviceCallback the async ServiceCallback to handle successful and failed responses. - * @throws IllegalArgumentException thrown if parameters fail the validation - * @return the {@link ServiceFuture} object - */ - public ServiceFuture listPublishingProfileXmlWithSecretsAsync(String resourceGroupName, String name, PublishingProfileFormat format, final ServiceCallback serviceCallback) { - return ServiceFuture.fromResponse(listPublishingProfileXmlWithSecretsWithServiceResponseAsync(resourceGroupName, name, format), serviceCallback); - } - - /** - * Gets the publishing profile for an app (or deployment slot, if specified). - * Gets the publishing profile for an app (or deployment slot, if specified). - * - * @param resourceGroupName Name of the resource group to which the resource belongs. - * @param name Name of the app. - * @param format Name of the format. Valid values are: - FileZilla3 - WebDeploy -- default - Ftp. Possible values include: 'FileZilla3', 'WebDeploy', 'Ftp' - * @throws IllegalArgumentException thrown if parameters fail the validation - * @return the observable to the InputStream object - */ - public Observable listPublishingProfileXmlWithSecretsAsync(String resourceGroupName, String name, PublishingProfileFormat format) { - return listPublishingProfileXmlWithSecretsWithServiceResponseAsync(resourceGroupName, name, format).map(new Func1, InputStream>() { - @Override - public InputStream call(ServiceResponse response) { - return response.body(); - } - }); - } - - /** - * Gets the publishing profile for an app (or deployment slot, if specified). - * Gets the publishing profile for an app (or deployment slot, if specified). - * - * @param resourceGroupName Name of the resource group to which the resource belongs. - * @param name Name of the app. - * @param format Name of the format. Valid values are: - FileZilla3 - WebDeploy -- default - Ftp. Possible values include: 'FileZilla3', 'WebDeploy', 'Ftp' - * @throws IllegalArgumentException thrown if parameters fail the validation - * @return the observable to the InputStream object - */ - public Observable> listPublishingProfileXmlWithSecretsWithServiceResponseAsync(String resourceGroupName, String name, PublishingProfileFormat format) { - if (resourceGroupName == null) { - throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); - } - if (name == null) { - throw new IllegalArgumentException("Parameter name is required and cannot be null."); - } - if (this.client.subscriptionId() == null) { - throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + if (publishingProfileOptions == null) { + throw new IllegalArgumentException("Parameter publishingProfileOptions is required and cannot be null."); } if (this.client.apiVersion() == null) { throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); } - CsmPublishingProfileOptions publishingProfileOptions = new CsmPublishingProfileOptions(); - publishingProfileOptions.withFormat(format); - return service.listPublishingProfileXmlWithSecrets(resourceGroupName, name, this.client.subscriptionId(), this.client.apiVersion(), this.client.acceptLanguage(), publishingProfileOptions, this.client.userAgent()) + Validator.validate(publishingProfileOptions); + return service.listPublishingProfileXmlWithSecrets(resourceGroupName, name, this.client.subscriptionId(), publishingProfileOptions, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) .flatMap(new Func1, Observable>>() { @Override public Observable> call(Response response) { @@ -20140,6 +20247,208 @@ private ServiceResponse getAuthSettingsSlotDelegate(Respo .build(response); } + /** + * Updates the Azure storage account configurations of an app. + * Updates the Azure storage account configurations of an app. + * + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the app. + * @param slot Name of the deployment slot. If a slot is not specified, the API will update the Azure storage account configurations for the production slot. + * @param azureStorageAccounts Azure storage accounts of the app. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws DefaultErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the AzureStoragePropertyDictionaryResourceInner object if successful. + */ + public AzureStoragePropertyDictionaryResourceInner updateAzureStorageAccountsSlot(String resourceGroupName, String name, String slot, AzureStoragePropertyDictionaryResourceInner azureStorageAccounts) { + return updateAzureStorageAccountsSlotWithServiceResponseAsync(resourceGroupName, name, slot, azureStorageAccounts).toBlocking().single().body(); + } + + /** + * Updates the Azure storage account configurations of an app. + * Updates the Azure storage account configurations of an app. + * + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the app. + * @param slot Name of the deployment slot. If a slot is not specified, the API will update the Azure storage account configurations for the production slot. + * @param azureStorageAccounts Azure storage accounts of the app. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture updateAzureStorageAccountsSlotAsync(String resourceGroupName, String name, String slot, AzureStoragePropertyDictionaryResourceInner azureStorageAccounts, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(updateAzureStorageAccountsSlotWithServiceResponseAsync(resourceGroupName, name, slot, azureStorageAccounts), serviceCallback); + } + + /** + * Updates the Azure storage account configurations of an app. + * Updates the Azure storage account configurations of an app. + * + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the app. + * @param slot Name of the deployment slot. If a slot is not specified, the API will update the Azure storage account configurations for the production slot. + * @param azureStorageAccounts Azure storage accounts of the app. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the AzureStoragePropertyDictionaryResourceInner object + */ + public Observable updateAzureStorageAccountsSlotAsync(String resourceGroupName, String name, String slot, AzureStoragePropertyDictionaryResourceInner azureStorageAccounts) { + return updateAzureStorageAccountsSlotWithServiceResponseAsync(resourceGroupName, name, slot, azureStorageAccounts).map(new Func1, AzureStoragePropertyDictionaryResourceInner>() { + @Override + public AzureStoragePropertyDictionaryResourceInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Updates the Azure storage account configurations of an app. + * Updates the Azure storage account configurations of an app. + * + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the app. + * @param slot Name of the deployment slot. If a slot is not specified, the API will update the Azure storage account configurations for the production slot. + * @param azureStorageAccounts Azure storage accounts of the app. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the AzureStoragePropertyDictionaryResourceInner object + */ + public Observable> updateAzureStorageAccountsSlotWithServiceResponseAsync(String resourceGroupName, String name, String slot, AzureStoragePropertyDictionaryResourceInner azureStorageAccounts) { + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (name == null) { + throw new IllegalArgumentException("Parameter name is required and cannot be null."); + } + if (slot == null) { + throw new IllegalArgumentException("Parameter slot is required and cannot be null."); + } + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (azureStorageAccounts == null) { + throw new IllegalArgumentException("Parameter azureStorageAccounts is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + Validator.validate(azureStorageAccounts); + return service.updateAzureStorageAccountsSlot(resourceGroupName, name, slot, this.client.subscriptionId(), azureStorageAccounts, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = updateAzureStorageAccountsSlotDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse updateAzureStorageAccountsSlotDelegate(Response response) throws DefaultErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(DefaultErrorResponseException.class) + .build(response); + } + + /** + * Gets the Azure storage account configurations of an app. + * Gets the Azure storage account configurations of an app. + * + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the app. + * @param slot Name of the deployment slot. If a slot is not specified, the API will update the Azure storage account configurations for the production slot. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws DefaultErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the AzureStoragePropertyDictionaryResourceInner object if successful. + */ + public AzureStoragePropertyDictionaryResourceInner listAzureStorageAccountsSlot(String resourceGroupName, String name, String slot) { + return listAzureStorageAccountsSlotWithServiceResponseAsync(resourceGroupName, name, slot).toBlocking().single().body(); + } + + /** + * Gets the Azure storage account configurations of an app. + * Gets the Azure storage account configurations of an app. + * + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the app. + * @param slot Name of the deployment slot. If a slot is not specified, the API will update the Azure storage account configurations for the production slot. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture listAzureStorageAccountsSlotAsync(String resourceGroupName, String name, String slot, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(listAzureStorageAccountsSlotWithServiceResponseAsync(resourceGroupName, name, slot), serviceCallback); + } + + /** + * Gets the Azure storage account configurations of an app. + * Gets the Azure storage account configurations of an app. + * + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the app. + * @param slot Name of the deployment slot. If a slot is not specified, the API will update the Azure storage account configurations for the production slot. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the AzureStoragePropertyDictionaryResourceInner object + */ + public Observable listAzureStorageAccountsSlotAsync(String resourceGroupName, String name, String slot) { + return listAzureStorageAccountsSlotWithServiceResponseAsync(resourceGroupName, name, slot).map(new Func1, AzureStoragePropertyDictionaryResourceInner>() { + @Override + public AzureStoragePropertyDictionaryResourceInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Gets the Azure storage account configurations of an app. + * Gets the Azure storage account configurations of an app. + * + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the app. + * @param slot Name of the deployment slot. If a slot is not specified, the API will update the Azure storage account configurations for the production slot. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the AzureStoragePropertyDictionaryResourceInner object + */ + public Observable> listAzureStorageAccountsSlotWithServiceResponseAsync(String resourceGroupName, String name, String slot) { + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (name == null) { + throw new IllegalArgumentException("Parameter name is required and cannot be null."); + } + if (slot == null) { + throw new IllegalArgumentException("Parameter slot is required and cannot be null."); + } + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.listAzureStorageAccountsSlot(resourceGroupName, name, slot, this.client.subscriptionId(), this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = listAzureStorageAccountsSlotDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse listAzureStorageAccountsSlotDelegate(Response response) throws DefaultErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(DefaultErrorResponseException.class) + .build(response); + } + /** * Updates the backup configuration of an app. * Updates the backup configuration of an app. @@ -32579,13 +32888,14 @@ private ServiceResponse deletePublicCertificateSlotDelegate(Response listPublishingProfileXmlWithSecretsSlotAsync(String resourceGroupName, String name, String slot, final ServiceCallback serviceCallback) { - return ServiceFuture.fromResponse(listPublishingProfileXmlWithSecretsSlotWithServiceResponseAsync(resourceGroupName, name, slot), serviceCallback); + public ServiceFuture listPublishingProfileXmlWithSecretsSlotAsync(String resourceGroupName, String name, String slot, CsmPublishingProfileOptions publishingProfileOptions, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(listPublishingProfileXmlWithSecretsSlotWithServiceResponseAsync(resourceGroupName, name, slot, publishingProfileOptions), serviceCallback); } /** @@ -32610,11 +32921,12 @@ public ServiceFuture listPublishingProfileXmlWithSecretsSlotAsync(S * @param resourceGroupName Name of the resource group to which the resource belongs. * @param name Name of the app. * @param slot Name of the deployment slot. If a slot is not specified, the API will get the publishing profile for the production slot. + * @param publishingProfileOptions Specifies publishingProfileOptions for publishing profile. For example, use {"format": "FileZilla3"} to get a FileZilla publishing profile. * @throws IllegalArgumentException thrown if parameters fail the validation * @return the observable to the InputStream object */ - public Observable listPublishingProfileXmlWithSecretsSlotAsync(String resourceGroupName, String name, String slot) { - return listPublishingProfileXmlWithSecretsSlotWithServiceResponseAsync(resourceGroupName, name, slot).map(new Func1, InputStream>() { + public Observable listPublishingProfileXmlWithSecretsSlotAsync(String resourceGroupName, String name, String slot, CsmPublishingProfileOptions publishingProfileOptions) { + return listPublishingProfileXmlWithSecretsSlotWithServiceResponseAsync(resourceGroupName, name, slot, publishingProfileOptions).map(new Func1, InputStream>() { @Override public InputStream call(ServiceResponse response) { return response.body(); @@ -32629,10 +32941,11 @@ public InputStream call(ServiceResponse response) { * @param resourceGroupName Name of the resource group to which the resource belongs. * @param name Name of the app. * @param slot Name of the deployment slot. If a slot is not specified, the API will get the publishing profile for the production slot. + * @param publishingProfileOptions Specifies publishingProfileOptions for publishing profile. For example, use {"format": "FileZilla3"} to get a FileZilla publishing profile. * @throws IllegalArgumentException thrown if parameters fail the validation * @return the observable to the InputStream object */ - public Observable> listPublishingProfileXmlWithSecretsSlotWithServiceResponseAsync(String resourceGroupName, String name, String slot) { + public Observable> listPublishingProfileXmlWithSecretsSlotWithServiceResponseAsync(String resourceGroupName, String name, String slot, CsmPublishingProfileOptions publishingProfileOptions) { if (resourceGroupName == null) { throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); } @@ -32645,121 +32958,14 @@ public Observable> listPublishingProfileXmlWithSecr if (this.client.subscriptionId() == null) { throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); } - if (this.client.apiVersion() == null) { - throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); - } - final PublishingProfileFormat format = null; - CsmPublishingProfileOptions publishingProfileOptions = new CsmPublishingProfileOptions(); - publishingProfileOptions.withFormat(null); - return service.listPublishingProfileXmlWithSecretsSlot(resourceGroupName, name, slot, this.client.subscriptionId(), this.client.apiVersion(), this.client.acceptLanguage(), publishingProfileOptions, this.client.userAgent()) - .flatMap(new Func1, Observable>>() { - @Override - public Observable> call(Response response) { - try { - ServiceResponse clientResponse = listPublishingProfileXmlWithSecretsSlotDelegate(response); - return Observable.just(clientResponse); - } catch (Throwable t) { - return Observable.error(t); - } - } - }); - } - - /** - * Gets the publishing profile for an app (or deployment slot, if specified). - * Gets the publishing profile for an app (or deployment slot, if specified). - * - * @param resourceGroupName Name of the resource group to which the resource belongs. - * @param name Name of the app. - * @param slot Name of the deployment slot. If a slot is not specified, the API will get the publishing profile for the production slot. - * @param format Name of the format. Valid values are: - FileZilla3 - WebDeploy -- default - Ftp. Possible values include: 'FileZilla3', 'WebDeploy', 'Ftp' - * @throws IllegalArgumentException thrown if parameters fail the validation - * @throws DefaultErrorResponseException thrown if the request is rejected by server - * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent - * @return the InputStream object if successful. - */ - public InputStream listPublishingProfileXmlWithSecretsSlot(String resourceGroupName, String name, String slot, PublishingProfileFormat format) { - return listPublishingProfileXmlWithSecretsSlotWithServiceResponseAsync(resourceGroupName, name, slot, format).toBlocking().single().body(); - } - - /** - * Gets the publishing profile for an app (or deployment slot, if specified). - * Gets the publishing profile for an app (or deployment slot, if specified). - * - * @param resourceGroupName Name of the resource group to which the resource belongs. - * @param name Name of the app. - * @param slot Name of the deployment slot. If a slot is not specified, the API will get the publishing profile for the production slot. - * @param format Name of the format. Valid values are: - FileZilla3 - WebDeploy -- default - Ftp. Possible values include: 'FileZilla3', 'WebDeploy', 'Ftp' - * @param serviceCallback the async ServiceCallback to handle successful and failed responses. - * @throws IllegalArgumentException thrown if parameters fail the validation - * @return the {@link ServiceFuture} object - */ - public ServiceFuture listPublishingProfileXmlWithSecretsSlotAsync(String resourceGroupName, String name, String slot, PublishingProfileFormat format, final ServiceCallback serviceCallback) { - return ServiceFuture.fromResponse(listPublishingProfileXmlWithSecretsSlotWithServiceResponseAsync(resourceGroupName, name, slot, format), serviceCallback); - } - - /** - * Gets the publishing profile for an app (or deployment slot, if specified). - * Gets the publishing profile for an app (or deployment slot, if specified). - * - * @param resourceGroupName Name of the resource group to which the resource belongs. - * @param name Name of the app. - * @param slot Name of the deployment slot. If a slot is not specified, the API will get the publishing profile for the production slot. - * @param format Name of the format. Valid values are: - FileZilla3 - WebDeploy -- default - Ftp. Possible values include: 'FileZilla3', 'WebDeploy', 'Ftp' - * @throws IllegalArgumentException thrown if parameters fail the validation - * @return the observable to the InputStream object - */ - public Observable listPublishingProfileXmlWithSecretsSlotAsync(String resourceGroupName, String name, String slot, PublishingProfileFormat format) { - return listPublishingProfileXmlWithSecretsSlotWithServiceResponseAsync(resourceGroupName, name, slot, format).map(new Func1, InputStream>() { - @Override - public InputStream call(ServiceResponse response) { - return response.body(); - } - }); - } - - /** - * Gets the publishing profile for an app (or deployment slot, if specified). - * Gets the publishing profile for an app (or deployment slot, if specified). - * - * @param resourceGroupName Name of the resource group to which the resource belongs. - * @param name Name of the app. - * @param slot Name of the deployment slot. If a slot is not specified, the API will get the publishing profile for the production slot. - * @param format Name of the format. Valid values are: - FileZilla3 - WebDeploy -- default - Ftp. Possible values include: 'FileZilla3', 'WebDeploy', 'Ftp' - * @throws IllegalArgumentException thrown if parameters fail the validation - * @return the observable to the InputStream object - */ - public Observable> listPublishingProfileXmlWithSecretsSlotWithServiceResponseAsync(String resourceGroupName, String name, String slot, PublishingProfileFormat format) { - if (resourceGroupName == null) { - throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); - } - if (name == null) { - throw new IllegalArgumentException("Parameter name is required and cannot be null."); - } - if (slot == null) { - throw new IllegalArgumentException("Parameter slot is required and cannot be null."); - } - if (this.client.subscriptionId() == null) { - throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + if (publishingProfileOptions == null) { + throw new IllegalArgumentException("Parameter publishingProfileOptions is required and cannot be null."); } if (this.client.apiVersion() == null) { throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); } - CsmPublishingProfileOptions publishingProfileOptions = new CsmPublishingProfileOptions(); - publishingProfileOptions.withFormat(format); - return service.listPublishingProfileXmlWithSecretsSlot(resourceGroupName, name, slot, this.client.subscriptionId(), this.client.apiVersion(), this.client.acceptLanguage(), publishingProfileOptions, this.client.userAgent()) + Validator.validate(publishingProfileOptions); + return service.listPublishingProfileXmlWithSecretsSlot(resourceGroupName, name, slot, this.client.subscriptionId(), publishingProfileOptions, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) .flatMap(new Func1, Observable>>() { @Override public Observable> call(Response response) {