BlobURL.acquireLease(String proposedID, int duration, ModifiedAccessConditions modifiedAccessConditions, Context context) Method

Definition

Acquires a lease on the blob for write and delete operations. The lease duration must be between 15 to 60 seconds, or infinite (-1). For more information, see the Azure Docs.

public Single<BlobAcquireLeaseResponse> acquireLease(String proposedID, int duration, ModifiedAccessConditions modifiedAccessConditions, Context context)

Parameters

proposedID
String

AString 

</code> in any valid GUID format. May be null. </p>
duration
int

The duration of the lease, in seconds, or negative one (-1) for a lease that never expires. A non-infinite lease can be between 15 and 60 seconds.

modifiedAccessConditions
ModifiedAccessConditions

ModifiedAccessConditions

context
Context

Context 

</code> offers a means of passing arbitrary data (key/value pairs) to an <xref uid="" data-throw-if-not-resolved="false">com.microsoft.rest.v2.http.HttpPipeline</xref>'s policy objects. Most applications do not need to pass arbitrary data to the pipeline and can pass<code>Context.NONE 

</code> or<code>null 

</code> . Each context object is immutable. The<code>withContext 

</code> with data method creates a new<code>Context 

</code> object that refers to its parent, forming a linked list. </p>

Returns

Emits the successful response.

Applies to