SMTK  @SMTK_VERSION@
Simulation Modeling Tool Kit
Friends | List of all members
smtk::resource::Key Class Reference

Operations need the ability to lock and unlock resources, but no additional access privilege is required. More...

#include <Resource.h>

Friends

class operation::Operation
 
class smtk::resource::ScopedLockSetGuard
 

Detailed Description

Operations need the ability to lock and unlock resources, but no additional access privilege is required.

We therefore use the PassKey pattern to grant Operation access to a resource's lock. Outside of operations, if you need to acquire a lock you must use a smtk::resource::ScopedLockSetGuard to ensure that locks are freed. Do not ever use the "new" operator to construct a ScopedLockSetGuard, as leaking it could cause deadlocks.


The documentation for this class was generated from the following file: