Oracle® Coherence .NET API Reference Release 3.7.1
E22844-03

Assign the ownership of this Lock to the calling thread.

Namespace:  Tangosol.Net.Cache
Assembly:  Coherence (in Coherence.dll) Version: 3.7.1.23 (3.7.1.23)

Syntax

C#
public virtual bool Assign(
	long waitMillis
)

Parameters

waitMillis
Type: System..::.Int64
The number of milliseconds to continue trying to obtain a lock; pass zero to return immediately; pass -1 to block the calling thread until the lock could be obtained.

Return Value

true if lock was successful; false otherwise.

Remarks

Note: caller of this method is expected to hold a synchronization monitor for the Lock object while making this call.

See Also