Inheritance diagram for IResource:
Public Member Functions | |
protected void | closure () |
Object | getLock () |
void | setLock (Object lock) |
void | acquire () |
bool | acquireIfOpen () |
void | close () |
Definition at line 46 of file IResource.d.
|
Subclasses must implement closure mechanics. This is invoked when the number of close() invocations match that of aquire() -- the latter is typically called immediately following the successful construction of an IResource implementation; one should expect close to be required at least once. Reimplemented in Conduit, FileConduit, Resource, and Socket. |
|
Return the lock used by this resource Reimplemented in Resource. |
|
Set an alternate lock. Typically one would use this to synchronize multiple different Resources via a common object. Reimplemented in Resource. |
|
hold a reference to this resource. The caller is now responsible for invoking close() upon this resource; Reimplemented in Resource. |
|
If this resource is still open, acquire it and return true. This is a threadsafe test-and-set mechanism that fails only if the resource is already closed, or was never opened. Note that you are responsible for invoking close() whenever this method returns true. Reimplemented in Resource. |
|
release a reference to this resource Reimplemented in Resource. Referenced by HttpClient::close(), ConnectionPool::PoolConnection::close(), HttpBridge::cross(), ClusterThread::run(), and testClient(). |