Rhino C++ API  8.6
Public Member Functions | List of all members
ON_SleepLockGuard Class Reference

#include <opennurbs_sleeplock.h>

Public Member Functions

 ON_SleepLockGuard (class ON_FixedSizePool &fsp)
 
 ON_SleepLockGuard (class ON_SleepLock &sleep_lock)
 
 ON_SleepLockGuard (class ON_SleepLock &sleep_lock, unsigned int interval_wait_msecs, unsigned int max_wait_msecs)
 
 ON_SleepLockGuard (class ON_SleepLock &sleep_lock, unsigned int interval_wait_msecs, unsigned int max_wait_msecs, bool bStealLockAfterWaiting)
 
 ON_SleepLockGuard (const class ON_Brep &)
 
 ~ON_SleepLockGuard ()
 
const bool IsManagingLock () const
 
void ReturnLock ()
 

Constructor & Destructor Documentation

◆ ON_SleepLockGuard() [1/5]

ON_SleepLockGuard::ON_SleepLockGuard ( class ON_SleepLock sleep_lock)

Description: Calls sleep_lock.GetLock(). Parameters: sleep_lock - [in] ON_SleepLock to manage.

◆ ON_SleepLockGuard() [2/5]

ON_SleepLockGuard::ON_SleepLockGuard ( class ON_FixedSizePool fsp)

Used by The ThreadSafe...() functions and for expert users to use when managing memory controlled by this pool. Best to ignore this unless you have a very clear idea of what you are doing, why you are doing it, and when you are doing it. Otherwise, you'll find yourself waiting forever on a nested access request.

◆ ON_SleepLockGuard() [3/5]

ON_SleepLockGuard::ON_SleepLockGuard ( class ON_SleepLock sleep_lock,
unsigned int  interval_wait_msecs,
unsigned int  max_wait_msecs 
)

Description: Calls sleep_lock.GetLock(interval_wait_msecs,max_wait_msecs). Parameters: sleep_lock - [in] ON_SleepLock to manage.

◆ ON_SleepLockGuard() [4/5]

ON_SleepLockGuard::ON_SleepLockGuard ( class ON_SleepLock sleep_lock,
unsigned int  interval_wait_msecs,
unsigned int  max_wait_msecs,
bool  bStealLockAfterWaiting 
)

Description: Calls sleep_lock.GetLock(interval_wait_msecs,max_wait_msecs,bStealLockAfterWaiting). Parameters: sleep_lock - [in] ON_SleepLock to manage.

◆ ~ON_SleepLockGuard()

ON_SleepLockGuard::~ON_SleepLockGuard ( )

Description: Calls sleep_lock.ReturnLock().

◆ ON_SleepLockGuard() [5/5]

ON_SleepLockGuard::ON_SleepLockGuard ( const class ON_Brep )

Member Function Documentation

◆ IsManagingLock()

const bool ON_SleepLockGuard::IsManagingLock ( ) const

Returns: True if this instance currently has the lock.

◆ ReturnLock()

void ON_SleepLockGuard::ReturnLock ( )

Description: If this instance has the lock, it is returned and the destructor does nothing.