Skip to content

Commit

Permalink
Storage: update 2019 04 01 (#5568)
Browse files Browse the repository at this point in the history
* Storage: update 2019 04 01

* Storage: update pom
  • Loading branch information
ChenTanyi authored Sep 27, 2019
1 parent 1c42f15 commit 1277779
Show file tree
Hide file tree
Showing 9 changed files with 349 additions and 37 deletions.
2 changes: 1 addition & 1 deletion storage/resource-manager/v2019_04_01/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
<relativePath>../../../pom.management.xml</relativePath>
</parent>
<artifactId>azure-mgmt-storage</artifactId>
<version>1.0.0-beta-1</version>
<version>1.0.0-beta-2</version>
<packaging>jar</packaging>
<name>Microsoft Azure SDK for Storage Management</name>
<description>This package contains Microsoft Storage Management SDK.</description>
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
/**
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for
* license information.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
*/

package com.microsoft.azure.management.storage.v2019_04_01;

import java.util.Collection;
import com.fasterxml.jackson.annotation.JsonCreator;
import com.microsoft.rest.ExpandableStringEnum;

/**
* Defines values for LargeFileSharesState.
*/
public final class LargeFileSharesState extends ExpandableStringEnum<LargeFileSharesState> {
/** Static value Disabled for LargeFileSharesState. */
public static final LargeFileSharesState DISABLED = fromString("Disabled");

/** Static value Enabled for LargeFileSharesState. */
public static final LargeFileSharesState ENABLED = fromString("Enabled");

/**
* Creates or finds a LargeFileSharesState from its string representation.
* @param name a name to look for
* @return the corresponding LargeFileSharesState
*/
@JsonCreator
public static LargeFileSharesState fromString(String name) {
return fromString(name, LargeFileSharesState.class);
}

/**
* @return known LargeFileSharesState values
*/
public static Collection<LargeFileSharesState> values() {
return values(LargeFileSharesState.class);
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,11 @@ public interface StorageAccount extends HasInner<StorageAccountInner>, Resource,
*/
Kind kind();

/**
* @return the largeFileSharesState value.
*/
LargeFileSharesState largeFileSharesState();

/**
* @return the lastGeoFailoverTime value.
*/
Expand Down Expand Up @@ -261,6 +266,18 @@ interface WithIsHnsEnabled {
WithCreate withIsHnsEnabled(Boolean isHnsEnabled);
}

/**
* The stage of the storageaccount definition allowing to specify LargeFileSharesState.
*/
interface WithLargeFileSharesState {
/**
* Specifies largeFileSharesState.
* @param largeFileSharesState Allow large file shares if sets to Enabled. It cannot be disabled once it is enabled. Possible values include: 'Disabled', 'Enabled'
* @return the next definition stage
*/
WithCreate withLargeFileSharesState(LargeFileSharesState largeFileSharesState);
}

/**
* The stage of the storageaccount definition allowing to specify NetworkRuleSet.
*/
Expand All @@ -278,13 +295,13 @@ interface WithNetworkRuleSet {
* the resource to be created (via {@link WithCreate#create()}), but also allows
* for any other optional settings to be specified.
*/
interface WithCreate extends Creatable<StorageAccount>, Resource.DefinitionWithTags<WithCreate>, DefinitionStages.WithAccessTier, DefinitionStages.WithAzureFilesIdentityBasedAuthentication, DefinitionStages.WithCustomDomain, DefinitionStages.WithEnableHttpsTrafficOnly, DefinitionStages.WithEncryption, DefinitionStages.WithIdentity, DefinitionStages.WithIsHnsEnabled, DefinitionStages.WithNetworkRuleSet {
interface WithCreate extends Creatable<StorageAccount>, Resource.DefinitionWithTags<WithCreate>, DefinitionStages.WithAccessTier, DefinitionStages.WithAzureFilesIdentityBasedAuthentication, DefinitionStages.WithCustomDomain, DefinitionStages.WithEnableHttpsTrafficOnly, DefinitionStages.WithEncryption, DefinitionStages.WithIdentity, DefinitionStages.WithIsHnsEnabled, DefinitionStages.WithLargeFileSharesState, DefinitionStages.WithNetworkRuleSet {
}
}
/**
* The template for a StorageAccount update operation, containing all the settings that can be modified.
*/
interface Update extends Appliable<StorageAccount>, Resource.UpdateWithTags<Update>, UpdateStages.WithAccessTier, UpdateStages.WithAzureFilesIdentityBasedAuthentication, UpdateStages.WithCustomDomain, UpdateStages.WithEnableHttpsTrafficOnly, UpdateStages.WithEncryption, UpdateStages.WithIdentity, UpdateStages.WithKind, UpdateStages.WithNetworkRuleSet, UpdateStages.WithSku {
interface Update extends Appliable<StorageAccount>, Resource.UpdateWithTags<Update>, UpdateStages.WithAccessTier, UpdateStages.WithAzureFilesIdentityBasedAuthentication, UpdateStages.WithCustomDomain, UpdateStages.WithEnableHttpsTrafficOnly, UpdateStages.WithEncryption, UpdateStages.WithIdentity, UpdateStages.WithKind, UpdateStages.WithLargeFileSharesState, UpdateStages.WithNetworkRuleSet, UpdateStages.WithSku {
}

/**
Expand Down Expand Up @@ -375,6 +392,18 @@ interface WithKind {
Update withKind(Kind kind);
}

/**
* The stage of the storageaccount update allowing to specify LargeFileSharesState.
*/
interface WithLargeFileSharesState {
/**
* Specifies largeFileSharesState.
* @param largeFileSharesState Allow large file shares if sets to Enabled. It cannot be disabled once it is enabled. Possible values include: 'Disabled', 'Enabled'
* @return the next update stage
*/
Update withLargeFileSharesState(LargeFileSharesState largeFileSharesState);
}

/**
* The stage of the storageaccount update allowing to specify NetworkRuleSet.
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -106,6 +106,13 @@ public class StorageAccountCreateParameters {
@JsonProperty(value = "properties.isHnsEnabled")
private Boolean isHnsEnabled;

/**
* Allow large file shares if sets to Enabled. It cannot be disabled once
* it is enabled. Possible values include: 'Disabled', 'Enabled'.
*/
@JsonProperty(value = "properties.largeFileSharesState")
private LargeFileSharesState largeFileSharesState;

/**
* Get required. Gets or sets the SKU name.
*
Expand Down Expand Up @@ -346,4 +353,24 @@ public StorageAccountCreateParameters withIsHnsEnabled(Boolean isHnsEnabled) {
return this;
}

/**
* Get allow large file shares if sets to Enabled. It cannot be disabled once it is enabled. Possible values include: 'Disabled', 'Enabled'.
*
* @return the largeFileSharesState value
*/
public LargeFileSharesState largeFileSharesState() {
return this.largeFileSharesState;
}

/**
* Set allow large file shares if sets to Enabled. It cannot be disabled once it is enabled. Possible values include: 'Disabled', 'Enabled'.
*
* @param largeFileSharesState the largeFileSharesState value to set
* @return the StorageAccountCreateParameters object itself.
*/
public StorageAccountCreateParameters withLargeFileSharesState(LargeFileSharesState largeFileSharesState) {
this.largeFileSharesState = largeFileSharesState;
return this;
}

}
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,13 @@ public class StorageAccountUpdateParameters {
@JsonProperty(value = "properties.networkAcls")
private NetworkRuleSet networkRuleSet;

/**
* Allow large file shares if sets to Enabled. It cannot be disabled once
* it is enabled. Possible values include: 'Disabled', 'Enabled'.
*/
@JsonProperty(value = "properties.largeFileSharesState")
private LargeFileSharesState largeFileSharesState;

/**
* Optional. Indicates the type of storage account. Currently only
* StorageV2 value supported by server. Possible values include: 'Storage',
Expand Down Expand Up @@ -272,6 +279,26 @@ public StorageAccountUpdateParameters withNetworkRuleSet(NetworkRuleSet networkR
return this;
}

/**
* Get allow large file shares if sets to Enabled. It cannot be disabled once it is enabled. Possible values include: 'Disabled', 'Enabled'.
*
* @return the largeFileSharesState value
*/
public LargeFileSharesState largeFileSharesState() {
return this.largeFileSharesState;
}

/**
* Set allow large file shares if sets to Enabled. It cannot be disabled once it is enabled. Possible values include: 'Disabled', 'Enabled'.
*
* @param largeFileSharesState the largeFileSharesState value to set
* @return the StorageAccountUpdateParameters object itself.
*/
public StorageAccountUpdateParameters withLargeFileSharesState(LargeFileSharesState largeFileSharesState) {
this.largeFileSharesState = largeFileSharesState;
return this;
}

/**
* Get optional. Indicates the type of storage account. Currently only StorageV2 value supported by server. Possible values include: 'Storage', 'StorageV2', 'BlobStorage', 'FileStorage', 'BlockBlobStorage'.
*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
import com.microsoft.azure.management.storage.v2019_04_01.GeoReplicationStats;
import com.microsoft.azure.management.storage.v2019_04_01.Identity;
import com.microsoft.azure.management.storage.v2019_04_01.Kind;
import com.microsoft.azure.management.storage.v2019_04_01.LargeFileSharesState;
import com.microsoft.azure.management.storage.v2019_04_01.NetworkRuleSet;
import com.microsoft.azure.management.storage.v2019_04_01.Endpoints;
import com.microsoft.azure.management.storage.v2019_04_01.ProvisioningState;
Expand Down Expand Up @@ -138,6 +139,11 @@ public Kind kind() {
return this.inner().kind();
}

@Override
public LargeFileSharesState largeFileSharesState() {
return this.inner().largeFileSharesState();
}

@Override
public DateTime lastGeoFailoverTime() {
return this.inner().lastGeoFailoverTime();
Expand Down Expand Up @@ -279,6 +285,16 @@ public StorageAccountImpl withIdentity(Identity identity) {
return this;
}

@Override
public StorageAccountImpl withLargeFileSharesState(LargeFileSharesState largeFileSharesState) {
if (isInCreateMode()) {
this.createParameter.withLargeFileSharesState(largeFileSharesState);
} else {
this.updateParameter.withLargeFileSharesState(largeFileSharesState);
}
return this;
}

@Override
public StorageAccountImpl withNetworkRuleSet(NetworkRuleSet networkRuleSet) {
if (isInCreateMode()) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
import com.microsoft.azure.management.storage.v2019_04_01.AzureFilesIdentityBasedAuthentication;
import com.microsoft.azure.management.storage.v2019_04_01.NetworkRuleSet;
import com.microsoft.azure.management.storage.v2019_04_01.GeoReplicationStats;
import com.microsoft.azure.management.storage.v2019_04_01.LargeFileSharesState;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.microsoft.rest.serializer.JsonFlatten;
import com.microsoft.azure.Resource;
Expand Down Expand Up @@ -175,6 +176,13 @@ public class StorageAccountInner extends Resource {
@JsonProperty(value = "properties.failoverInProgress", access = JsonProperty.Access.WRITE_ONLY)
private Boolean failoverInProgress;

/**
* Allow large file shares if sets to Enabled. It cannot be disabled once
* it is enabled. Possible values include: 'Disabled', 'Enabled'.
*/
@JsonProperty(value = "properties.largeFileSharesState")
private LargeFileSharesState largeFileSharesState;

/**
* Get gets the SKU.
*
Expand Down Expand Up @@ -408,4 +416,24 @@ public Boolean failoverInProgress() {
return this.failoverInProgress;
}

/**
* Get allow large file shares if sets to Enabled. It cannot be disabled once it is enabled. Possible values include: 'Disabled', 'Enabled'.
*
* @return the largeFileSharesState value
*/
public LargeFileSharesState largeFileSharesState() {
return this.largeFileSharesState;
}

/**
* Set allow large file shares if sets to Enabled. It cannot be disabled once it is enabled. Possible values include: 'Disabled', 'Enabled'.
*
* @param largeFileSharesState the largeFileSharesState value to set
* @return the StorageAccountInner object itself.
*/
public StorageAccountInner withLargeFileSharesState(LargeFileSharesState largeFileSharesState) {
this.largeFileSharesState = largeFileSharesState;
return this;
}

}
Original file line number Diff line number Diff line change
Expand Up @@ -112,10 +112,10 @@ public PagedList<StorageAccount> list() {
public Observable<StorageAccount> listAsync() {
StorageAccountsInner client = this.inner();
return client.listAsync()
.flatMap(new Func1<Page<StorageAccountInner>, Observable<StorageAccountInner>>() {
.flatMapIterable(new Func1<Page<StorageAccountInner>, Iterable<StorageAccountInner>>() {
@Override
public Observable<StorageAccountInner> call(Page<StorageAccountInner> innerPage) {
return Observable.from(innerPage.items());
public Iterable<StorageAccountInner> call(Page<StorageAccountInner> page) {
return page.items();
}
})
.map(new Func1<StorageAccountInner, StorageAccount>() {
Expand Down
Loading

0 comments on commit 1277779

Please sign in to comment.