Share via


ShareCreateOptions Class

  • java.lang.Object
    • com.azure.storage.file.share.options.ShareCreateOptions

public class ShareCreateOptions

Extended options that may be passed when creating a share.

Constructor Summary

Constructor Description
ShareCreateOptions()

Creates a new instance of ShareCreateOptions.

Method Summary

Modifier and Type Method and Description
ShareAccessTier getAccessTier()

Gets the access tier for the share.

Map<String,String> getMetadata()

Gets the metadata to associate with the share.

ShareProtocols getProtocols()

Gets the protocols to enable on the share.

Integer getQuotaInGb()

Gets the size in GB to limit the share's growth.

ShareRootSquash getRootSquash()

Gets the root squash to set for the share.

ShareCreateOptions setAccessTier(ShareAccessTier accessTier)

Sets the access tier for the share.

ShareCreateOptions setMetadata(Map<String,String> metadata)

Sets the metadata to associate with the share.

ShareCreateOptions setProtocols(ShareProtocols protocols)

Sets the protocols to enable on the share.

ShareCreateOptions setQuotaInGb(Integer quotaInGb)

Sets the size in GB to limit the share's growth.

ShareCreateOptions setRootSquash(ShareRootSquash rootSquash)

Sets the root squash to set for the share.

Methods inherited from java.lang.Object

Constructor Details

ShareCreateOptions

public ShareCreateOptions()

Creates a new instance of ShareCreateOptions.

Method Details

getAccessTier

public ShareAccessTier getAccessTier()

Gets the access tier for the share.

Returns:

getMetadata

public Map getMetadata()

Gets the metadata to associate with the share.

Returns:

Metadata to associate with the share

getProtocols

public ShareProtocols getProtocols()

Gets the protocols to enable on the share.

Returns:

getQuotaInGb

public Integer getQuotaInGb()

Gets the size in GB to limit the share's growth.

Returns:

Size in GB to limit the share's growth.

getRootSquash

public ShareRootSquash getRootSquash()

Gets the root squash to set for the share. Only valid for NFS.

Returns:

The root squash to set for the share. Only valid for NFS.

setAccessTier

public ShareCreateOptions setAccessTier(ShareAccessTier accessTier)

Sets the access tier for the share.

Parameters:

accessTier - ShareAccessTier.

Returns:

The updated options.

setMetadata

public ShareCreateOptions setMetadata(Map metadata)

Sets the metadata to associate with the share.

Parameters:

metadata - Metadata to associate with the share. If there is leading or trailing whitespace in any metadata key or value, it must be removed or encoded.

Returns:

The updated options.

setProtocols

public ShareCreateOptions setProtocols(ShareProtocols protocols)

Sets the protocols to enable on the share.

Parameters:

protocols - ShareProtocols

Returns:

The updated options.

setQuotaInGb

public ShareCreateOptions setQuotaInGb(Integer quotaInGb)

Sets the size in GB to limit the share's growth.

Parameters:

quotaInGb - Size in GB to limit the share's growth. The quota in GB must be between 1 and 5120.

Returns:

The updated options.

setRootSquash

public ShareCreateOptions setRootSquash(ShareRootSquash rootSquash)

Sets the root squash to set for the share. Only valid for NFS.

Parameters:

rootSquash - The root squash to set for the share. Only valid for NFS.

Returns:

The updated options.

Applies to