Boost logo

Boost-Commit :

From: anthony_at_[hidden]
Date: 2008-05-08 09:00:00


Author: anthonyw
Date: 2008-05-08 08:59:59 EDT (Thu, 08 May 2008)
New Revision: 45211
URL: http://svn.boost.org/trac/boost/changeset/45211

Log:
Added docs for native_handle
Text files modified:
   trunk/libs/thread/doc/mutexes.qbk | 77 +++++++++++++++++++++++++++++++++++++++
   trunk/libs/thread/doc/thread_ref.qbk | 16 ++++++++
   2 files changed, 93 insertions(+), 0 deletions(-)

Modified: trunk/libs/thread/doc/mutexes.qbk
==============================================================================
--- trunk/libs/thread/doc/mutexes.qbk (original)
+++ trunk/libs/thread/doc/mutexes.qbk 2008-05-08 08:59:59 EDT (Thu, 08 May 2008)
@@ -12,6 +12,9 @@
         void lock();
         bool try_lock();
         void unlock();
+
+ typedef platform-specific-type native_handle_type;
+ native_handle_type native_handle();
         
         typedef unique_lock<mutex> scoped_lock;
         typedef scoped_lock scoped_try_lock;
@@ -20,6 +23,23 @@
 __mutex__ implements the __lockable_concept__ to provide an exclusive-ownership mutex. At most one thread can own the lock on a given
 instance of __mutex__ at any time. Multiple concurrent calls to __lock_ref__, __try_lock_ref__ and __unlock_ref__ shall be permitted.
 
+[section:nativehandle Member function `native_handle()`]
+
+ typedef platform-specific-type native_handle_type;
+ native_handle_type native_handle();
+
+[variablelist
+
+[[Effects:] [Returns an instance of `native_handle_type` that can be used with platform-specific APIs to manipulate the underlying
+implementation. If no such instance exists, `native_handle()` and `native_handle_type` are not present.]]
+
+[[Throws:] [Nothing.]]
+
+]
+
+[endsect]
+
+
 [endsect]
 
 [section:try_mutex Typedef `try_mutex`]
@@ -47,6 +67,9 @@
         template<typename TimeDuration>
         bool timed_lock(TimeDuration const & relative_time);
 
+ typedef platform-specific-type native_handle_type;
+ native_handle_type native_handle();
+
         typedef unique_lock<timed_mutex> scoped_timed_lock;
         typedef scoped_timed_lock scoped_try_lock;
         typedef scoped_timed_lock scoped_lock;
@@ -56,6 +79,22 @@
 lock on a given instance of __timed_mutex__ at any time. Multiple concurrent calls to __lock_ref__, __try_lock_ref__,
 __timed_lock_ref__, __timed_lock_duration_ref__ and __unlock_ref__ shall be permitted.
 
+[section:nativehandle Member function `native_handle()`]
+
+ typedef platform-specific-type native_handle_type;
+ native_handle_type native_handle();
+
+[variablelist
+
+[[Effects:] [Returns an instance of `native_handle_type` that can be used with platform-specific APIs to manipulate the underlying
+implementation. If no such instance exists, `native_handle()` and `native_handle_type` are not present.]]
+
+[[Throws:] [Nothing.]]
+
+]
+
+[endsect]
+
 [endsect]
 
 [section:recursive_mutex Class `recursive_mutex`]
@@ -70,6 +109,9 @@
         void lock();
         bool try_lock();
         void unlock();
+
+ typedef platform-specific-type native_handle_type;
+ native_handle_type native_handle();
         
         typedef unique_lock<recursive_mutex> scoped_lock;
         typedef scoped_lock scoped_try_lock;
@@ -81,6 +123,22 @@
 __lock_ref__ or __try_lock_ref__ to acquire an additional level of ownership of the mutex. __unlock_ref__ must be called once for
 each level of ownership acquired by a single thread before ownership can be acquired by another thread.
 
+[section:nativehandle Member function `native_handle()`]
+
+ typedef platform-specific-type native_handle_type;
+ native_handle_type native_handle();
+
+[variablelist
+
+[[Effects:] [Returns an instance of `native_handle_type` that can be used with platform-specific APIs to manipulate the underlying
+implementation. If no such instance exists, `native_handle()` and `native_handle_type` are not present.]]
+
+[[Throws:] [Nothing.]]
+
+]
+
+[endsect]
+
 [endsect]
 
 [section:recursive_try_mutex Typedef `recursive_try_mutex`]
@@ -108,6 +166,9 @@
 
         template<typename TimeDuration>
         bool timed_lock(TimeDuration const & relative_time);
+
+ typedef platform-specific-type native_handle_type;
+ native_handle_type native_handle();
         
         typedef unique_lock<recursive_timed_mutex> scoped_lock;
         typedef scoped_lock scoped_try_lock;
@@ -121,6 +182,22 @@
 __timed_lock_duration_ref__ or __try_lock_ref__ to acquire an additional level of ownership of the mutex. __unlock_ref__ must be
 called once for each level of ownership acquired by a single thread before ownership can be acquired by another thread.
 
+[section:nativehandle Member function `native_handle()`]
+
+ typedef platform-specific-type native_handle_type;
+ native_handle_type native_handle();
+
+[variablelist
+
+[[Effects:] [Returns an instance of `native_handle_type` that can be used with platform-specific APIs to manipulate the underlying
+implementation. If no such instance exists, `native_handle()` and `native_handle_type` are not present.]]
+
+[[Throws:] [Nothing.]]
+
+]
+
+[endsect]
+
 [endsect]
 
 [include shared_mutex_ref.qbk]

Modified: trunk/libs/thread/doc/thread_ref.qbk
==============================================================================
--- trunk/libs/thread/doc/thread_ref.qbk (original)
+++ trunk/libs/thread/doc/thread_ref.qbk 2008-05-08 08:59:59 EDT (Thu, 08 May 2008)
@@ -364,6 +364,22 @@
 
 [endsect]
 
+[section:nativehandle Member function `native_handle()`]
+
+ typedef platform-specific-type native_handle_type;
+ native_handle_type native_handle();
+
+[variablelist
+
+[[Effects:] [Returns an instance of `native_handle_type` that can be used with platform-specific APIs to manipulate the underlying
+implementation. If no such instance exists, `native_handle()` and `native_handle_type` are not present.]]
+
+[[Throws:] [Nothing.]]
+
+]
+
+[endsect]
+
 [section:equals `operator==`]
 
     bool operator==(const thread& other) const;


Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk