LockManager.TestLock Method (String, LockManager.LockType, Int64)
Test if this thread already holds a lock.
Namespace: Microsoft.TeamFoundation.Framework.Server
Assembly: Microsoft.TeamFoundation.Framework.Server (in Microsoft.TeamFoundation.Framework.Server.dll)
Syntax
'Declaration
Public Function TestLock ( _
lockName As String, _
lockType As LockManager.LockType, _
requestId As Long _
) As Boolean
public bool TestLock(
string lockName,
LockManager.LockType lockType,
long requestId
)
public:
bool TestLock(
String^ lockName,
LockManager::LockType lockType,
long long requestId
)
member TestLock :
lockName:string *
lockType:LockManager.LockType *
requestId:int64 -> bool
public function TestLock(
lockName : String,
lockType : LockManager.LockType,
requestId : long
) : boolean
Parameters
lockName
Type: System.StringThe lock name to test.
lockType
Type: Microsoft.TeamFoundation.Framework.Server.LockManager.LockTypeThe lock type to test.
- requestId
Type: System.Int64
Return Value
Type: System.Boolean
True if the current thread already holds that lock, false otherwise.
.NET Framework Security
- Full trust for the immediate caller. This member cannot be used by partially trusted code. For more information, see Using Libraries from Partially Trusted Code.