/// <summary> /// Adds an operation be submitted as part of the batch. /// </summary> /// <param name="pageBlob">The <see cref="CloudPageBlob"/> whose tier will be set.</param> /// <param name="premiumPageBlobTier">A <see cref="PremiumPageBlobTier"/> representing the tier to set.</param> /// <param name="accessCondition">An <see cref="AccessCondition"/> object that represents the condition that must be met in order for the request to proceed. If <c>null</c>, no condition is used.</param> /// <param name="blobRequestOptions">A <see cref="BlobRequestOptions"/> object that specifies additional options for the request.</param> public void AddSubOperation(CloudPageBlob pageBlob, PremiumPageBlobTier premiumPageBlobTier, AccessCondition accessCondition = default(AccessCondition), BlobRequestOptions blobRequestOptions = default(BlobRequestOptions)) { CommonUtility.AssertInBounds("operationCount", this.Operations.Count, 0, Constants.MaxSubOperationPerBatch - 1); CommonUtility.AssertNotNull("pageBlob", pageBlob); CommonUtility.AssertNotNull("premiumPageBlobTier", premiumPageBlobTier); this.Operations.Add(pageBlob.SetBlobTierImpl(premiumPageBlobTier, blobRequestOptions ?? BlobRequestOptions.BaseDefaultRequestOptions)); }