Product Documentation

VCL/CLX Developers Guide

Previous Topic

Next Topic

Session-Wide Lock Modes

c-treeDB Lock Modes

c-treeDB .NET
Lock Modes


Explanation

CTLOCK_FREE

FREE_LOCK

Turn off session-wide record locking. Free all automatically-acquired locks (with certain exceptions, see below).

CTLOCK_READ

READ_LOCK

Non-blocking read locks. If the lock cannot be acquired an error is returned.

CTLOCK_READ_BLOCK

READ_BLOCK_LOCK

Blocking read lock. The thread will block until the lock can be acquired.

CTLOCK_WRITE

WRITE_LOCK

Non-blocking write lock. If the lock cannot be acquired an error is returned.

CTLOCK_WRITE_BLOCK

WRITE_BLOCK_LOCK

Blocking write lock. The thread will block until the lock can be acquired.

CTLOCK_RESET

RESET_LOCK

Equivalent to calling Lock with CTLOCK_FREE followed by Lock() with CTLOCK_WRITE. This releases currently-held record locks (with certain exceptions, see below).

CTLOCK_SUSPEND

SUSPEND_LOCK

Temporarily suspend session-wide record locking. While locking is suspended, new record reads, writes, and deletes will not be automatically locked. Existing record locks remain in place, though.

CTLOCK_RESTORE
_READ

RESTORE_READ_LOCK

To be used after a call to Lock with the CTLOCK_SUSPEND mode. This lock mode restores the lock mode as READ.

CTLOCK_RESTORE
_READ_BLOCK

RESTORE_READ

_BLOCK_LOCK

To be used after a call to Lock with the CTLOCK_SUSPEND mode. This lock mode restores the lock mode as READ_BLOCK.

CTLOCK_RESTORE
_WRITE

RESTORE_WRITE_LOCK

To be used after a call to Lock with the CTLOCK_SUSPEND mode. This lock mode restores the lock mode as WRITE.

CTLOCK_RESTORE
_WRITE_BLOCK

RESTORE_WRITE

_BLOCK_LOCK

To be used after a call to Lock with the CTLOCK_SUSPEND mode. This lock mode restores the lock mode as WRITE_BLOCK.

CTLOCK_RESTORE
_PREVIOUS

 

To be used after a call to Lock with the CTLOCK_SUSPEND mode. This lock mode restores the same lock mode that was valid before suspending the lock.

c-treeDB .NET Lock Modes are defined in the LOCK_MODE enum.

TOCIndex