Click or drag to resize

WebDavSessionLockAsync Method

IT Hit WebDAV Classes Reference
Locks an item.

Namespace:  ITHit.WebDAV.Client
Assembly:  ITHit.WebDAV.Client (in ITHit.WebDAV.Client.dll) Version: 6.0.4052-Beta
Syntax
public Task<LockInfo> LockAsync(
	Uri item,
	LockScope lockScope,
	bool deep,
	string owner,
	Nullable<TimeSpan> timeout,
	IDictionary<string, string> headers = null,
	CancellationToken cancellationToken = null
)

Parameters

item
Type: SystemUri
URI of the item to be locked.
lockScope
Type: ITHit.WebDAV.ClientLockScope
Scope of the lock.
deep
Type: SystemBoolean
Whether to lock entire subtree.
owner
Type: SystemString
Owner of the lock.
timeout
Type: SystemNullableTimeSpan
TimeOut after which lock expires.
headers (Optional)
Type: System.Collections.GenericIDictionaryString, String
Request headers.
cancellationToken (Optional)
Type: System.ThreadingCancellationToken
Propagates notification that operations should be canceled.

Return Value

Type: TaskLockInfo
Instance of LockInfo with information about the created lock.
Remarks
Server can set lock with different timeout than the one that was requested.
See Also