Dela via


ArmStorageModelFactory.BlobContainerImmutabilityPolicy Method

Definition

Initializes a new instance of BlobContainerImmutabilityPolicy.

public static Azure.ResourceManager.Storage.Models.BlobContainerImmutabilityPolicy BlobContainerImmutabilityPolicy (Azure.ETag? etag = default, System.Collections.Generic.IEnumerable<Azure.ResourceManager.Storage.Models.UpdateHistoryEntry> updateHistory = default, int? immutabilityPeriodSinceCreationInDays = default, Azure.ResourceManager.Storage.Models.ImmutabilityPolicyState? state = default, bool? allowProtectedAppendWrites = default, bool? allowProtectedAppendWritesAll = default);
static member BlobContainerImmutabilityPolicy : Nullable<Azure.ETag> * seq<Azure.ResourceManager.Storage.Models.UpdateHistoryEntry> * Nullable<int> * Nullable<Azure.ResourceManager.Storage.Models.ImmutabilityPolicyState> * Nullable<bool> * Nullable<bool> -> Azure.ResourceManager.Storage.Models.BlobContainerImmutabilityPolicy
Public Shared Function BlobContainerImmutabilityPolicy (Optional etag As Nullable(Of ETag) = Nothing, Optional updateHistory As IEnumerable(Of UpdateHistoryEntry) = Nothing, Optional immutabilityPeriodSinceCreationInDays As Nullable(Of Integer) = Nothing, Optional state As Nullable(Of ImmutabilityPolicyState) = Nothing, Optional allowProtectedAppendWrites As Nullable(Of Boolean) = Nothing, Optional allowProtectedAppendWritesAll As Nullable(Of Boolean) = Nothing) As BlobContainerImmutabilityPolicy

Parameters

etag
Nullable<ETag>

ImmutabilityPolicy Etag.

updateHistory
IEnumerable<UpdateHistoryEntry>

The ImmutabilityPolicy update history of the blob container.

immutabilityPeriodSinceCreationInDays
Nullable<Int32>

The immutability period for the blobs in the container since the policy creation, in days.

state
Nullable<ImmutabilityPolicyState>

The ImmutabilityPolicy state of a blob container, possible values include: Locked and Unlocked.

allowProtectedAppendWrites
Nullable<Boolean>

This property can only be changed for unlocked time-based retention policies. When enabled, new blocks can be written to an append blob while maintaining immutability protection and compliance. Only new blocks can be added and any existing blocks cannot be modified or deleted. This property cannot be changed with ExtendImmutabilityPolicy API.

allowProtectedAppendWritesAll
Nullable<Boolean>

This property can only be changed for unlocked time-based retention policies. When enabled, new blocks can be written to both 'Append and Bock Blobs' while maintaining immutability protection and compliance. Only new blocks can be added and any existing blocks cannot be modified or deleted. This property cannot be changed with ExtendImmutabilityPolicy API. The 'allowProtectedAppendWrites' and 'allowProtectedAppendWritesAll' properties are mutually exclusive.

Returns

A new BlobContainerImmutabilityPolicy instance for mocking.

Applies to