CTX_Base :: Lock - Lock context object
The function is used to lock a context object. Locking becomes necessary, when synchronization of context resources between different threads is requested. The function checks, whether the context is locked or not. When the context object is already locked, the function returns an error (wait= false ) or waits until the context object becomes available (wait= true ).
Return value: Success ( logical )