Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
/**
* 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_06_01;

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

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

/** Static value TLS1_1 for MinimumTlsVersion. */
public static final MinimumTlsVersion TLS1_1 = fromString("TLS1_1");

/** Static value TLS1_2 for MinimumTlsVersion. */
public static final MinimumTlsVersion TLS1_2 = fromString("TLS1_2");

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

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

/**
* @return the allowBlobPublicAccess value.
*/
Boolean allowBlobPublicAccess();

/**
* @return the azureFilesIdentityBasedAuthentication value.
*/
Expand Down Expand Up @@ -97,6 +102,11 @@ public interface StorageAccount extends HasInner<StorageAccountInner>, Resource,
*/
DateTime lastGeoFailoverTime();

/**
* @return the minimumTlsVersion value.
*/
MinimumTlsVersion minimumTlsVersion();

/**
* @return the networkRuleSet value.
*/
Expand Down Expand Up @@ -210,6 +220,18 @@ interface WithAccessTier {
WithCreate withAccessTier(AccessTier accessTier);
}

/**
* The stage of the storageaccount definition allowing to specify AllowBlobPublicAccess.
*/
interface WithAllowBlobPublicAccess {
/**
* Specifies allowBlobPublicAccess.
* @param allowBlobPublicAccess Allow or disallow public access to all blobs or containers in the storage account. The default interpretation is true for this property
* @return the next definition stage
*/
WithCreate withAllowBlobPublicAccess(Boolean allowBlobPublicAccess);
}

/**
* The stage of the storageaccount definition allowing to specify AzureFilesIdentityBasedAuthentication.
*/
Expand Down Expand Up @@ -294,6 +316,18 @@ interface WithLargeFileSharesState {
WithCreate withLargeFileSharesState(LargeFileSharesState largeFileSharesState);
}

/**
* The stage of the storageaccount definition allowing to specify MinimumTlsVersion.
*/
interface WithMinimumTlsVersion {
/**
* Specifies minimumTlsVersion.
* @param minimumTlsVersion Set the minimum TLS version to be permitted on requests to storage. The default interpretation is TLS 1.0 for this property. Possible values include: 'TLS1_0', 'TLS1_1', 'TLS1_2'
* @return the next definition stage
*/
WithCreate withMinimumTlsVersion(MinimumTlsVersion minimumTlsVersion);
}

/**
* The stage of the storageaccount definition allowing to specify NetworkRuleSet.
*/
Expand Down Expand Up @@ -323,13 +357,13 @@ interface WithRoutingPreference {
* 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.WithLargeFileSharesState, DefinitionStages.WithNetworkRuleSet, DefinitionStages.WithRoutingPreference {
interface WithCreate extends Creatable<StorageAccount>, Resource.DefinitionWithTags<WithCreate>, DefinitionStages.WithAccessTier, DefinitionStages.WithAllowBlobPublicAccess, DefinitionStages.WithAzureFilesIdentityBasedAuthentication, DefinitionStages.WithCustomDomain, DefinitionStages.WithEnableHttpsTrafficOnly, DefinitionStages.WithEncryption, DefinitionStages.WithIdentity, DefinitionStages.WithIsHnsEnabled, DefinitionStages.WithLargeFileSharesState, DefinitionStages.WithMinimumTlsVersion, DefinitionStages.WithNetworkRuleSet, DefinitionStages.WithRoutingPreference {
}
}
/**
* 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.WithLargeFileSharesState, UpdateStages.WithNetworkRuleSet, UpdateStages.WithRoutingPreference, UpdateStages.WithSku {
interface Update extends Appliable<StorageAccount>, Resource.UpdateWithTags<Update>, UpdateStages.WithAccessTier, UpdateStages.WithAllowBlobPublicAccess, UpdateStages.WithAzureFilesIdentityBasedAuthentication, UpdateStages.WithCustomDomain, UpdateStages.WithEnableHttpsTrafficOnly, UpdateStages.WithEncryption, UpdateStages.WithIdentity, UpdateStages.WithKind, UpdateStages.WithLargeFileSharesState, UpdateStages.WithMinimumTlsVersion, UpdateStages.WithNetworkRuleSet, UpdateStages.WithRoutingPreference, UpdateStages.WithSku {
}

/**
Expand All @@ -348,6 +382,18 @@ interface WithAccessTier {
Update withAccessTier(AccessTier accessTier);
}

/**
* The stage of the storageaccount update allowing to specify AllowBlobPublicAccess.
*/
interface WithAllowBlobPublicAccess {
/**
* Specifies allowBlobPublicAccess.
* @param allowBlobPublicAccess Allow or disallow public access to all blobs or containers in the storage account. The default interpretation is true for this property
* @return the next update stage
*/
Update withAllowBlobPublicAccess(Boolean allowBlobPublicAccess);
}

/**
* The stage of the storageaccount update allowing to specify AzureFilesIdentityBasedAuthentication.
*/
Expand Down Expand Up @@ -432,6 +478,18 @@ interface WithLargeFileSharesState {
Update withLargeFileSharesState(LargeFileSharesState largeFileSharesState);
}

/**
* The stage of the storageaccount update allowing to specify MinimumTlsVersion.
*/
interface WithMinimumTlsVersion {
/**
* Specifies minimumTlsVersion.
* @param minimumTlsVersion Set the minimum TLS version to be permitted on requests to storage. The default interpretation is TLS 1.0 for this property. Possible values include: 'TLS1_0', 'TLS1_1', 'TLS1_2'
* @return the next update stage
*/
Update withMinimumTlsVersion(MinimumTlsVersion minimumTlsVersion);
}

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

/**
* Allow or disallow public access to all blobs or containers in the
* storage account. The default interpretation is true for this property.
*/
@JsonProperty(value = "properties.allowBlobPublicAccess")
private Boolean allowBlobPublicAccess;

/**
* Set the minimum TLS version to be permitted on requests to storage. The
* default interpretation is TLS 1.0 for this property. Possible values
* include: 'TLS1_0', 'TLS1_1', 'TLS1_2'.
*/
@JsonProperty(value = "properties.minimumTlsVersion")
private MinimumTlsVersion minimumTlsVersion;

/**
* Get required. Gets or sets the SKU name.
*
Expand Down Expand Up @@ -400,4 +415,44 @@ public StorageAccountCreateParameters withRoutingPreference(RoutingPreference ro
return this;
}

/**
* Get allow or disallow public access to all blobs or containers in the storage account. The default interpretation is true for this property.
*
* @return the allowBlobPublicAccess value
*/
public Boolean allowBlobPublicAccess() {
return this.allowBlobPublicAccess;
}

/**
* Set allow or disallow public access to all blobs or containers in the storage account. The default interpretation is true for this property.
*
* @param allowBlobPublicAccess the allowBlobPublicAccess value to set
* @return the StorageAccountCreateParameters object itself.
*/
public StorageAccountCreateParameters withAllowBlobPublicAccess(Boolean allowBlobPublicAccess) {
this.allowBlobPublicAccess = allowBlobPublicAccess;
return this;
}

/**
* Get set the minimum TLS version to be permitted on requests to storage. The default interpretation is TLS 1.0 for this property. Possible values include: 'TLS1_0', 'TLS1_1', 'TLS1_2'.
*
* @return the minimumTlsVersion value
*/
public MinimumTlsVersion minimumTlsVersion() {
return this.minimumTlsVersion;
}

/**
* Set set the minimum TLS version to be permitted on requests to storage. The default interpretation is TLS 1.0 for this property. Possible values include: 'TLS1_0', 'TLS1_1', 'TLS1_2'.
*
* @param minimumTlsVersion the minimumTlsVersion value to set
* @return the StorageAccountCreateParameters object itself.
*/
public StorageAccountCreateParameters withMinimumTlsVersion(MinimumTlsVersion minimumTlsVersion) {
this.minimumTlsVersion = minimumTlsVersion;
return this;
}

}
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,21 @@ public class StorageAccountUpdateParameters {
@JsonProperty(value = "properties.routingPreference")
private RoutingPreference routingPreference;

/**
* Allow or disallow public access to all blobs or containers in the
* storage account. The default interpretation is true for this property.
*/
@JsonProperty(value = "properties.allowBlobPublicAccess")
private Boolean allowBlobPublicAccess;

/**
* Set the minimum TLS version to be permitted on requests to storage. The
* default interpretation is TLS 1.0 for this property. Possible values
* include: 'TLS1_0', 'TLS1_1', 'TLS1_2'.
*/
@JsonProperty(value = "properties.minimumTlsVersion")
private MinimumTlsVersion minimumTlsVersion;

/**
* Optional. Indicates the type of storage account. Currently only
* StorageV2 value supported by server. Possible values include: 'Storage',
Expand Down Expand Up @@ -326,6 +341,46 @@ public StorageAccountUpdateParameters withRoutingPreference(RoutingPreference ro
return this;
}

/**
* Get allow or disallow public access to all blobs or containers in the storage account. The default interpretation is true for this property.
*
* @return the allowBlobPublicAccess value
*/
public Boolean allowBlobPublicAccess() {
return this.allowBlobPublicAccess;
}

/**
* Set allow or disallow public access to all blobs or containers in the storage account. The default interpretation is true for this property.
*
* @param allowBlobPublicAccess the allowBlobPublicAccess value to set
* @return the StorageAccountUpdateParameters object itself.
*/
public StorageAccountUpdateParameters withAllowBlobPublicAccess(Boolean allowBlobPublicAccess) {
this.allowBlobPublicAccess = allowBlobPublicAccess;
return this;
}

/**
* Get set the minimum TLS version to be permitted on requests to storage. The default interpretation is TLS 1.0 for this property. Possible values include: 'TLS1_0', 'TLS1_1', 'TLS1_2'.
*
* @return the minimumTlsVersion value
*/
public MinimumTlsVersion minimumTlsVersion() {
return this.minimumTlsVersion;
}

/**
* Set set the minimum TLS version to be permitted on requests to storage. The default interpretation is TLS 1.0 for this property. Possible values include: 'TLS1_0', 'TLS1_1', 'TLS1_2'.
*
* @param minimumTlsVersion the minimumTlsVersion value to set
* @return the StorageAccountUpdateParameters object itself.
*/
public StorageAccountUpdateParameters withMinimumTlsVersion(MinimumTlsVersion minimumTlsVersion) {
this.minimumTlsVersion = minimumTlsVersion;
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 @@ -23,6 +23,7 @@
import com.microsoft.azure.management.storage.v2019_06_01.Identity;
import com.microsoft.azure.management.storage.v2019_06_01.Kind;
import com.microsoft.azure.management.storage.v2019_06_01.LargeFileSharesState;
import com.microsoft.azure.management.storage.v2019_06_01.MinimumTlsVersion;
import com.microsoft.azure.management.storage.v2019_06_01.NetworkRuleSet;
import com.microsoft.azure.management.storage.v2019_06_01.Endpoints;
import java.util.ArrayList;
Expand Down Expand Up @@ -93,6 +94,11 @@ public AccessTier accessTier() {
return this.inner().accessTier();
}

@Override
public Boolean allowBlobPublicAccess() {
return this.inner().allowBlobPublicAccess();
}

@Override
public AzureFilesIdentityBasedAuthentication azureFilesIdentityBasedAuthentication() {
return this.inner().azureFilesIdentityBasedAuthentication();
Expand Down Expand Up @@ -163,6 +169,11 @@ public DateTime lastGeoFailoverTime() {
return this.inner().lastGeoFailoverTime();
}

@Override
public MinimumTlsVersion minimumTlsVersion() {
return this.inner().minimumTlsVersion();
}

@Override
public NetworkRuleSet networkRuleSet() {
return this.inner().networkRuleSet();
Expand Down Expand Up @@ -260,6 +271,16 @@ public StorageAccountImpl withAccessTier(AccessTier accessTier) {
return this;
}

@Override
public StorageAccountImpl withAllowBlobPublicAccess(Boolean allowBlobPublicAccess) {
if (isInCreateMode()) {
this.createParameter.withAllowBlobPublicAccess(allowBlobPublicAccess);
} else {
this.updateParameter.withAllowBlobPublicAccess(allowBlobPublicAccess);
}
return this;
}

@Override
public StorageAccountImpl withAzureFilesIdentityBasedAuthentication(AzureFilesIdentityBasedAuthentication azureFilesIdentityBasedAuthentication) {
if (isInCreateMode()) {
Expand Down Expand Up @@ -320,6 +341,16 @@ public StorageAccountImpl withLargeFileSharesState(LargeFileSharesState largeFil
return this;
}

@Override
public StorageAccountImpl withMinimumTlsVersion(MinimumTlsVersion minimumTlsVersion) {
if (isInCreateMode()) {
this.createParameter.withMinimumTlsVersion(minimumTlsVersion);
} else {
this.updateParameter.withMinimumTlsVersion(minimumTlsVersion);
}
return this;
}

@Override
public StorageAccountImpl withNetworkRuleSet(NetworkRuleSet networkRuleSet) {
if (isInCreateMode()) {
Expand Down
Loading