Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r52724 - in sandbox/interthreads: boost/interthreads boost/interthreads/algorithm boost/interthreads/typeof libs/interthreads/doc libs/interthreads/doc/reference libs/interthreads/doc/reference/typeof libs/interthreads/example libs/interthreads/test
From: vicente.botet_at_[hidden]
Date: 2009-05-02 06:41:05


Author: viboes
Date: 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
New Revision: 52724
URL: http://svn.boost.org/trac/boost/changeset/52724

Log:
Boost.Interthreads V0.1.3 : Removal of Async
Removed:
   sandbox/interthreads/boost/interthreads/algorithm/
   sandbox/interthreads/boost/interthreads/future_traits.hpp
   sandbox/interthreads/boost/interthreads/typeof/
   sandbox/interthreads/libs/interthreads/doc/reference/act_traits.qbk
   sandbox/interthreads/libs/interthreads/doc/reference/algorithm.qbk
   sandbox/interthreads/libs/interthreads/doc/reference/are_all_joinable.qbk
   sandbox/interthreads/libs/interthreads/doc/reference/are_all_ready.qbk
   sandbox/interthreads/libs/interthreads/doc/reference/asynchronous_adapter.qbk
   sandbox/interthreads/libs/interthreads/doc/reference/asynchronous_executor_decorator.qbk
   sandbox/interthreads/libs/interthreads/doc/reference/basic_threader.qbk
   sandbox/interthreads/libs/interthreads/doc/reference/basic_threader_decorator.qbk
   sandbox/interthreads/libs/interthreads/doc/reference/detach.qbk
   sandbox/interthreads/libs/interthreads/doc/reference/detach_all.qbk
   sandbox/interthreads/libs/interthreads/doc/reference/fork.qbk
   sandbox/interthreads/libs/interthreads/doc/reference/fork_after.qbk
   sandbox/interthreads/libs/interthreads/doc/reference/fork_all.qbk
   sandbox/interthreads/libs/interthreads/doc/reference/get.qbk
   sandbox/interthreads/libs/interthreads/doc/reference/get_all.qbk
   sandbox/interthreads/libs/interthreads/doc/reference/has_exception.qbk
   sandbox/interthreads/libs/interthreads/doc/reference/has_value.qbk
   sandbox/interthreads/libs/interthreads/doc/reference/have_all_exception.qbk
   sandbox/interthreads/libs/interthreads/doc/reference/have_all_value.qbk
   sandbox/interthreads/libs/interthreads/doc/reference/interrupt.qbk
   sandbox/interthreads/libs/interthreads/doc/reference/interrupt_all.qbk
   sandbox/interthreads/libs/interthreads/doc/reference/interruption_requested.qbk
   sandbox/interthreads/libs/interthreads/doc/reference/interruption_requested_all.qbk
   sandbox/interthreads/libs/interthreads/doc/reference/is_ready.qbk
   sandbox/interthreads/libs/interthreads/doc/reference/join.qbk
   sandbox/interthreads/libs/interthreads/doc/reference/join_all.qbk
   sandbox/interthreads/libs/interthreads/doc/reference/join_all_until.qbk
   sandbox/interthreads/libs/interthreads/doc/reference/join_until.qbk
   sandbox/interthreads/libs/interthreads/doc/reference/joinable.qbk
   sandbox/interthreads/libs/interthreads/doc/reference/launcher.qbk
   sandbox/interthreads/libs/interthreads/doc/reference/launcher_decorator.qbk
   sandbox/interthreads/libs/interthreads/doc/reference/scheduler.qbk
   sandbox/interthreads/libs/interthreads/doc/reference/threader.qbk
   sandbox/interthreads/libs/interthreads/doc/reference/typeof/
   sandbox/interthreads/libs/interthreads/doc/reference/wait.qbk
   sandbox/interthreads/libs/interthreads/doc/reference/wait_all.qbk
   sandbox/interthreads/libs/interthreads/doc/reference/wait_all_until.qbk
   sandbox/interthreads/libs/interthreads/doc/reference/wait_for_all.qbk
   sandbox/interthreads/libs/interthreads/doc/reference/wait_for_any.qbk
   sandbox/interthreads/libs/interthreads/doc/reference/wait_until.qbk
   sandbox/interthreads/libs/interthreads/test/data_types.hpp
   sandbox/interthreads/libs/interthreads/test/test_ae.hpp
   sandbox/interthreads/libs/interthreads/test/test_basic_threader.cpp
   sandbox/interthreads/libs/interthreads/test/test_launcher.cpp
   sandbox/interthreads/libs/interthreads/test/test_thread_pool.cpp
   sandbox/interthreads/libs/interthreads/test/test_thread_shared_ptr.cpp
   sandbox/interthreads/libs/interthreads/test/test_threader.cpp
Text files modified:
   sandbox/interthreads/boost/interthreads/basic_threader_decorator.hpp | 9 +++++----
   sandbox/interthreads/boost/interthreads/thread_specific_shared_ptr.hpp | 5 ++---
   sandbox/interthreads/boost/interthreads/threader_decorator.hpp | 8 ++++----
   sandbox/interthreads/libs/interthreads/doc/interthreads.qbk | 2 +-
   sandbox/interthreads/libs/interthreads/example/basic_keep_alive.cpp | 13 +++++++++----
   sandbox/interthreads/libs/interthreads/example/hello_world.cpp | 2 +-
   sandbox/interthreads/libs/interthreads/example/mono_thread_id.cpp | 38 +++++++-------------------------------
   sandbox/interthreads/libs/interthreads/test/Jamfile.v2 | 13 +------------
   8 files changed, 30 insertions(+), 60 deletions(-)

Modified: sandbox/interthreads/boost/interthreads/basic_threader_decorator.hpp
==============================================================================
--- sandbox/interthreads/boost/interthreads/basic_threader_decorator.hpp (original)
+++ sandbox/interthreads/boost/interthreads/basic_threader_decorator.hpp 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
@@ -15,9 +15,10 @@
 //
 //////////////////////////////////////////////////////////////////////////////
 
-#include <boost/interthreads/asynchronous_executor_wait_decorator.hpp>
-#include <boost/interthreads/wait_thread_decorator.hpp>
-#include <boost/interthreads/basic_threader.hpp>
+#include <boost/async/asynchronous_executor_wait_decorator.hpp>
+//#include <boost/async/wait_thread_decorator.hpp>
+#include <boost/async/basic_threader.hpp>
+#include <boost/interthreads/thread_decorator.hpp>
 
 
 #include <boost/config/abi_prefix.hpp>
@@ -26,7 +27,7 @@
 namespace interthreads {
 
 
- typedef asynchronous_executor_wait_decorator<basic_threader,thread_decorator> basic_threader_decorator;
+ typedef asynchronous_executor_wait_decorator<async::basic_threader,thread_decorator> basic_threader_decorator;
 
 }
 }

Deleted: sandbox/interthreads/boost/interthreads/future_traits.hpp
==============================================================================
--- sandbox/interthreads/boost/interthreads/future_traits.hpp 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
+++ (empty file)
@@ -1,177 +0,0 @@
-#ifndef BOOST_INTERTHREADS_FUTURE_TRAITS__HPP
-#define BOOST_INTERTHREADS_FUTURE_TRAITS__HPP
-
-//////////////////////////////////////////////////////////////////////////////
-//
-// (C) Copyright Vicente J. Botet Escriba 2008-2009.
-// Distributed under the Boost Software License, Version 1.0.
-// (See accompanying file LICENSE_1_0.txt or
-// copy at http://www.boost.org/LICENSE_1_0.txt)
-//
-// Based on the threader/joiner design from of Kevlin Henney (n1883)
-//
-// See http://www.boost.org/libs/interthreads for documentation.
-//
-//////////////////////////////////////////////////////////////////////////////
-
-#include <boost/interthreads/act_traits.hpp>
-#include <boost/thread/detail/move.hpp>
-//#include <boost/thread/thread.hpp>
-#include <boost/futures/future.hpp>
-//#include <boost/utility/result_of.hpp>
-#include <boost/type_traits/is_fundamental.hpp>
-#include <boost/type_traits/is_convertible.hpp>
-#include <boost/mpl/if.hpp>
-
-#include <boost/config/abi_prefix.hpp>
-
-
-namespace boost {
-namespace interthreads {
-
- template<typename T>
- struct act_traits<unique_future<T> >
- {
- typedef boost::scoped_ptr<T> storage_type;
-#ifdef BOOST_HAS_RVALUE_REFS
- typedef T const& source_reference_type;
- struct dummy;
- typedef typename boost::mpl::if_<boost::is_fundamental<T>,dummy&,T&&>::type rvalue_source_type;
- typedef typename boost::mpl::if_<boost::is_fundamental<T>,T,T&&>::type move_dest_type;
-#else
- typedef T& source_reference_type;
- typedef typename boost::mpl::if_<boost::is_convertible<T&,boost::detail::thread_move_t<T> >,boost::detail::thread_move_t<T>,T const&>::type rvalue_source_type;
- typedef typename boost::mpl::if_<boost::is_convertible<T&,boost::detail::thread_move_t<T> >,boost::detail::thread_move_t<T>,T>::type move_dest_type;
-#endif
-
- static void init(storage_type& storage,source_reference_type t)
- {
- storage.reset(new T(t));
- }
-
- static void init(storage_type& storage,rvalue_source_type t)
- {
- storage.reset(new T(static_cast<rvalue_source_type>(t)));
- }
-
- static void cleanup(storage_type& storage)
- {
- storage.reset();
- }
- };
-
- template<typename T>
- struct act_traits<unique_future<T&> >
- {
- typedef T* storage_type;
- typedef T& source_reference_type;
- struct rvalue_source_type
- {};
- typedef T& move_dest_type;
-
- static void init(storage_type& storage,T& t)
- {
- storage=&t;
- }
-
- static void cleanup(storage_type& storage)
- {
- storage=0;
- }
- };
-
- template<>
- struct act_traits<unique_future<void> >
- {
- typedef bool storage_type;
- typedef void move_dest_type;
-
- static void init(storage_type& storage)
- {
- storage=true;
- }
-
- static void cleanup(storage_type& storage)
- {
- storage=false;
- }
-
- };
-
- template<typename T>
- struct act_traits<shared_future<T> >
- {
- typedef boost::scoped_ptr<T> storage_type;
-#ifdef BOOST_HAS_RVALUE_REFS
- typedef T const& source_reference_type;
- struct dummy;
- typedef typename boost::mpl::if_<boost::is_fundamental<T>,dummy&,T&&>::type rvalue_source_type;
-#else
- typedef T& source_reference_type;
- typedef typename boost::mpl::if_<boost::is_convertible<T&,boost::detail::thread_move_t<T> >,boost::detail::thread_move_t<T>,T const&>::type rvalue_source_type;
-#endif
- //typedef const T& move_dest_type;
- typedef T move_dest_type;
-
- static void init(storage_type& storage,source_reference_type t)
- {
- storage.reset(new T(t));
- }
-
- static void init(storage_type& storage,rvalue_source_type t)
- {
- storage.reset(new T(static_cast<rvalue_source_type>(t)));
- }
-
- static void cleanup(storage_type& storage)
- {
- storage.reset();
- }
- };
-
- template<typename T>
- struct act_traits<shared_future<T&> >
- {
- typedef T* storage_type;
- typedef T& source_reference_type;
- struct rvalue_source_type
- {};
- typedef T& move_dest_type;
-
- static void init(storage_type& storage,T& t)
- {
- storage=&t;
- }
-
- static void cleanup(storage_type& storage)
- {
- storage=0;
- }
- };
-
- template<>
- struct act_traits<shared_future<void> >
- {
- typedef bool storage_type;
- typedef void move_dest_type;
-
- static void init(storage_type& storage)
- {
- storage=true;
- }
-
- static void cleanup(storage_type& storage)
- {
- storage=false;
- }
-
- };
-
-}
-}
-
-
-#include <boost/config/abi_suffix.hpp>
-
-#endif
-

Modified: sandbox/interthreads/boost/interthreads/thread_specific_shared_ptr.hpp
==============================================================================
--- sandbox/interthreads/boost/interthreads/thread_specific_shared_ptr.hpp (original)
+++ sandbox/interthreads/boost/interthreads/thread_specific_shared_ptr.hpp 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
@@ -36,7 +36,7 @@
         typedef shared_ptr<T> shared_ptr_type;
         typedef std::map<thread::id, shared_ptr_type> map_type;
         typedef mutex mutex_type;
- typedef unique_lock<mutex_type> lock_type;
+ typedef unique_lock<mutex_type> lock_type;
     private:
         typedef condition_variable condition_type;
 
@@ -199,8 +199,7 @@
             lock_type lock(monitor_);
             typename map_type::const_iterator i(tmap_.find(id));
             if ( i == tmap_.end()) {
- mapchanged_.wait(lock);
-
+ // mapchanged_.wait(lock);
                 return shared_ptr_type();
             } else {
                 return i->second;

Modified: sandbox/interthreads/boost/interthreads/threader_decorator.hpp
==============================================================================
--- sandbox/interthreads/boost/interthreads/threader_decorator.hpp (original)
+++ sandbox/interthreads/boost/interthreads/threader_decorator.hpp 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
@@ -15,9 +15,9 @@
 //
 //////////////////////////////////////////////////////////////////////////////
 
-#include <boost/interthreads/asynchronous_executor_decorator.hpp>
+#include <boost/async/asynchronous_executor_decorator.hpp>
 #include <boost/interthreads/thread_decorator.hpp>
-#include <boost/interthreads/threader.hpp>
+#include <boost/async/threader.hpp>
 
 
 #include <boost/config/abi_prefix.hpp>
@@ -26,8 +26,8 @@
 namespace interthreads {
 
 
- typedef asynchronous_executor_decorator<unique_threader,basic_thread_decorator> unique_threader_decorator;
- typedef asynchronous_executor_decorator<shared_threader,basic_thread_decorator> shared_threader_decorator;
+ typedef asynchronous_executor_decorator<async::unique_threader,basic_thread_decorator> unique_threader_decorator;
+ typedef asynchronous_executor_decorator<async::shared_threader,basic_thread_decorator> shared_threader_decorator;
 
 }
 }

Modified: sandbox/interthreads/libs/interthreads/doc/interthreads.qbk
==============================================================================
--- sandbox/interthreads/libs/interthreads/doc/interthreads.qbk (original)
+++ sandbox/interthreads/libs/interthreads/doc/interthreads.qbk 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
@@ -6,7 +6,7 @@
   http://www.boost.org/LICENSE_1_0.txt).
 ]
 
-[article InterThreads
+[article Toward Boost.InterThreads
     [quickbook 1.4]
     [authors [Botet Escriba, Vicente J.]]
     [copyright 2008-2009 Vicente J. Botet Escriba]

Deleted: sandbox/interthreads/libs/interthreads/doc/reference/act_traits.qbk
==============================================================================
--- sandbox/interthreads/libs/interthreads/doc/reference/act_traits.qbk 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
+++ (empty file)
@@ -1,39 +0,0 @@
-[/
- (C) Copyright 2008-2009 Vicente J. Botet Escriba
- Distributed under the Boost Software License, Version 1.0.
- (See accompanying file LICENSE_1_0.txt or copy at
- http://www.boost.org/LICENSE_1_0.txt).
-]
-
-[/==========================================================================================]
-[section:act_traits_hpp Header `<boost/interthreads/act_traits.hpp>`]
-[/==========================================================================================]
-
-Includes all the __ACT__ and __AE__ traits.
-
- namespace boost {
- namespace interthreads {
-
- template<typename ACT>
- struct act_traits;
-
- template <typename ACT>
- struct is_movable;
-
- template <typename ACT>
- struct has_future_if;
-
- template <typename ACT>
- struct has_thread_if;
-
- template <typename AE, typename T>
- struct asynchronous_completion_token;
-
- template <typename AE>
- struct get_future;
-
- }
- }
-
-[endsect]
-

Deleted: sandbox/interthreads/libs/interthreads/doc/reference/algorithm.qbk
==============================================================================
--- sandbox/interthreads/libs/interthreads/doc/reference/algorithm.qbk 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
+++ (empty file)
@@ -1,57 +0,0 @@
-[/
- (C) Copyright 2008-2009 Vicente J. Botet Escriba
- Distributed under the Boost Software License, Version 1.0.
- (See accompanying file LICENSE_1_0.txt or copy at
- http://www.boost.org/LICENSE_1_0.txt).
-]
-
-[/==========================================================================================]
-[section:algorithm_hpp Header `<boost/interthreads/algorithm.hpp>`]
-[/==========================================================================================]
-
-Include all the __AE__/__ACT__ framework functions.
-
- #include <boost/interthreads/fork.hpp>
- //#include <boost/interthreads/lazy_fork.hpp>
- #include <boost/interthreads/fork_after.hpp>
- #include <boost/interthreads/fork_all.hpp>
- #include <boost/interthreads/wait_for_all.hpp>
- #include <boost/interthreads/wait_for_any.hpp>
-
- #include <boost/interthreads/algorithm/join.hpp>
- #include <boost/interthreads/algorithm/join_until.hpp>
- //#include <boost/interthreads/algorithm/join_all_for.hpp>
- #include <boost/interthreads/algorithm/joinable.hpp>
- #include <boost/interthreads/algorithm/detach.hpp>
- #include <boost/interthreads/algorithm/interrupt.hpp>
- #include <boost/interthreads/algorithm/interruption_requested.hpp>
-
- #include <boost/interthreads/algorithm/join_all.hpp>
- #include <boost/interthreads/algorithm/join_all_until.hpp>
- //#include <boost/interthreads/algorithm/join_all_for.hpp>
- #include <boost/interthreads/algorithm/are_all_joinable.hpp>
- #include <boost/interthreads/algorithm/detach_all.hpp>
- #include <boost/interthreads/algorithm/interrupt_all.hpp>
- #include <boost/interthreads/algorithm/interruption_requested_on_all.hpp>
-
- #include <boost/interthreads/algorithm/wait.hpp>
- #include <boost/interthreads/algorithm/wait_until.hpp>
- //#include <boost/interthreads/algorithm/wait_all_for.hpp>
- #include <boost/interthreads/algorithm/get.hpp>
- #include <boost/interthreads/algorithm/get_until.hpp>
- #include <boost/interthreads/algorithm/is_ready.hpp>
- #include <boost/interthreads/algorithm/has_value.hpp>
- #include <boost/interthreads/algorithm/has_exception.hpp>
-
- #include <boost/interthreads/algorithm/wait_all.hpp>
- #include <boost/interthreads/algorithm/wait_all_until.hpp>
- //#include <boost/interthreads/algorithm/wait_all_for.hpp>
- #include <boost/interthreads/algorithm/get_all.hpp>
- //#include <boost/interthreads/algorithm/get_all_until.hpp>
- //#include <boost/interthreads/algorithm/get_all_for.hpp>
- #include <boost/interthreads/algorithm/are_all_ready.hpp>
- #include <boost/interthreads/algorithm/have_all_value.hpp>
- #include <boost/interthreads/algorithm/have_all_exception.hpp>
-
-[endsect]
-

Deleted: sandbox/interthreads/libs/interthreads/doc/reference/are_all_joinable.qbk
==============================================================================
--- sandbox/interthreads/libs/interthreads/doc/reference/are_all_joinable.qbk 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
+++ (empty file)
@@ -1,36 +0,0 @@
-[/
- (C) Copyright 2008-2009 Vicente J. Botet Escriba
- Distributed under the Boost Software License, Version 1.0.
- (See accompanying file LICENSE_1_0.txt or copy at
- http://www.boost.org/LICENSE_1_0.txt).
-]
-
-[/==========================================================================================]
-[section:are_all_joinable_hpp Header `<boost/interthreads/algorithm/are_all_joinable.hpp>`]
-[/==========================================================================================]
-
-Defines a free function __are_all_joinable__ which states if all the __ACT__ in a sequence of __ACT__ are __joinable__.
-
- namespace boost { namespace interthreads {
- namespace fct {
- struct joinable {
- typedef bool result_type;
-
- template<typename ACT>
- bool operator()(ACT& act) const;
- };
- }
-
- namespace result_of {
- template <typename Sequence>
- struct are_all_joinable {
- typedef typename fusion::result_of::all<Sequence, fct::joinable>::type type;
- };
- }
-
- template <typename Sequence>
- bool are_all_joinable(Sequence& t);
- }}
-
-[endsect]
-

Deleted: sandbox/interthreads/libs/interthreads/doc/reference/are_all_ready.qbk
==============================================================================
--- sandbox/interthreads/libs/interthreads/doc/reference/are_all_ready.qbk 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
+++ (empty file)
@@ -1,33 +0,0 @@
-[/
- (C) Copyright 2008-2009 Vicente J. Botet Escriba
- Distributed under the Boost Software License, Version 1.0.
- (See accompanying file LICENSE_1_0.txt or copy at
- http://www.boost.org/LICENSE_1_0.txt).
-]
-
-[/==========================================================================================]
-[section:are_all_ready_hpp Header `<boost/interthreads/algorithm/are_all_ready.hpp>`]
-[/==========================================================================================]
-
-Defines a free function __are_all_ready__ which states if all the __ACT__ in a sequence of __ACT__ are ready.
-The current implementation applies the __is_ready__ free function for each __ACT__.
-
- namespace boost { namespace interthreads {
- namespace fct {
- struct is_ready {
- typedef bool result_type;
- template<typename ACT> bool operator()(ACT& act) const;
- };
- }
-
- namespace result_of {
- template <typename Sequence> struct are_all_ready {
- typedef typename fusion::result_of::template all<Sequence, fct::is_ready>::type type;
- };
- }
-
- template <typename Sequence> bool are_all_ready(Sequence& t);
- }}
-
-[endsect]
-

Deleted: sandbox/interthreads/libs/interthreads/doc/reference/asynchronous_adapter.qbk
==============================================================================
--- sandbox/interthreads/libs/interthreads/doc/reference/asynchronous_adapter.qbk 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
+++ (empty file)
@@ -1,53 +0,0 @@
-[/
- (C) Copyright 2008-2009 Vicente J. Botet Escriba
- Distributed under the Boost Software License, Version 1.0.
- (See accompanying file LICENSE_1_0.txt or copy at
- http://www.boost.org/LICENSE_1_0.txt).
-]
-
-
-[/==========================================================================================]
-[section:asynchronous_adapter_hpp Header `<boost/interthreads/asynchronous_adapter.hpp>`]
-[/==========================================================================================]
-
- namespace boost { namespace interthreads {
- template <typename AE, template <class> class Decorator>
- struct asynchronous_executor_decorator : AE {
- template <typename T>
- struct handle {
- typedef typename AE::template handle<T>::type type;
- };
-
- template <typename F>
- typename AE::template handle< typename boost::result_of<F()>::type >::type
- fork( F fn );
-
- asynchronous_executor_decorator();
-
- template <typename Nullary>
- asynchronous_executor_decorator(thread::native_handle_attr_type& attr, Nullary f);
- asynchronous_executor_decorator(Nullary f);
-
- asynchronous_executor_decorator(boost::detail::thread_move_t<asynchronous_executor_decorator> x);
-
- asynchronous_executor_decorator& operator=(boost::detail::thread_move_t<asynchronous_executor_decorator> x);
-
- operator boost::detail::thread_move_t<asynchronous_executor_decorator>();
-
- boost::detail::thread_move_t<asynchronous_executor_decorator> move();
- };
-
- template <typename AE, template <class> class Decorator>
- struct get_future<asynchronous_executor_decorator<AE, Decorator> > {
- template <typename T>
- struct future_type {
- typedef typename AE::template get_future<AE>::type type;
- };
- template <typename T>
- typename future_type<T>::type& operator()(typename AE::template handle<T>::type & j);
- };
- }}
-
-
-[endsect]
-

Deleted: sandbox/interthreads/libs/interthreads/doc/reference/asynchronous_executor_decorator.qbk
==============================================================================
--- sandbox/interthreads/libs/interthreads/doc/reference/asynchronous_executor_decorator.qbk 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
+++ (empty file)
@@ -1,36 +0,0 @@
-[/
- (C) Copyright 2008-2009 Vicente J. Botet Escriba
- Distributed under the Boost Software License, Version 1.0.
- (See accompanying file LICENSE_1_0.txt or copy at
- http://www.boost.org/LICENSE_1_0.txt).
-]
-
-[/==========================================================================================]
-[section:asynchronous_executor_decorator_hpp Header `<boost/interthreads/asynchronous_executor_decorator.hpp>`]
-[/==========================================================================================]
-
- namespace boost { namespace interthreads {
- template <typename AE, template <class> class Decorator>
- struct asynchronous_executor_decorator : AE {
- template <typename T> struct handle {
- typedef typename AE::template handle<T>::type type;
- };
-
- template <typename F>
- typename AE::template handle< typename boost::result_of<F()>::type >::type
- fork( F fn );
- };
-
- template <typename AE, template <class> class Decorator>
- struct get_future<asynchronous_executor_decorator<AE, Decorator> > {
- template <typename T>
- struct future_type {
- typedef typename AE::template get_future<AE>::type type;
- };
- template <typename T>
- typename future_type<T>::type& operator()(typename AE::template handle<T>::type & j);
- };
- }}
-
-[endsect]
-

Deleted: sandbox/interthreads/libs/interthreads/doc/reference/basic_threader.qbk
==============================================================================
--- sandbox/interthreads/libs/interthreads/doc/reference/basic_threader.qbk 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
+++ (empty file)
@@ -1,69 +0,0 @@
-[/
- (C) Copyright 2008-2009 Vicente J. Botet Escriba
- Distributed under the Boost Software License, Version 1.0.
- (See accompanying file LICENSE_1_0.txt or copy at
- http://www.boost.org/LICENSE_1_0.txt).
-]
-
-[/==========================================================================================]
-[section:basic_threader_hpp Header `<boost/interthreads/basic_threader.hpp>`]
-[/==========================================================================================]
-
-__basic_threader__ is an __AE__ with a thread as __ThreadBasedACT__.
-
- namespace boost { namespace interthreads {
- class basic_threader {
- public:
- thread::native_handle_attr_type& attr();
-
- template <typename T> struct handle {
- typedef thread type;
- };
-
- template <typename F> thread fork(F f);
- };
-
- template<>
- struct act_traits<thread > {
- typedef void move_dest_type;
- };
-
- namespace partial_specialization_workaround {
- template <>
- struct wait<thread> {
- static result_of::wait<thread>::type apply( thread& act) {
- return act.join();
- }
- };
-
- template <>
- struct wait_until<thread> {
- static result_of::wait_until<thread>::type apply( thread& act, const system_time& abs_time ) {
- return act.timed_join(abs_time);
- }
- };
- template <typename Duration>
- struct wait_for<thread, Duration> {
- static typename result_of::template wait_for<thread,Duration>::type apply( thread& act, Duration abs_time ) {
- return act.timed_join(abs_time);
- }
- };
-
- template <>
- struct join_until<thread> {
- static result_of::join_until<thread>::type apply( thread& act, const system_time& abs_time ) {
- return act.timed_join(abs_time);
- }
- };
- template <typename Duration>
- struct join_for<thread, Duration> {
- static typename result_of::template join_for<thread,Duration>::type apply( thread& act, Duration abs_time ) {
- return act.timed_join(abs_time);
- }
- };
- }
-
- }}
-
-[endsect]
-

Deleted: sandbox/interthreads/libs/interthreads/doc/reference/basic_threader_decorator.qbk
==============================================================================
--- sandbox/interthreads/libs/interthreads/doc/reference/basic_threader_decorator.qbk 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
+++ (empty file)
@@ -1,19 +0,0 @@
-[/
- (C) Copyright 2008-2009 Vicente J. Botet Escriba
- Distributed under the Boost Software License, Version 1.0.
- (See accompanying file LICENSE_1_0.txt or copy at
- http://www.boost.org/LICENSE_1_0.txt).
-]
-
-[/==========================================================================================]
-[section:basic_threader_decorator_hpp Header `<boost/interthreads/basic_threader_decorator.hpp>`]
-[/==========================================================================================]
-
-Shorter name for an __asynchronous_executor_decorator__ based on __basic_threader__ and decorated with the __thread_decorator__ .
-
- namespace boost { namespace interthreads {
- typedef asynchronous_executor_decorator<basic_threader,thread_decorator> basic_threader_decorator;
- }}
-
-[endsect]
-

Deleted: sandbox/interthreads/libs/interthreads/doc/reference/detach.qbk
==============================================================================
--- sandbox/interthreads/libs/interthreads/doc/reference/detach.qbk 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
+++ (empty file)
@@ -1,41 +0,0 @@
-[/
- (C) Copyright 2008-2009 Vicente J. Botet Escriba
- Distributed under the Boost Software License, Version 1.0.
- (See accompanying file LICENSE_1_0.txt or copy at
- http://www.boost.org/LICENSE_1_0.txt).
-]
-
-[/==========================================================================================]
-[section:detach_hpp Header `<boost/interthreads/algorithm/detach.hpp>`]
-[/==========================================================================================]
-
-Defines a free function __detach__ which __detach__ the __ACT__ passed as parameter.
-The default implementation applies the __detach__ member function to the __ACT__. A user adapting another __ACT__ could need
-to specialize the __detach__ free function if the __ACT__ do not provides a detach function with the same prototype.
-
-As for the moment we can not partially specialize a function a trick is used: instead of calling directly to the __detach__
-member function detach calls to the static operation apply on a class with the same name in the namespace __partial_specialization_workaround__.
-So the user can specialize partially this class.
-
-The template parameter ACT must be a model of __ThreadBasedACT__.
-
- namespace boost { namespace interthreads {
- namespace result_of {
- template <typename ACT> struct detach {
- typedef void type;
- };
- }
-
- namespace partial_specialization_workaround {
- template <typename ACT> struct detach {
- static typename result_of::detach<ACT>::type apply( ACT& act );
- };
- }
-
- template <typename ACT>
- typename boost::enable_if<has_thread_if<ACT>,void>::type
- detach(ACT& act);
- }}
-
-[endsect]
-

Deleted: sandbox/interthreads/libs/interthreads/doc/reference/detach_all.qbk
==============================================================================
--- sandbox/interthreads/libs/interthreads/doc/reference/detach_all.qbk 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
+++ (empty file)
@@ -1,35 +0,0 @@
-[/
- (C) Copyright 2008-2009 Vicente J. Botet Escriba
- Distributed under the Boost Software License, Version 1.0.
- (See accompanying file LICENSE_1_0.txt or copy at
- http://www.boost.org/LICENSE_1_0.txt).
-]
-
-[/==========================================================================================]
-[section:detach_all_hpp Header `<boost/interthreads/algorithm/detach_all.hpp>`]
-[/==========================================================================================]
-
-Defines a free function __detach_all__ which detach all the __ACT__ in the sequence passed as parameter.
-
- namespace boost { namespace interthreads {
- namespace fct {
- struct detach {
- typedef void result_type;
- template<typename ACT>
- void operator()(ACT& act) const;
- };
- }
-
- namespace result_of {
- template <typename Sequence>
- struct detach_all {
- typedef typename fusion::result_of::for_each<Sequence, fct::detach>::type type;
- };
- }
-
- template <typename Sequence>
- void detach_all(Sequence& t);
- }}
-
-[endsect]
-

Deleted: sandbox/interthreads/libs/interthreads/doc/reference/fork.qbk
==============================================================================
--- sandbox/interthreads/libs/interthreads/doc/reference/fork.qbk 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
+++ (empty file)
@@ -1,118 +0,0 @@
-[/
- (C) Copyright 2008-2009 Vicente J. Botet Escriba
- Distributed under the Boost Software License, Version 1.0.
- (See accompanying file LICENSE_1_0.txt or copy at
- http://www.boost.org/LICENSE_1_0.txt).
-]
-
-[/==========================================================================================]
-[section:fork_hpp Header `<boost/interthreads/fork.hpp>`]
-[/==========================================================================================]
-
- namespace boost { namespace interthreads {
- namespace result_of {
- template <typename AE, typename F, typename A1, ..., typename An>
- struct fork;
- typedef typename AE::handle<typename result_of<F(A1, ..., An)> >::type type;
- };
- }
-
- template< typename AE, typename F, typename A1, ..., typename An >
- typename asynchronous_completion_token<AE,
- typename boost::result_of<F(A1,..., An)>::type >::type
- fork( AE& ae, F fn, A1 a1, ..., An an );
-
-
- template< typename F, typename A1, ..., typename An >
- typename asynchronous_completion_token<default_asynchronous_executor,
- typename boost::result_of<F(A1,..., An)>::type >::type
- fork( F fn, A1 a1, ..., An an );
- }}
-
-[section Metafunction `result_of::fork<AE,F> `]
-[/==========================================================================================]
-
-A metafunction returning the result type of applying __fork__ to an asynchronous executor and a Nullary functor.
-
- namespace result_of {
- template <typename AE, typename F, typename A1, ..., typename An>
- struct fork;
- typedef typename AE::handle<typename result_of<F(A1, ..., An)> >::type type;
- };
- }
-
-[table fork Parameters
- [
- [[*Parameter]]
- [[*Requirement]]
- [[*Description]]
- ]
- [
- [`AE`]
- [A model of __AsynchronousExecutor__]
- [Operation's argument ]
- ]
- [
- [`F`]
- [A model of n-ary function]
- [Operation's argument ]
- ]
- [
- [`Ak`]
- [A model of n-ary function]
- [n-ary function argument type for argument k]
- ]
-]
-
-[variablelist
-[[Expression:] [result_of::fork<AE,F,A1,...,An>::type]]
-[[Return type:] [AE::handle<typename result_of<F(A1,...,An)> >::type]]
-]
-
-[endsect]
-
-[section Non member function `fork()`]
-[/==========================================================================================]
-
- template< typename AE, typename F, typename A1 , ... typename An >
- typename result_of::fork<AE,F, A1, An> >::type> >::type
- fork( AE& ae, F fn, A1 a1 , ..., An an );
-
-[table fork Parameters
- [
- [[*Parameter]]
- [[*Requirement]]
- [[*Description]]
- ]
- [
- [`AE`]
- [A model of __AsynchronousExecutor__]
- [Operation's argument ]
- ]
- [
- [`F`]
- [A model of n-ary function]
- [Operation's argument ]
- ]
- [
- [`Ak`]
- [A model of n-ary function]
- [n-ary function argument type for argument k]
- ]
-]
-
-[variablelist
-[[Requires:] [The expression fn(a1, ..., an) must be valid and
-have a type convertible to R, where R is typename result_of<F(A1, ..., An)>::type..]]
-
-[[Efect:] [Request the `AE` to creates a thread of execution for the function `fn`
-Request the asynchronous evaluation the expression `fn(a1, ..., an)` with respect to the calling thread to the
-asynchronous executor `ae` and
-places its result in an object h of type AE::handle<R>::type as if by using h.set_value( fn(a1, ..., an) ).
-If the expression fn() throws an exception e, places e into h as if by using
-h.set_exception( current_exception() ).]]
-
-[[Returns:] [the AE handle h.]]
-]
-[endsect]
-[endsect]

Deleted: sandbox/interthreads/libs/interthreads/doc/reference/fork_after.qbk
==============================================================================
--- sandbox/interthreads/libs/interthreads/doc/reference/fork_after.qbk 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
+++ (empty file)
@@ -1,265 +0,0 @@
-[/
- (C) Copyright 2008-2009 Vicente J. Botet Escriba
- Distributed under the Boost Software License, Version 1.0.
- (See accompanying file LICENSE_1_0.txt or copy at
- http://www.boost.org/LICENSE_1_0.txt).
-]
-
-[/==========================================================================================]
-[section:fork_after_hpp Header `<boost/interthreads/fork_after.hpp>`]
-[/==========================================================================================]
-
-Defines a free function __fork_after__ which request the asynchronous evaluation a function with respect to
-the calling thread to the asynchronous executor `ae` after the completion of some __ACT__. The result is an __ACT__ wrapping the __ACT__ associated to the __AE__.
-
-The default implementation forks a helper task which waits the completion of the __ACT__ 's only then evaluates the function.
-A user adapting another __AE__ could want to specialize the __fork_after__ free function.
-As for the moment we can not partially specialize a function a trick is used: instead of calling directly to the __fork_after__
-member function __fork_after__ calls to the static operation __apply__ on a class with the same name in the namespace __partial_specialization_workaround__.
-So the user can specialize partially this class.
-
- namespace boost { namespace interthreads {
- template <typename ACT>
- struct act_traits<act_wrapper<ACT> >;
-
- template <typename ACT>
- struct is_movable<act_wrapper<ACT> > : is_movable<ACT>{};
-
- template <typename ACT>
- struct has_future_if<act_wrapper<ACT> > : has_future_if<ACT> {};
-
- template <typename ACT>
- struct has_thread_if<act_wrapper<ACT> > : has_thread_if<ACT>{};
-
- template <typename ACT>
- struct act_wrapper;
-
- namespace result_of {
- template <typename AE,typename F>
- struct fork_after {
- typedef act_wrapper<typename asynchronous_completion_token<AE, typename boost::result_of<F()>::type>::type> type;
- };
- }
-
- namespace partial_specialization_workaround {
- template< typename AE, typename F, typename D >
- struct fork_after {
- static typename result_of::fork_after<AE,F>::type
- apply(AE& ae, F fn, D& d);
- };
- }
-
- template< typename AE, typename F, typename D>
- typename result_of::fork_after<AE,F>::type
- fork_after( AE& ae, F fn, D& d);
-
- template< typename AE, typename D, typename F, typename A1, ..., typename An >
- act_wrapper< typename asynchronous_completion_token<AE, typename boost::result_of<F(A1,..., An)>::type >::type >
- after_completion_fork( AE& ae, D& d, F fn, A1 a1, ..., An an );
-
-
- }}
-
-[/==================================================]
-[section Partial Specialization Template Class `act_traits<act_wrapper<ACT>>`]
-[/==========================================================================================]
-
-act_wrapper inherits the traits of its wrapped __ACT__.
-
- template <typename ACT>
- struct act_traits<act_wrapper<ACT> > : act_traits<ACT>{};
-
-[endsect]
-
-[/==================================================]
-[section Partial Specialization Template Class `is_movable<act_wrapper<ACT> >`]
-[/==========================================================================================]
-
-act_wrapper inherits the traits of its wrapped __ACT__.
-
- template <typename ACT>
- struct is_movable<act_wrapper<ACT> > : is_movable<ACT>{};
-
-[endsect]
-
-[/==================================================]
-[section Template Class `act_wrapper<>`]
-[/==========================================================================================]
-
- template <typename ACT>
- struct act_wrapper {
- typedef typename act_traits<act_wrapper<ACT> >::move_dest_type move_dest_type;
- act_wrapper();
- void wait_initialized();
- void set(ACT& other);
- void set(boost::detail::thread_move_t<ACT> other);
-
- void wait();
- bool wait_until(const system_time& abs_time);
- template <typename Duration>
- bool wait_for(ACT& act, Duration rel_time);
- move_dest_type get();
- bool is_ready();
- bool has_value();
- bool has_exception();
-
- void detach();
- bool joinable();
- void join();
- bool join_until(const system_time& abs_time);
- template <typename Duration>
- bool join_for(ACT& act, Duration rel_time);
- void interrupt();
- bool interruption_requested();
- };
-
-
-[endsect]
-
-[section Metafunction `result_of::fork<AE,F> `]
-[/==========================================================================================]
-
-A metafunction returning the result type of applying __fork_after__ to an asynchronous executor and a Nullary functor.
-
- namespace result_of {
- template <typename AE,typename F>
- struct fork_after {
- typedef act_wrapper<typename asynchronous_completion_token<AE, typename boost::result_of<F()>::type>::type> type;
- };
- }
-
-[table fork Parameters
- [
- [[*Parameter]]
- [[*Requirement]]
- [[*Description]]
- ]
- [
- [`AE`]
- [A model of __AsynchronousExecutor__]
- [Operation's argument ]
- ]
- [
- [`F`]
- [A model of n-ary function]
- [Operation's argument ]
- ]
-]
-
-[variablelist
-[[Expression:] [result_of::fork_after<AE,F>::type]]
-[[Return type:] [act_wrapper<typename asynchronous_completion_token<AE, typename boost::result_of<F()>::type>::type>]]
-]
-
-[endsect]
-
-[section Static Member Function `partial_specialization_workaround::fork_after<>::apply()`]
-[/==========================================================================================]
-
- namespace partial_specialization_workaround {
- template< typename AE, typename F, typename D >
- struct fork_after {
- static typename result_of::fork_after<AE,F>::type
- apply(AE& ae, F fn, D& d);
- };
- }
-
-[endsect]
-
-[section Non member function `fork_after()`]
-[/==========================================================================================]
-
- template< typename AE, typename F, typename D>
- typename result_of::fork_after<AE,F,D>::type
- fork_after( AE& ae, F fn, D& d);
-
-[table fork Parameters
- [
- [[*Parameter]]
- [[*Requirement]]
- [[*Description]]
- ]
- [
- [`AE`]
- [A model of __AsynchronousExecutor__]
- [Operation's argument ]
- ]
- [
- [`F`]
- [A model of n-ary function]
- [Operation's argument ]
- ]
- [
- [`D`]
- [A model of a fusion __Sequence__ of __ACT__]
- [Dependent __ACT__ ]
- ]
-]
-
-[variablelist
-[[Requires:] [The expression fn() must be valid and
-have a type convertible to R, where R is typename result_of<F()>::type..]]
-
-[[Efect:] [Request the asynchronous evaluation the expression `fn()` with respect to the calling thread to the
-asynchronous executor `ae` after the completion of all the __ACT__ in `d` and
-places its result in an object h of type AE::handle<R>::type as if by using h.set_value( fn() ).
-If the expression fn() throws an exception e, places e into h as if by using
-h.set_exception( current_exception() ).]]
-
-[[Returns:] [the AE handle h.]]
-]
-
-[endsect]
-
-[section Non member function `after_completion_fork()`]
-[/==========================================================================================]
-
- template< typename AE, typename D, typename F, typename A1, ..., typename An >
- act_wrapper< typename asynchronous_completion_token<AE, typename boost::result_of<F(A1,..., An)>::type >::type >
- after_completion_fork( AE& ae, D& d, F fn, A1 a1, ..., An an );
-
-[table fork Parameters
- [
- [[*Parameter]]
- [[*Requirement]]
- [[*Description]]
- ]
- [
- [`AE`]
- [A model of __AsynchronousExecutor__]
- [Operation's argument ]
- ]
- [
- [`D`]
- [A model of a fusion __Sequence__ of __ACT__]
- [Dependent __ACT__ ]
- ]
- [
- [`F`]
- [A model of n-ary function]
- [Operation's argument ]
- ]
- [
- [`Ak`]
- [A model of n-ary function]
- [n-ary function argument type for argument k]
- ]
-]
-
-[variablelist
-[[Requires:] [The expression fn(a1, ..., an) must be valid and
-have a type convertible to R, where R is typename result_of<Fn()>::type..]]
-
-[[Efect:] [Request the `AE` to creates a thread of execution for the function `fn`
-Request the asynchronous evaluation the expression `fn(a1, ..., an)` with respect to the calling thread to the
-asynchronous executor `ae` after the completion of all the __ACT__ in `d` and
-places its result in an object h of type AE::handle<R>::type as if by using h.set_value( fn(a1, ..., an) ).
-If the expression fn() throws an exception e, places e into h as if by using
-h.set_exception( current_exception() ).]]
-
-[[Returns:] [the AE handle h.]]
-]
-
-[endsect]
-[endsect]
-

Deleted: sandbox/interthreads/libs/interthreads/doc/reference/fork_all.qbk
==============================================================================
--- sandbox/interthreads/libs/interthreads/doc/reference/fork_all.qbk 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
+++ (empty file)
@@ -1,117 +0,0 @@
-[/
- (C) Copyright 2008-2009 Vicente J. Botet Escriba
- Distributed under the Boost Software License, Version 1.0.
- (See accompanying file LICENSE_1_0.txt or copy at
- http://www.boost.org/LICENSE_1_0.txt).
-]
-
-[/==========================================================================================]
-[section:fork_all_hpp Header `<boost/interthreads/fork_all.hpp>`]
-[/==========================================================================================]
-
- namespace boost { namespace interthreads {
- namespace result_of {
- template <typename AE, typename T>
- struct fork_all;
- template <typename AE, typename F1, ..., typename Fn>
- struct fork_all <AE,fusion::tuple<F1, ..., Fn> >{
- typedef fusion::tuple<
- typename result_of::fork<AE,F1>::type,
- ...
- typename result_of::fork<AE,Fn>::type
- > type;
- };
- }
-
- template< typename AE, typename F1, ..., typename Fn>
- typename result_of::fork_all<AE, mpl::tuple<F1, ..., Fn> >::type
- fork_all( AE& ae, F1 f1, ..., Fn fn );
-
- template< typename F1, ..., typename Fn>
- typename result_of::fork_all<default_asynchronous_executor, F1, ..., Fn>::type
- fork_all( F1 f1, ..., Fn fn );
- }}
-
-[section Metafunction `result_of::fork_all<AE,F1, ..., Fn> `]
-[/==========================================================================================]
-
-A metafunction returning the result type of applying fork_all to an asynchronous executor and n Nullary functors.
-
- namespace result_of {
- template <typename AE, typename T>
- struct fork_all;
- template <typename AE, typename F1, ..., typename Fn>
- struct fork_all <AE,fusion::tuple<F1, ..., Fn> >{
- typedef fusion::tuple<
- typename result_of::fork<AE,F1>::type,
- ...
- typename result_of::fork<AE,Fn>::type
- > type;
- };
- }
-
-[table fork_all Parameters
- [
- [[*Parameter]]
- [[*Requirement]]
- [[*Description]]
- ]
- [
- [`AE`]
- [A model of `AsynchrousExecutor`]
- [Operation's argument ]
- ]
- [
- [`Fk`]
- [A model of nullary function]
- [Operation's argument ]
- ]
-]
-
-[variablelist
-[[Expression:] [`result_of::fork_all<AE,F1,...,Fn>::type`]]
-[[Return type:] [a fusion tuple of the result of forking each `Fk` by the `AE`]]
-]
-
-[endsect]
-
-[section Non member function `fork_all()`]
-[/==========================================================================================]
-
- template< typename AE, typename F1, ..., typename Fn>
- typename result_of::fork_all<AE, mpl::tuple<F1, ..., Fn> >::type
- fork_all( AE& ae, F1 f1, ..., Fn fn );
-
- template< typename F1, ..., typename Fn>
- typename result_of::fork_all<default_asynchronous_executor, F1, ..., Fn>::type
- fork_all( F1 f1, ..., Fn fn );
-
-[table fork Parameters
- [
- [[*Parameter]]
- [[*Requirement]]
- [[*Description]]
- ]
- [
- [`AE`]
- [A model of `AsynchrousExecutor`]
- [Operation's argument ]
- ]
- [
- [`Fk`]
- [A model of nullary function]
- [Operation's argument ]
- ]
-]
-
-[variablelist
-[[Returns:] [a fusion tuple of the result of forking each `fk` by the `ae`]]
-[[Efect:] [Request the `AE` to creates a n thread of execution one for the function `fk`.]]
-]
-
-[endsect]
-
-
-[endsect]
-
-

Deleted: sandbox/interthreads/libs/interthreads/doc/reference/get.qbk
==============================================================================
--- sandbox/interthreads/libs/interthreads/doc/reference/get.qbk 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
+++ (empty file)
@@ -1,105 +0,0 @@
-[/
- (C) Copyright 2008-2009 Vicente J. Botet Escriba
- Distributed under the Boost Software License, Version 1.0.
- (See accompanying file LICENSE_1_0.txt or copy at
- http://www.boost.org/LICENSE_1_0.txt).
-]
-
-[/==========================================================================================]
-[section:get_hpp Header `<boost/interthreads/algorithm/get.hpp>`]
-[/==========================================================================================]
-
-Defines a free function __get__ which obtain the stored value on the __ACT__ passed as parameter.
-The default implementation applies the __get__ member function to the __ACT__. A user adapting another __ACT__ could need
-to specialize the __get__ free function if the __ACT__ do not provides a get function with the same prototype.
-As for the moment we can not partially specialize a function a trick is used: instead of calling directly to the __get__
-member function __get__ calls to the static operation __apply__ on a class with the same name in the namespace __partial_specialization_workaround__.
-So the user can specialize partially this class.
-
-The template parameter ACT must be a model of __FutureBasedACT__.
-
-
- namespace boost { namespace interthreads {
- namespace result_of {
- template <typename ACT> struct get {
- typedef typename act_traits<ACT>::move_dest_type type;
- };
- }
-
- namespace partial_specialization_workaround {
- template <typename ACT> struct get {
- static typename result_of::get<ACT>::type apply( ACT& act );
- };
- }
-
- template <typename ACT>
- typename boost::enable_if<has_future_if<ACT>,
- typename result_of::template get<ACT>::type
- >::type
- get(ACT& act);
- }}
-
-[section Metafunction `result_of::get<ACT> `]
-[/==========================================================================================]
-
-A metafunction returning the result type of applying get to an __ACT__.
-
- namespace result_of {
- template <typename ACT> struct get {
- typedef typename act_traits<ACT>::move_dest_type type;
- };
- }
-
-[table get Parameters
- [
- [[*Parameter]]
- [[*Requirement]]
- [[*Description]]
- ]
- [
- [`ACT`]
- [An __ACT__]
- [Operation's argument ]
- ]
-]
-
-[variablelist
-[[Expression:] [`result_of::get<S>::type`]]
-[[Returns:] [Depending on the nature of the ACT returns a `act_traits<ACT>::move_dest_type`.]]
-]
-
-[endsect]
-
-[section Static Member Function `partial_specialization_workaround::get<>::apply()`]
-[/==========================================================================================]
-
-The default implementation applies the 'get()' member function on the __ACT__.
-
- namespace partial_specialization_workaround {
- template <typename ACT> struct get {
- static typename result_of::get<ACT>::type apply( ACT& act );
- };
- }
-
-[endsect]
-
-[section Non member function `get()`]
-[/==========================================================================================]
-
- template <typename ACT>
- typename boost::enable_if<has_future_if<ACT>,
- typename result_of::template get<ACT>::type
- >::type
- get(ACT& act);
-
-
-[variablelist
-[[Returns:] [a fusion tuple of the result of applying `get` to each one of the asynchronous completion token handles in the sequence.]]
-[[Effect:] [Blocks until all the ACT handles in the Sequence are ready.]]
-[[Throws:] [if some of the ACT::get operation throws]]
-]
-
-[endsect]
-
-[endsect]
-

Deleted: sandbox/interthreads/libs/interthreads/doc/reference/get_all.qbk
==============================================================================
--- sandbox/interthreads/libs/interthreads/doc/reference/get_all.qbk 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
+++ (empty file)
@@ -1,101 +0,0 @@
-[/
- (C) Copyright 2008-2009 Vicente J. Botet Escriba
- Distributed under the Boost Software License, Version 1.0.
- (See accompanying file LICENSE_1_0.txt or copy at
- http://www.boost.org/LICENSE_1_0.txt).
-]
-
-[/==========================================================================================]
-[section:get_all_hpp Header `<boost/interthreads/algorithm/get_all.hpp>`]
-[/==========================================================================================]
-
-Defines a free function __get_all__ which waits the completion of all the __ACT__ in the sequence passed as parameter, and returns a tuple with the value stores in each one of the __ACT__.
-
- namespace boost { namespace interthreads {
- namespace fct {
- struct get {
- template<typename T>
- typename T::result_type operator()(T& t);
- };
- }
- namespace result_of {
- template <typename Sequence>
- struct get_all {
- typedef typename result_of::transform<Sequence, fct::get>::type type;
- };
- }
- template <typename Sequence>
- typename result_of::get_all<Sequence>::type
- get_all(Sequence& mt);
- }}
-
-[section Functor `fct::get<>`]
-[/==========================================================================================]
-
- namespace fct {
- struct get {
- template<typename AE>
- typename AE::result_type operator()(AE& ae);
- };
- }
-
-
-[variablelist
-[[Returns:] [The result of the AE::get().]]
-[[Throws:] [if AE::get() throws.]]
-]
-
-[endsect]
-
-[section Metafunction `result_of::get_all<AE,F1, ..., Fn> `]
-[/==========================================================================================]
-
-A metafunction returning the result type of applying get_all to a Sequence of __ACT__.
-
- namespace result_of {
- template <typename Sequence>
- struct get_all {
- typedef typename result_of::transform<Sequence, fct::get>::type type;
- };
- }
-
-[table fork_all Parameters
- [
- [[*Parameter]]
- [[*Requirement]]
- [[*Description]]
- ]
- [
- [`Sequence`]
- [A sequence of of __ACTs__]
- [Operation's argument ]
- ]
-]
-
-[variablelist
-[[Expression:] [`result_of::get_all<S>::type`]]
-[[Return type:] [a fusion tuple of the result of applying get to each one of the asynchronous executors in the sequence]]
-]
-
-[endsect]
-
-[section Non member function `get_all`]
-[/==========================================================================================]
-
- namespace algo {
- template <typename Sequence>
- typename result_of::get_all<Sequence>::type
- get_all(Sequence& mt);
- }
-
-
-[variablelist
-[[Returns:] [a fusion tuple of the result of applying `get` to each one of the asynchronous completion token handles in the sequence.]]
-[[Effect:] [Blocks until all the ACT handles in the Sequence are ready.]]
-[[Throws:] [if some of the ACT::get operation throws]]
-]
-
-[endsect]
-
-[endsect]
-

Deleted: sandbox/interthreads/libs/interthreads/doc/reference/has_exception.qbk
==============================================================================
--- sandbox/interthreads/libs/interthreads/doc/reference/has_exception.qbk 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
+++ (empty file)
@@ -1,42 +0,0 @@
-[/
- (C) Copyright 2008-2009 Vicente J. Botet Escriba
- Distributed under the Boost Software License, Version 1.0.
- (See accompanying file LICENSE_1_0.txt or copy at
- http://www.boost.org/LICENSE_1_0.txt).
-]
-
-[/==========================================================================================]
-[section:has_exception_hpp Header `<boost/interthreads/algorithm/has_exception.hpp>`]
-[/==========================================================================================]
-
-Defines a free function __has_exception__ which states if __ACT__ passed as parameter has an exception.
-The default implementation applies the __has_exception__ member function to the __ACT__. A user adapting another __ACT__ could need
-to specialize the __has_exception__ free function if the __ACT__ do not provides a has_exception function with the same prototype.
-
-As for the moment we can not partially specialize a function a trick is used: instead of calling directly to the __has_exception__
-member function __has_exception__ calls to the static operation __apply__ on a class with the same name in the namespace __partial_specialization_workaround__.
-So the user can specialize partially this class.
-
-The template parameter ACT must be a model of __FutureBasedACT__.
-
- namespace boost { namespace interthreads {
-
- namespace fct {
- struct has_exception {
- typedef bool result_type;
- template<typename ACT> bool operator()(ACT& act) const;
- };
- }
-
- namespace result_of {
- template <typename Sequence> struct have_all_exception {
- typedef typename fusion::result_of::all<Sequence, fct::has_exception>::type type;
- };
- }
-
- template <typename Sequence> bool have_all_exception(Sequence& t);
-
- }}
-
-[endsect]
-

Deleted: sandbox/interthreads/libs/interthreads/doc/reference/has_value.qbk
==============================================================================
--- sandbox/interthreads/libs/interthreads/doc/reference/has_value.qbk 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
+++ (empty file)
@@ -1,45 +0,0 @@
-[/
- (C) Copyright 2008-2009 Vicente J. Botet Escriba
- Distributed under the Boost Software License, Version 1.0.
- (See accompanying file LICENSE_1_0.txt or copy at
- http://www.boost.org/LICENSE_1_0.txt).
-]
-
-[/==========================================================================================]
-[section:has_value_hpp Header `<boost/interthreads/algorithm/has_value.hpp>`]
-[/==========================================================================================]
-
-Defines a free function __has_value__ which states if __ACT__ passed as parameter has a value.
-The default implementation applies the __has_value__ member function to the __ACT__. A user adapting another __ACT__ could need
-to specialize the __has_value__ free function if the __ACT__ do not provides a has_value function with the same prototype.
-
-As for the moment we can not partially specialize a function a trick is used: instead of calling directly to the __has_value__
-member function __has_value__ calls to the static operation __apply__ on a class with the same name in the namespace __partial_specialization_workaround__.
-So the user can specialize partially this class.
-
-The template parameter ACT must be a model of __FutureBasedACT__.
-
-
- namespace boost { namespace interthreads {
-
- namespace result_of {
- template <typename ACT> struct has_value {
- typedef bool type;
- };
- }
-
- namespace partial_specialization_workaround {
- template <typename ACT> struct has_value {
- static typename result_of::has_value<ACT>::type apply( ACT& act );
- };
- }
-
- template <typename ACT>
- typename boost::enable_if<has_future_if<ACT>,
- typename result_of::template is_ready<ACT>::type
- >::type has_value(ACT& act);
-
- }}
-
-[endsect]
-

Deleted: sandbox/interthreads/libs/interthreads/doc/reference/have_all_exception.qbk
==============================================================================
--- sandbox/interthreads/libs/interthreads/doc/reference/have_all_exception.qbk 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
+++ (empty file)
@@ -1,33 +0,0 @@
-[/
- (C) Copyright 2008-2009 Vicente J. Botet Escriba
- Distributed under the Boost Software License, Version 1.0.
- (See accompanying file LICENSE_1_0.txt or copy at
- http://www.boost.org/LICENSE_1_0.txt).
-]
-
-[/==========================================================================================]
-[section:have_all_exception_hpp Header `<boost/interthreads/algorithm/have_some_exception.hpp>`]
-[/==========================================================================================]
-
-Defines a free function __have_some_exception__ which states if some of the __ACT__ in a sequence of __ACT__ have a exception stored.
-The current implementation applies the __has_exception__ free function for each __ACT__.
-
- namespace boost { namespace interthreads {
- namespace fct {
- struct has_exception {
- typedef bool result_type;
- template<typename ACT> bool operator()(ACT& act) const;
- };
- }
-
- namespace result_of {
- template <typename Sequence> struct have_some_exception {
- typedef typename fusion::result_of::all<Sequence, fct::has_exception>::type type;
- };
- }
-
- template <typename Sequence> bool have_some_exception(Sequence& t);
- }}
-
-[endsect]
-

Deleted: sandbox/interthreads/libs/interthreads/doc/reference/have_all_value.qbk
==============================================================================
--- sandbox/interthreads/libs/interthreads/doc/reference/have_all_value.qbk 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
+++ (empty file)
@@ -1,33 +0,0 @@
-[/
- (C) Copyright 2008-2009 Vicente J. Botet Escriba
- Distributed under the Boost Software License, Version 1.0.
- (See accompanying file LICENSE_1_0.txt or copy at
- http://www.boost.org/LICENSE_1_0.txt).
-]
-
-[/==========================================================================================]
-[section:have_all_value_hpp Header `<boost/interthreads/algorithm/have_all_value.hpp>`]
-[/==========================================================================================]
-
-Defines a free function __have_all_value__ which states if all the __ACT__ in a sequence of __ACT__ have a value.
-The current implementation applies the __has_value__ free function for each __ACT__.
-
- namespace boost { namespace interthreads {
- namespace fct {
- struct has_value {
- typedef bool result_type;
- template<typename ACT> bool operator()(ACT& act) const;
- };
- }
-
- namespace result_of {
- template <typename Sequence> struct have_all_value {
- typedef typename fusion::result_of::all<Sequence, fct::has_value>::type type;
- };
- }
-
- template <typename Sequence> bool have_all_value(Sequence& t);
- }}
-
-[endsect]
-

Deleted: sandbox/interthreads/libs/interthreads/doc/reference/interrupt.qbk
==============================================================================
--- sandbox/interthreads/libs/interthreads/doc/reference/interrupt.qbk 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
+++ (empty file)
@@ -1,43 +0,0 @@
-[/
- (C) Copyright 2008-2009 Vicente J. Botet Escriba
- Distributed under the Boost Software License, Version 1.0.
- (See accompanying file LICENSE_1_0.txt or copy at
- http://www.boost.org/LICENSE_1_0.txt).
-]
-
-[/==========================================================================================]
-[section:interrupt_hpp Header `<boost/interthreads/algorithm/interrupt.hpp>`]
-[/==========================================================================================]
-
-Defines a free function __interrupt__ which interrupts the __ACT__ passed as parameter.
-The default implementation applies the __interrupt__ member function to the __ACT__. A user adapting another __ACT__ could need
-to specialize the __interrupt__ free function if the __ACT__ do not provides a interrupt function with the same prototype.
-
-As for the moment we can not partially specialize a function a trick is used: instead of calling directly to the __interrupt__
-member function interrupt calls to the static operation apply on a class with the same name in the namespace __partial_specialization_workaround__.
-So the user can specialize partially this class.
-
-The template parameter ACT must be a model of __ThreadBasedACT__.
-
- namespace boost { namespace interthreads {
- namespace result_of {
- template <typename ACT> struct interrupt {
- typedef void type;
- };
- }
-
- namespace partial_specialization_workaround {
- template <typename ACT> struct interrupt {
- static typename result_of::template interrupt<ACT>::type apply( ACT& act );
- };
- }
-
- template <typename ACT>
- typename boost::enable_if<has_thread_if<ACT>,
- void
- >::type interrupt(ACT& act)
- }}
-
-
-[endsect]
-

Deleted: sandbox/interthreads/libs/interthreads/doc/reference/interrupt_all.qbk
==============================================================================
--- sandbox/interthreads/libs/interthreads/doc/reference/interrupt_all.qbk 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
+++ (empty file)
@@ -1,35 +0,0 @@
-[/
- (C) Copyright 2008-2009 Vicente J. Botet Escriba
- Distributed under the Boost Software License, Version 1.0.
- (See accompanying file LICENSE_1_0.txt or copy at
- http://www.boost.org/LICENSE_1_0.txt).
-]
-
-[/==========================================================================================]
-[section:interrupt_all_hpp Header `<boost/interthreads/algorithm/interrupt_all.hpp>`]
-[/==========================================================================================]
-
-Defines a free function __interrupt_all__ which interrupts all the __ACT__ in the sequence passed as parameter.
-
- namespace boost { namespace interthreads {
- namespace fct {
- struct interrupt {
- template<typename ACT>
- void operator()(ACT& act) const;
- };
- }
-
- namespace result_of {
- template <typename Sequence>
- struct interrupt_all {
- typedef typename fusion::result_of::for_each<Sequence, fct::interrupt>::type type;
- };
- }
-
- template <typename Sequence>
- void interrupt_all(Sequence& t);
- }}
-
-
-[endsect]
-

Deleted: sandbox/interthreads/libs/interthreads/doc/reference/interruption_requested.qbk
==============================================================================
--- sandbox/interthreads/libs/interthreads/doc/reference/interruption_requested.qbk 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
+++ (empty file)
@@ -1,43 +0,0 @@
-[/
- (C) Copyright 2008-2009 Vicente J. Botet Escriba
- Distributed under the Boost Software License, Version 1.0.
- (See accompanying file LICENSE_1_0.txt or copy at
- http://www.boost.org/LICENSE_1_0.txt).
-]
-
-[/==========================================================================================]
-[section:interruption_requested_hpp Header `<boost/interthreads/algorithm/interruption_requested.hpp>`]
-[/==========================================================================================]
-
-Defines a free function __interruption_requested__ which states if __ACT__ passed as parameter has received un __interrupt__ request.
-The default implementation applies the __interruption_requested__ member function to the __ACT__. A user adapting another __ACT__ could need
-to specialize the __interruption_requested__ free function if the __ACT__ do not provides a interruption_requested function with the same prototype.
-
-As for the moment we can not partially specialize a function a trick is used: instead of calling directly to the __interruption_requested__
-member function __interruption_requested__ calls to the static operation __apply__ on a class with the same name in the namespace __partial_specialization_workaround__.
-So the user can specialize partially this class.
-
-The template parameter ACT must be a model of __ThreadBasedACT__.
-
- namespace boost { namespace interthreads {
- namespace result_of {
- template <typename ACT> struct interruption_requested {
- typedef bool type;
- };
- }
-
- namespace partial_specialization_workaround {
- template <typename ACT> struct interruption_requested {
- static typename result_of::interruption_requested<ACT>::type apply( ACT& act );
- };
- }
-
- template <typename ACT>
- typename boost::enable_if<has_thread_if<ACT>,
- bool
- >::type
- bool interruption_requested(ACT& act);
- }}
-
-[endsect]
-

Deleted: sandbox/interthreads/libs/interthreads/doc/reference/interruption_requested_all.qbk
==============================================================================
--- sandbox/interthreads/libs/interthreads/doc/reference/interruption_requested_all.qbk 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
+++ (empty file)
@@ -1,36 +0,0 @@
-[/
- (C) Copyright 2008-2009 Vicente J. Botet Escriba
- Distributed under the Boost Software License, Version 1.0.
- (See accompanying file LICENSE_1_0.txt or copy at
- http://www.boost.org/LICENSE_1_0.txt).
-]
-
-[/==========================================================================================]
-[section:interruption_requested_on_all_hpp Header `<boost/interthreads/algorithm/interruption_requested_on_all.hpp>`]
-[/==========================================================================================]
-
-Defines a free function __interruption_requested_on_all__ which states if an interruption has been requested on all the __ACT__ in a sequence of __ACT__.
-
- namespace boost { namespace interthreads {
- namespace fct {
- struct interruption_requested {
- typedef bool result_type;
-
- template<typename ACT>
- bool operator()(ACT& act) const;
- };
- }
-
- namespace result_of {
- template <typename Sequence>
- struct interruption_requested_on_all {
- typedef typename fusion::result_of::all<Sequence, fct::interruption_requested>::type type;
- };
- }
-
- template <typename Sequence>
- bool interruption_requested_on_all(Sequence& t);
- }}
-
-[endsect]
-

Deleted: sandbox/interthreads/libs/interthreads/doc/reference/is_ready.qbk
==============================================================================
--- sandbox/interthreads/libs/interthreads/doc/reference/is_ready.qbk 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
+++ (empty file)
@@ -1,45 +0,0 @@
-[/
- (C) Copyright 2008-2009 Vicente J. Botet Escriba
- Distributed under the Boost Software License, Version 1.0.
- (See accompanying file LICENSE_1_0.txt or copy at
- http://www.boost.org/LICENSE_1_0.txt).
-]
-
-[/==========================================================================================]
-[section:is_ready_hpp Header `<boost/interthreads/algorithm/is_ready.hpp>`]
-[/==========================================================================================]
-
-Defines a free function __is_ready__ which states if __ACT__ passed as parameter is ready.
-The default implementation applies the __is_ready__ member function to the __ACT__. A user adapting another __ACT__ could need
-to specialize the __is_ready__ free function if the __ACT__ do not provides a is_ready function with the same prototype.
-
-As for the moment we can not partially specialize a function a trick is used: instead of calling directly to the __is_ready__
-member function __is_ready__ calls to the static operation __apply__ on a class with the same name in the namespace __partial_specialization_workaround__.
-So the user can specialize partially this class.
-
-The template parameter ACT must be a model of __FutureBasedACT__.
-
-
- namespace boost { namespace interthreads {
-
- namespace result_of {
- template <typename ACT> struct is_ready {
- typedef bool type;
- };
- }
-
- namespace partial_specialization_workaround {
- template <typename ACT> struct is_ready {
- static typename result_of::is_ready<ACT>::type apply( ACT& act );
- };
- }
-
- template <typename ACT>
- typename boost::enable_if<has_future_if<ACT>,
- typename result_of::template is_ready<ACT>::type
- >::type is_ready(ACT& act);
-
- }}
-
-[endsect]
-

Deleted: sandbox/interthreads/libs/interthreads/doc/reference/join.qbk
==============================================================================
--- sandbox/interthreads/libs/interthreads/doc/reference/join.qbk 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
+++ (empty file)
@@ -1,46 +0,0 @@
-[/
- (C) Copyright 2008-2009 Vicente J. Botet Escriba
- Distributed under the Boost Software License, Version 1.0.
- (See accompanying file LICENSE_1_0.txt or copy at
- http://www.boost.org/LICENSE_1_0.txt).
-]
-
-[/==========================================================================================]
-[section:join_hpp Header `<boost/interthreads/algorithm/join.hpp>`]
-[/==========================================================================================]
-
-Defines a free function __join__ which joins the __ACT__ passed as parameter.
-The default implementation applies the __join__ member function to the __ACT__. A user adapting another __ACT__ could need
-to specialize the __join__ free function if the __ACT__ do not provides a join function with the same prototype.
-
-As for the moment we can not partially specialize a function a trick is used: instead of calling directly to the __join__
-member function join calls to the static operation apply on a class with the same name in the namespace __partial_specialization_workaround__.
-So the user can specialize partially this class.
-
-The template parameter ACT must be a model of __ThreadBasedACT__.
-
-
- namespace boost { namespace interthreads {
- namespace result_of {
- template <typename ACT> struct join {
- typedef void type;
- };
- }
-
- namespace partial_specialization_workaround {
- template <typename ACT> struct join {
- static typename result_of::join<ACT>::type apply( ACT& act );
- };
- }
-
- template <typename ACT>
- typename boost::enable_if<has_thread_if<ACT>,
- typename result_of::join<ACT>::type
- >::type
- join(ACT& act) {
- return partial_specialization_workaround::join<ACT>::apply(act);
- }
- }}
-
-[endsect]
-

Deleted: sandbox/interthreads/libs/interthreads/doc/reference/join_all.qbk
==============================================================================
--- sandbox/interthreads/libs/interthreads/doc/reference/join_all.qbk 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
+++ (empty file)
@@ -1,36 +0,0 @@
-[/
- (C) Copyright 2008-2009 Vicente J. Botet Escriba
- Distributed under the Boost Software License, Version 1.0.
- (See accompanying file LICENSE_1_0.txt or copy at
- http://www.boost.org/LICENSE_1_0.txt).
-]
-
-[/==========================================================================================]
-[section:join_all_hpp Header `<boost/interthreads/algorithm/join_all.hpp>`]
-[/==========================================================================================]
-
-Defines a free function __join_all__ which waits the completion of all the __ACT__ in the sequence passed as parameter.
-
- namespace boost { namespace interthreads {
- namespace fct {
- struct join {
- typedef void result_type;
- template<typename ACT>
- void operator()(ACT& act) const;
- };
- }
-
- namespace result_of {
- template <typename Sequence>
- struct join_all {
- typedef typename fusion::result_of::for_each<Sequence, fct::join>::type type;
- };
- }
-
- template <typename Sequence>
- typename result_of::join_all<Sequence>::type
- join_all(Sequence& t);
- }}
-
-[endsect]
-

Deleted: sandbox/interthreads/libs/interthreads/doc/reference/join_all_until.qbk
==============================================================================
--- sandbox/interthreads/libs/interthreads/doc/reference/join_all_until.qbk 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
+++ (empty file)
@@ -1,51 +0,0 @@
-[/
- (C) Copyright 2008-2009 Vicente J. Botet Escriba
- Distributed under the Boost Software License, Version 1.0.
- (See accompanying file LICENSE_1_0.txt or copy at
- http://www.boost.org/LICENSE_1_0.txt).
-]
-
-[/==========================================================================================]
-[section:join_all_until_hpp Header `<boost/interthreads/algorithm/join_all_until.hpp>`]
-[/==========================================================================================]
-
-Defines a free function __join_all_until__ and __join_all_for__ which waits the completion of all the __ACT__ in the sequence passed as parameter or a given time is reached or elapsed respectiviely.
-
- namespace boost { namespace interthreads {
- namespace fct {
- struct join_until {
- join_until(const system_time& abs_time);
- template<typename ACT>
- bool operator()(ACT& act) const;
- };
-
- struct join_for {
- template <typename Duration>
- join_for(const Duration& rel_time);
- template<typename ACT>
- bool operator()(ACT& act) const;
- }
-
- namespace result_of {
- template <typename Sequence>
- struct join_all_until {
- typedef bool type;
- };
-
- template <typename Sequence>
- struct join_all_for {
- typedef bool type;
- };
- }
-
- template <typename Sequence>
- typename result_of::join_all_until<Sequence>
- join_all_until(Sequence& t, const system_time& abs_time);
-
- template <typename Sequence, typename Duration>
- typename result_of::join_all_for<Sequence>
- join_all_for(Sequence& t, const Duration& rel_time);
- }}
-
-[endsect]
-

Deleted: sandbox/interthreads/libs/interthreads/doc/reference/join_until.qbk
==============================================================================
--- sandbox/interthreads/libs/interthreads/doc/reference/join_until.qbk 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
+++ (empty file)
@@ -1,72 +0,0 @@
-[/
- (C) Copyright 2008-2009 Vicente J. Botet Escriba
- Distributed under the Boost Software License, Version 1.0.
- (See accompanying file LICENSE_1_0.txt or copy at
- http://www.boost.org/LICENSE_1_0.txt).
-]
-
-[/==========================================================================================]
-[section:join_until_hpp Header `<boost/interthreads/algorithm/join_until.hpp>`]
-[/==========================================================================================]
-
-Defines a free function __join_until__ which join until the __ACT__ passed as parameter is ready or the given time is reached.
-The default implementation applies the __join_until__ member function to the __ACT__. A user adapting another __ACT__ could need
-to specialize the __join_until__ free function if the __ACT__ do not provides a join_until function with the same prototype.
-
-As for the moment we can not partially specialize a function a trick is used: instead of calling directly to the __join_until__
-member function, __join_until__ calls to the static operation apply on a class with the same name in the namespace __partial_specialization_workaround__.
-So the user can specialize partially this class.
-
-Defines a free function __join_for__ which join until the __ACT__ passed as parameter is ready or the given time is elapsed.
-The default implementation applies the __join_for__ member function to the __ACT__. A user adapting another __ACT__ could need
-to specialize the __join_for__ free function if the __ACT__ do not provides a __join_for__ function with the same prototype.
-
-As for the moment we can not partially specialize a function a trick is used: instead of calling directly to the __join_until__
-member function, __join_for__ calls to the static operation apply on a class with the same name in the namespace __partial_specialization_workaround__.
-So the user can specialize partially this class.
-
-The template parameter ACT must be a model of __ThreadBasedACT__.
-
-
- namespace boost { namespace interthreads {
- namespace result_of {
- template <typename ACT> struct join_until {
- typedef bool type;
- };
- }
- namespace result_of {
- template <typename ACT, typename Duration> struct join_for {
- typedef bool type;
- };
- }
-
- namespace partial_specialization_workaround {
- template< typename ACT >
- struct join_until {
- static typename result_of::template join_until<ACT>::type apply( ACT& act, const system_time& abs_time );
- };
- template< typename ACT, typename Duration>
- struct join_for {
- static typename result_of::template join_for<ACT,Duration>::type apply( ACT& act, Duration abs_time );
- };
- }
-
- template <typename ACT>
- typename boost::enable_if<has_thread_if<ACT>,
- typename result_of::template join_until<ACT>::type
- >::type
- join_until(ACT& act, const system_time& abs_time) {
- return partial_specialization_workaround::join_until<ACT>::apply(act, abs_time);
- }
-
- template <typename ACT, typename Duration>
- typename boost::enable_if<has_thread_if<ACT>,
- typename result_of::template join_for<ACT,Duration>::type
- >::type
- join_for(ACT& act, const Duration& rel_time) {
- return partial_specialization_workaround::join_for<ACT,Duration>::apply(act, rel_time);
- }
- }}
-
-[endsect]
-

Deleted: sandbox/interthreads/libs/interthreads/doc/reference/joinable.qbk
==============================================================================
--- sandbox/interthreads/libs/interthreads/doc/reference/joinable.qbk 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
+++ (empty file)
@@ -1,41 +0,0 @@
-[/
- (C) Copyright 2008-2009 Vicente J. Botet Escriba
- Distributed under the Boost Software License, Version 1.0.
- (See accompanying file LICENSE_1_0.txt or copy at
- http://www.boost.org/LICENSE_1_0.txt).
-]
-
-[/==========================================================================================]
-[section:joinable_hpp Header `<boost/interthreads/algorithm/joinable.hpp>`]
-[/==========================================================================================]
-
-Defines a free function __joinable__ which states if __ACT__ passed as parameter is __joinable__.
-The default implementation applies the __joinable__ member function to the __ACT__. A user adapting another __ACT__ could need
-to specialize the __joinable__ free function if the __ACT__ do not provides a joinable function with the same prototype.
-
-As for the moment we can not partially specialize a function a trick is used: instead of calling directly to the __joinable__
-member function __joinable__ calls to the static operation __apply__ on a class with the same name in the namespace __partial_specialization_workaround__.
-So the user can specialize partially this class.
-
-The template parameter ACT must be a model of __ThreadBasedACT__.
-
- namespace boost { namespace interthreads {
- namespace result_of {
- template <typename ACT> struct joinable {
- typedef bool type;
- };
- }
-
- namespace partial_specialization_workaround {
- template< typename ACT> struct joinable {
- static typename result_of::template joinable<ACT>::type apply( ACT& act );
- };
- }
-
- template <typename ACT>
- typename boost::enable_if<has_thread_if<ACT>,
- typename result_of::template joinable<ACT>::type >::type joinable(ACT& act);
- }}
-
-[endsect]
-

Deleted: sandbox/interthreads/libs/interthreads/doc/reference/launcher.qbk
==============================================================================
--- sandbox/interthreads/libs/interthreads/doc/reference/launcher.qbk 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
+++ (empty file)
@@ -1,235 +0,0 @@
-[/
- (C) Copyright 2008-2009 Vicente J. Botet Escriba
- Distributed under the Boost Software License, Version 1.0.
- (See accompanying file LICENSE_1_0.txt or copy at
- http://www.boost.org/LICENSE_1_0.txt).
-]
-
-[/==========================================================================================]
-[section:launcher_hpp Header `<boost/interthreads/launcher.hpp>`]
-[/==========================================================================================]
-
-A launcher is an __AE__ with a future as __FutureBasedACT__ so we can get the value associated to it.
-
-The library defines two kind of launchers:
-unique_launcher and shared_launcher that respectively have a unique_future and a shared_future as __ACT__
-
- #include <boost/interthreads/fork.hpp>
- namespace boost { namespace interthreads {
- class launcher;
- class shared_launcher;
-
- namespace partial_specialization_workaround {
- template <typename R> struct join<unique_future<R> > {
- static typename result_of::template join<unique_future<R> >::type
- apply( unique_future<R>& act) {
- return act.wait();
- }
- };
- template <typename R> struct join<shared_future<R> > {
- static typename result_of::template join<shared_future<R> >::type
- apply( shared_future<R>& act) {
- return act.wait();
- }
- };
- template <typename R> struct join_until<unique_future<R> > {
- static typename result_of::template join_until<unique_future<R> >::type
- apply( unique_future<R>& act, const system_time& abs_time ) {
- return act.timed_wait_until(abs_time);
- }
- };
- template <typename R> struct join_until<shared_future<R> > {
- static typename result_of::template join_until<shared_future<R> >::type
- apply( shared_future<R>& act, const system_time& abs_time ) {
- return act.timed_wait_until(abs_time);
- }
- };
- template <typename R, typename Duration> struct join_for<unique_future<R>, Duration> {
- static typename result_of::template join_for<unique_future<R>,Duration>::type
- apply( unique_future<R>& act, Duration rel_time ) {
- return act.timed_wait(rel_time);
- }
- };
- template <typename R, typename Duration> struct join_for<shared_future<R>, Duration> {
- static typename result_of::template join_for<shared_future<R>,Duration>::type
- apply( shared_future<R>& act, Duration rel_time ) {
- return act.timed_wait(rel_time);
- }
- };
- template <typename R> struct wait_until<unique_future<R> > {
- static typename result_of::template wait_until<unique_future<R> >::type
- apply( unique_future<R>& act, const system_time& abs_time ) {
- return act.timed_wait_until(abs_time);
- }
- };
- template <typename R> struct wait_until<shared_future<R> > {
- static typename result_of::template wait_until<shared_future<R> >::type
- apply( shared_future<R>& act, const system_time& abs_time ) {
- return act.timed_wait_until(abs_time);
- }
- };
- template <typename R, typename Duration> struct wait_for<unique_future<R>, Duration> {
- static typename result_of::template wait_for<unique_future<R>,Duration>::type
- apply( unique_future<R>& act, Duration rel_time ) {
- return act.timed_wait(rel_time);
- }
- };
- template <typename R, typename Duration> struct wait_for<shared_future<R>, Duration> {
- static typename result_of::template wait_for<shared_future<R>,Duration>::type
- apply( shared_future<R>& act, Duration rel_time ) {
- return act.timed_wait(rel_time);
- }
- };
- }
-
- }}
-
-[section Class `launcher `]
-[/==========================================================================================]
-
-Thread launcher using a common configuration managed with the thread attributes and
-returning on the fork operation a unique_future to the resulting type of the call to the threaded function.
-
- class launcher {
- public:
- thread::native_handle_attr_type& attr();
-
- template <typename T>
- struct handle {
- typedef unique_future<T> > type;
- };
-
- template <typename F>
- unique_future<typename result_of<F()>::type>
- fork(F f);
- };
-
-[section Member function `launcher::attributes`]
-[/==========================================================================================]
-
-Reference to the thread attributes accesor.
-
- thread::native_handle_attr_type& attributes();
-
-[variablelist
-[[Returns:] [A reference to the thread attributes.]]
-[[Complexity:] [constant.]]
-]
-
-
-[endsect]
-[section Metafunction `launcher::handle<>`]
-[/==========================================================================================]
-
-Metafunction that returns the result type of the fork function applied to a launcher and the value type.
-
- template <typename T>
- struct handle {
- typedef unique_future<T> > type;
- };
-
-[variablelist
-[[Expression:] [L::handle<T>::type]]
-[[Return type:] [A unique_future<T>.]]
-[[Complexity:] [constant.]]
-
-]
-
-[endsect]
-
-[section Member function `lancher::fork`]
-[/==========================================================================================]
-
- template <typename F>
- unique_future<typename result_of<F()>::type>
- fork(F f);
-
-[variablelist
-[[Returns:] [A unique_future to the result of calling a function F.]]
-[[Effects:] [create a thread executing the function f.
- The result of the function will be stored on the resulting future.]]
-
-]
-
-
-[endsect]
-
-
-[endsect]
-
-[section Class `shared_launcher `]
-[/==========================================================================================]
-
-Thread shared_launcher using a common configuration managed with the thread attributes and
-returning on the fork operation a unique_future to the resulting type of the call to the threaded function.
-
- class shared_launcher {
- public:
- thread::native_handle_attr_type& attr();
-
- template <typename T>
- struct handle {
- typedef unique_future<T> > type;
- };
-
- template <typename F>
- unique_future<typename result_of<F()>::type>
- fork(F f);
- };
-
-[section Member function `shared_launcher::attributes`]
-[/==========================================================================================]
-
-Reference to the thread attributes accesor.
-
- thread::native_handle_attr_type& attributes();
-
-[variablelist
-[[Returns:] [A reference to the thread attributes.]]
-[[Complexity:] [constant.]]
-]
-
-
-[endsect]
-[section Metafunction `shared_launcher::handle<>`]
-[/==========================================================================================]
-
-Metafunction that returns the result type of the fork function applied to a shared_launcher and the value type.
-
- template <typename T>
- struct handle {
- typedef unique_future<T> > type;
- };
-
-[variablelist
-[[Expression:] [L::handle<T>::type]]
-[[Return type:] [A unique_future<T>.]]
-[[Complexity:] [constant.]]
-
-]
-
-[endsect]
-
-[section Member function `lancher::fork`]
-[/==========================================================================================]
-
- template <typename F>
- unique_future<typename result_of<F()>::type>
- fork(F f);
-
-[variablelist
-[[Returns:] [A unique_future to the result of calling a function F.]]
-[[Effects:] [create a thread executing the function f.
- The result of the function will be stored on the resulting future.]]
-
-]
-
-
-[endsect]
-
-
-[endsect]
-
-
-[endsect]
-

Deleted: sandbox/interthreads/libs/interthreads/doc/reference/launcher_decorator.qbk
==============================================================================
--- sandbox/interthreads/libs/interthreads/doc/reference/launcher_decorator.qbk 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
+++ (empty file)
@@ -1,20 +0,0 @@
-[/
- (C) Copyright 2008-2009 Vicente J. Botet Escriba
- Distributed under the Boost Software License, Version 1.0.
- (See accompanying file LICENSE_1_0.txt or copy at
- http://www.boost.org/LICENSE_1_0.txt).
-]
-
-[/==========================================================================================]
-[section:launcher_decorator_hpp Header `<boost/interthreads/launcher_decorator.hpp>`]
-[/==========================================================================================]
-
-Shorter names for an __asynchronous_executor_decorator__ based on __launcher__ and __shared_launcher__ respectively and decorated with the __thread_decorator__ .
-
- namespace boost { namespace interthreads {
- typedef asynchronous_executor_decorator<launcher,thread_decorator> launcher_decorator;
- typedef asynchronous_executor_decorator<shared_launcher,thread_decorator> shared_launcher_decorator;
- }}
-
-[endsect]
-

Deleted: sandbox/interthreads/libs/interthreads/doc/reference/scheduler.qbk
==============================================================================
--- sandbox/interthreads/libs/interthreads/doc/reference/scheduler.qbk 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
+++ (empty file)
@@ -1,79 +0,0 @@
-[/
- (C) Copyright 2008-2009 Vicente J. Botet Escriba
- Distributed under the Boost Software License, Version 1.0.
- (See accompanying file LICENSE_1_0.txt or copy at
- http://www.boost.org/LICENSE_1_0.txt).
-]
-
-[/==========================================================================================]
-[section:scheduler_hpp Header `<boost/interthreads/scheduler.hpp>`]
-[/==========================================================================================]
-
-__tp_pool__ can be seen as a __AE__ adding some functions and specializing some traits classes.
-The functions are:
-
-* get_future
-* interruption_requested
-
-The traits are:
-
-* asynchronous_completion_token : associating the __ACT__ __tp_task__
-* partial_specialization_workaround::fork::apply: to call to submit instead of fork.
-
-__tp_task__ is an __ACT__ that models __ThreadBasedACT__ and __FutureBasedACT__.
-
- namespace boost { namespace interthreads {
-
- template <typename C>
- class scheduler {
- explicit scheduler(
- tp::poolsize const& psize
- );
- template <typename T>
- struct handle {
- typedef tp::task<T> type;
- };
- template <typename F>
- tp::task<typename boost::result_of<F()>::type>
- fork(F f);
- };
-
- template <typename Channel>
- struct get_future<scheduler<Channel> > {
- template <typename T>
- struct future_type {
- typedef shared_future<T> type;
- };
- template <typename T>
- shared_future<T>& operator()(tp::task<T>& act);
- };
-
- template <typename Channel, typename T>
- struct asynchronous_completion_token<boost::tp::pool<Channel>,T> {
- typedef boost::tp::task<T> type;
- };
-
- namespace partial_specialization_workaround {
- template< typename Channel, typename F >
- struct fork<boost::tp::pool<Channel>,F> {
- static typename result_of::fork<boost::tp::pool<Channel>, F>::type
- apply( boost::tp::pool<Channel>& ae, F fn );
- };
- }
- template <typename C>
- struct get_future<tp::pool<C> > {
- template <typename T>
- shared_future<T>& operator()(tp::task<T>& act);
- };
-
-
- template <typename R>
- struct has_future_if<tp::task<R> > : mpl::true_{};
-
- template <typename R>
- struct has_thread_if<tp::task<R> > : mpl::true_{};
- }}
-
-
-[endsect]
-

Deleted: sandbox/interthreads/libs/interthreads/doc/reference/threader.qbk
==============================================================================
--- sandbox/interthreads/libs/interthreads/doc/reference/threader.qbk 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
+++ (empty file)
@@ -1,768 +0,0 @@
-[/
- (C) Copyright 2008-2009 Vicente J. Botet Escriba
- Distributed under the Boost Software License, Version 1.0.
- (See accompanying file LICENSE_1_0.txt or copy at
- http://www.boost.org/LICENSE_1_0.txt).
-]
-
-[/==========================================================================================]
-[section:threader_hpp Header `<boost/interthreads/threader.hpp>`]
-[/==========================================================================================]
-
-A threader is an __AE__ with an __ACT__ that model __ThreadBasedACT__ and __FutureBasedACT__.
-
-The library defines two kind of threaders:
-unique_threader and shared_threader that respectively have a unique_joiner and a shared_joiner as __ACT__
-
- #include <boost/interthreads/fork.hpp>
- namespace boost {
- namespace interthreads {
- template <typename ResultType>
- class unique_joiner;
-
- template <typename ResultType>
- void swap(unique_joiner<ResultType>& lhs, unique_joiner<ResultType>& rhs);
-
- class unique_threader;
-
- template <typename ResultType>
- class shared_joiner;
-
- template <typename ResultType>
- void swap(shared_joiner<ResultType>& lhs, shared_joiner<ResultType>& rhs);
-
- class shared_threader;
- }
- }
-
-[/==================================================]
-[section Template Class `unique_joiner<>`]
-[/==========================================================================================]
-
-
- template <typename ResultType>
- class unique_joiner {
- typedef unique_joiner this_type;
- public:
- unique_joiner(const unique_joiner& rhs) = delete;
- unique_joiner& operator=(const unique_joiner& rhs) = delete;
-
- typedef ResultType result_type;
-
- template <typename Nullary>
- unique_joiner(thread::native_handle_attr_type& attr, Nullary f);
- template <typename Nullary>
- unique_joiner(Nullary f);
-
- unique_joiner(boost::detail::thread_move_t<unique_joiner> x);
- unique_joiner& operator=(boost::detail::thread_move_t<unique_joiner> x);
- operator boost::detail::thread_move_t<unique_joiner>();
- boost::detail::thread_move_t<unique_joiner> move();
-
- void swap(this_type& x);
-
- bool joinable() const;
- void join();
- bool join_until(const system_time& abs_time);
- template<typename TimeDuration>
- inline bool join_for(TimeDuration const& rel_time);
-
- result_type get();
- result_type operator()();
-
- bool is_ready() const;
- bool has_exception() const;
- bool has_value() const;
-
- void wait() const;
- bool wait_until(const system_time& abs_time) const;
- template<typename TimeDuration>
- inline bool wait_for(TimeDuration const& rel_time) const;
-
- thread::id get_id() const;
- void detach();
- void interrupt();
- bool interruption_requested() const;
-
- typedef platform-specific-type native_handle_type;
- native_handle_type native_handle();
-
- unique_future<result_type> get_future();
-
- };
-
-
-[section:destructor unique_joiner Destructor]
-[/==========================================================================================]
-
- ~unique_joiner();
-
-[variablelist
-[[Effects:] [If `*this` has an associated thread of execution, calls __detach__. Destroys `*this`.]]
-[[Throws:] [Nothing.]]
-]
-
-[endsect]
-
-[section:swap Member function `swap()`]
-
- void swap(unique_joiner& other);
-
-[variablelist
-[[Effects:] [Exchanges the threads of execution associated with `*this` and `other`, so `*this` is associated with the thread of
-execution associated with `other` prior to the call, and vice-versa.]]
-[[Postconditions:] [`this->get_id()` returns the same value as `other.get_id()` prior to the call. `other.get_id()` returns the same
-value as `this->get_id()` prior to the call.]]
-[[Throws:] [Nothing.]]
-
-]
-
-[endsect]
-
-
-[section Member Function `get()|operator()()`]
-[/==========================================================================================]
-
- result_type get();
- result_type operator()();
-
-[variablelist
-[[Effects:] [Retrieves the value returned by the Nullary function.]]
-[[Sychronization:][The completion of the call to the operator()() the Nullary function happens before get() returns.]]
-[[Returns:] [If the result type R is a reference, returns the stored reference.
-If R is void, there is no return value.
-Otherwise, returns an rvalue-reference to the value stored in the asynchronous result.]]
-[[Throws:] [the stored exception, if an exception was stored and not retrieved before.]]
-[[Postconditions:] [It is unspecified what happens when get() is called a second time on the same unique_joiner.]]
-[[Thread safety:][unsafe]]
-]
-[endsect]
-
-
-[section Member Function `is_ready()`]
-[/==========================================================================================]
-
- bool is_ready() const;
-
-[variablelist
-[[Returns:] [true only if the associated state holds a value or an exception ready for retrieval.]]
-[[Remark:] [the return value is unspecified after a call to get().]]
-]
-[endsect]
-
-[section Member Function `has_exception()`]
-[/==========================================================================================]
-
- bool has_exception() const;
-
-[variablelist
-[[Returns:] [true only if is_ready() == true and the associated state contains an exception.]]
-]
-[endsect]
-
-[section Member Function `has_value()`]
-[/==========================================================================================]
-
- bool has_value() const;
-
-[variablelist
-[[Returns:] [true only if is_ready() == true and the associated state contains a value.]]
-]
-[endsect]
-
-[section Member Function `wait()`]
-[/==========================================================================================]
-
- void wait();
-
-[variablelist
-[[Effects:] [Blocks until the Nullariry function ends.]]
-[[Sychronization:][The completion of the call to the operator()() the Nullary function happens before wait() returns.]]
-[[Throws:] [the stored exception, if an exception was stored and not retrieved before.]]
-[[Postconditions:] [is_ready() == true.]]
-[[Thread safety:][unsafe]]
-]
-[endsect]
-
-[section Member Function `wait_until()|wait_for()`]
-[/==========================================================================================]
-
- bool wait_until(const system_time& abs_time);
- template<typename TimeDuration>
- bool wait_for(TimeDuration const& rel_time);
-
-
-[variablelist
-[[Effects:] [Blocks until the Nullariry function ends.]]
-[[Sychronization:][The completion of the call to the operator()() the Nullary function happens before wait() returns.]]
-[[Returns:] [If the result type R is a reference, returns the stored reference.
-If R is void, there is no return value.
-Otherwise, returns an rvalue-reference to the value stored in the asynchronous result.]]
-[[Throws:] [the stored exception, if an exception was stored and not retrieved before.]]
-[[Postconditions:] [is_ready() == true.]]
-[[Thread safety:][unsafe]]
-]
-[endsect]
-
-
-
-[section:joinable Member function `joinable()`]
-[/==========================================================================================]
-
- bool joinable() const;
-
-[variablelist
-[[Returns:] [`true` if `*this` refers to a thread of execution, `false` otherwise.]]
-[[Throws:] [Nothing]]
-]
-
-[endsect]
-
-[section:join Member function `join()`]
-[/==========================================================================================]
-
- void join();
-
-[variablelist
-[[Preconditions:] [`this->get_id()!=boost::this_thread::get_id()`]]
-[[Effects:] [If `*this` refers to a thread of execution, waits for that thread of execution to complete.]]
-[[Postconditions:] [If `*this` refers to a thread of execution on entry, that thread of execution has completed. `*this` no longer refers to any thread of execution.]]
-[[Throws:] [__thread_interrupted__ if the current thread of execution is interrupted.]]
-[[Notes:] [`join()` is one of the predefined __interruption_points__.]]
-]
-
-[endsect]
-
-[section Member function `join_until()|join_for()`]
-[/==========================================================================================]
-
- bool join_until(const system_time& wait_until);
-
- template<typename TimeDuration>
- bool join_for(TimeDuration const& rel_time);
-
-[variablelist
-[[Preconditions:] [`this->get_id()!=boost::this_thread::get_id()`]]
-[[Effects:] [If `*this` refers to a thread of execution, waits for that thread of execution to complete, the time `wait_until` has
-been reach or the specified duration `rel_time` has elapsed. If `*this` doesn't refer to a thread of execution, returns immediately.]]
-[[Returns:] [`true` if `*this` refers to a thread of execution on entry, and that thread of execution has completed before the call
-times out, `false` otherwise.]]
-[[Postconditions:] [If `*this` refers to a thread of execution on entry, and `timed_join` returns `true`, that thread of execution
-has completed, and `*this` no longer refers to any thread of execution. If this call to `timed_join` returns `false`, `*this` is
-unchanged.]]
-[[Throws:] [__thread_interrupted__ if the current thread of execution is interrupted.]]
-[[Notes:] [`timed_join()` is one of the predefined __interruption_points__.]]
-]
-
-[endsect]
-
-[section:detach Member function `detach()`]
-[/==========================================================================================]
-
- void detach();
-
-[variablelist
-[[Effects:] [If `*this` refers to a thread of execution, that thread of execution becomes detached, and no longer has an associated __thread__ object.]]
-[[Postconditions:] [`*this` no longer refers to any thread of execution.]]
-[[Throws:] [Nothing]]
-]
-
-[endsect]
-
-
-[section:get_id Member function `get_id()`]
-[/==========================================================================================]
-
- thread::id get_id() const;
-
-[variablelist
-[[Returns:] [If `*this` refers to a thread of execution, an instance of __thread_id__ that represents that thread. Otherwise returns
-a default-constructed __thread_id__.]]
-[[Throws:] [Nothing]]
-]
-
-[endsect]
-
-[section:interrupt Member function `interrupt()`]
-[/==========================================================================================]
-
- void interrupt();
-
-[variablelist
-[[Effects:] [If `*this` refers to a thread of execution, request that the thread will be interrupted the next time it enters one of
-the predefined __interruption_points__ with interruption enabled, or if it is currently __blocked__ in a call to one of the
-predefined __interruption_points__ with interruption enabled .]]
-[[Throws:] [Nothing]]
-]
-
-
-[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]
-
-
-
-[endsect]
-[section:non_member_swap Non-member function `swap()`]
-
- void swap(unique_joiner& lhs,unique_joiner& rhs);
-
-[variablelist
-
-[[Effects:] [`lhs.swap(rhs)`.]]
-
-]
-
-[endsect]
-
-[/==================================================]
-[section Template Class `unique_threader`]
-[/==========================================================================================]
-
- class unique_threader {
- public:
- thread::native_handle_attr_type& attributes();
-
- template <typename T>
- struct handle {
- typedef unique_joiner<T> type;
- };
-
- template <typename F>
- unique_joiner<typename result_of<F()>::type>
- fork(F f);
-
- };
-
-[section Member function `unique_threader::attributes()`]
-[/==========================================================================================]
-
-Reference to the thread attributes accesor.
-
- thread::native_handle_attr_type& attributes();
-
-[variablelist
-[[Returns:] [A reference to the thread attributes.]]
-[[Complexity:] [constant.]]
-]
-
-
-[endsect]
-[section Metafunction `unique_threader::handle<>`]
-[/==========================================================================================]
-
-Metafunction that returns the result type of the fork function applied to a unique_threader and the value type.
-
- template <typename T>
- struct handle {
- typedef unique_joiner<T> type;
- };
-
-
-[variablelist
-[[Expression:] [L::handle<T>::type]]
-[[Return type:] [A unique_joiner<T>.]]
-[[Complexity:] [constant.]]
-
-]
-
-[endsect]
-
-[section Member function `unique_threader::fork`]
-[/==========================================================================================]
-
- template <typename F>
- unique_joiner<typename result_of<F()>::type>
- fork(F f);
-
-[variablelist
-[[Returns:] [A unique_joiner to the result of calling a function F.]]
-[[Effects:] [create a thread executing the function f.
- The result of the function will be stored on the resulting unique_joiner.]]
-
-]
-
-
-[endsect]
-
-[endsect]
-
-[/==================================================]
-[section Template Class `shared_joiner<>`]
-[/==========================================================================================]
-
- template <typename ResultType>
- class shared_joiner {
- typedef shared_joiner this_type;
- public:
- shared_joiner(const shared_joiner& rhs);
- shared_joiner& operator=(const shared_joiner& rhs);
-
- typedef ResultType result_type;
-
- template <typename Nullary>
- shared_joiner(thread::native_handle_attr_type& attr, Nullary f);
- template <typename Nullary>
- shared_joiner(Nullary f);
-
- shared_joiner(boost::detail::thread_move_t<shared_joiner> x);
- shared_joiner& operator=(boost::detail::thread_move_t<shared_joiner> x);
- operator boost::detail::thread_move_t<shared_joiner>();
- boost::detail::thread_move_t<shared_joiner> move();
-
- void swap(this_type& x);
-
- bool joinable() const;
- void join();
- bool join_until(const system_time& abs_time);
- template<typename TimeDuration>
- inline bool join_for(TimeDuration const& rel_time);
-
- result_type get();
- result_type operator()();
-
- bool is_ready() const;
- bool has_exception() const;
- bool has_value() const;
-
- void wait() const;
- bool wait_until(const system_time& abs_time) const;
- template<typename TimeDuration>
- inline bool wait_for(TimeDuration const& rel_time) const;
-
- thread::id get_id() const;
- void detach();
- void interrupt();
- bool interruption_requested() const;
-
- typedef platform-specific-type native_handle_type;
- native_handle_type native_handle();
-
- shared_future<result_type> get_future();
- };
-
-
-[section:destructor shared_joiner Destructor]
-[/==========================================================================================]
-
- ~shared_joiner();
-
-[variablelist
-[[Effects:] [If `*this` has an associated thread of execution, calls __detach__. Destroys `*this`.]]
-[[Throws:] [Nothing.]]
-]
-
-[endsect]
-
-[section:swap2 Member function `swap()`]
-
- void swap(shared_joiner& other);
-
-[variablelist
-[[Effects:] [Exchanges the threads of execution associated with `*this` and `other`, so `*this` is associated with the thread of
-execution associated with `other` prior to the call, and vice-versa.]]
-[[Postconditions:] [`this->get_id()` returns the same value as `other.get_id()` prior to the call. `other.get_id()` returns the same
-value as `this->get_id()` prior to the call.]]
-[[Throws:] [Nothing.]]
-
-]
-
-[endsect]
-
-
-[section Member Function `get()|operator()()`]
-[/==========================================================================================]
-
- result_type get();
- result_type operator()();
-
-[variablelist
-[[Effects:] [Retrieves the value returned by the Nullary function.]]
-[[Sychronization:][The completion of the call to the operator()() the Nullary function happens before get() returns.]]
-[[Returns:] [If the result type R is a reference, returns the stored reference.
-If R is void, there is no return value.
-Otherwise, returns an rvalue-reference to the value stored in the asynchronous result.]]
-[[Throws:] [the stored exception, if an exception was stored and not retrieved before.]]
-[[Postconditions:] [It is unspecified what happens when get() is called a second time on the same shared_joiner.]]
-[[Thread safety:][unsafe]]
-]
-[endsect]
-
-
-[section Member Function `is_ready()`]
-[/==========================================================================================]
-
- bool is_ready() const;
-
-[variablelist
-[[Returns:] [true only if the associated state holds a value or an exception ready for retrieval.]]
-[[Remark:] [the return value is unspecified after a call to get().]]
-]
-[endsect]
-
-[section Member Function `has_exception()`]
-[/==========================================================================================]
-
- bool has_exception() const;
-
-[variablelist
-[[Returns:] [true only if is_ready() == true and the associated state contains an exception.]]
-]
-[endsect]
-
-[section Member Function `has_value()`]
-[/==========================================================================================]
-
- bool has_value() const;
-
-[variablelist
-[[Returns:] [true only if is_ready() == true and the associated state contains a value.]]
-]
-[endsect]
-
-[section Member Function `wait()`]
-[/==========================================================================================]
-
- void wait();
-
-[variablelist
-[[Effects:] [Blocks until the Nullariry function ends.]]
-[[Sychronization:][The completion of the call to the operator()() the Nullary function happens before wait() returns.]]
-[[Throws:] [the stored exception, if an exception was stored and not retrieved before.]]
-[[Postconditions:] [is_ready() == true.]]
-[[Thread safety:][unsafe]]
-]
-[endsect]
-
-[section Member Function `wait_until()|wait_for()`]
-[/==========================================================================================]
-
- bool wait_until(const system_time& abs_time);
- template<typename TimeDuration>
- bool wait_for(TimeDuration const& rel_time);
-
-
-[variablelist
-[[Effects:] [Blocks until the Nullariry function ends.]]
-[[Sychronization:][The completion of the call to the operator()() the Nullary function happens before wait() returns.]]
-[[Returns:] [If the result type R is a reference, returns the stored reference.
-If R is void, there is no return value.
-Otherwise, returns an rvalue-reference to the value stored in the asynchronous result.]]
-[[Throws:] [the stored exception, if an exception was stored and not retrieved before.]]
-[[Postconditions:] [is_ready() == true.]]
-[[Thread safety:][unsafe]]
-]
-[endsect]
-
-
-
-[section:joinable2 Member function `joinable()`]
-[/==========================================================================================]
-
- bool joinable() const;
-
-[variablelist
-[[Returns:] [`true` if `*this` refers to a thread of execution, `false` otherwise.]]
-[[Throws:] [Nothing]]
-]
-
-[endsect]
-
-[section:join2 Member function `join()`]
-[/==========================================================================================]
-
- void join();
-
-[variablelist
-[[Preconditions:] [`this->get_id()!=boost::this_thread::get_id()`]]
-[[Effects:] [If `*this` refers to a thread of execution, waits for that thread of execution to complete.]]
-[[Postconditions:] [If `*this` refers to a thread of execution on entry, that thread of execution has completed. `*this` no longer refers to any thread of execution.]]
-[[Throws:] [__thread_interrupted__ if the current thread of execution is interrupted.]]
-[[Notes:] [`join()` is one of the predefined __interruption_points__.]]
-]
-
-[endsect]
-
-[section Member function `join_until()|join_for()`]
-[/==========================================================================================]
-
- bool join_until(const system_time& wait_until);
-
- template<typename TimeDuration>
- bool join_for(TimeDuration const& rel_time);
-
-[variablelist
-[[Preconditions:] [`this->get_id()!=boost::this_thread::get_id()`]]
-[[Effects:] [If `*this` refers to a thread of execution, waits for that thread of execution to complete, the time `wait_until` has
-been reach or the specified duration `rel_time` has elapsed. If `*this` doesn't refer to a thread of execution, returns immediately.]]
-[[Returns:] [`true` if `*this` refers to a thread of execution on entry, and that thread of execution has completed before the call
-times out, `false` otherwise.]]
-[[Postconditions:] [If `*this` refers to a thread of execution on entry, and `timed_join` returns `true`, that thread of execution
-has completed, and `*this` no longer refers to any thread of execution. If this call to `timed_join` returns `false`, `*this` is
-unchanged.]]
-[[Throws:] [__thread_interrupted__ if the current thread of execution is interrupted.]]
-[[Notes:] [`timed_join()` is one of the predefined __interruption_points__.]]
-]
-
-[endsect]
-
-[section:detach3 Member function `detach()`]
-[/==========================================================================================]
-
- void detach();
-
-[variablelist
-[[Effects:] [If `*this` refers to a thread of execution, that thread of execution becomes detached, and no longer has an associated __thread__ object.]]
-[[Postconditions:] [`*this` no longer refers to any thread of execution.]]
-[[Throws:] [Nothing]]
-]
-
-[endsect]
-
-
-[section:get_id2 Member function `get_id()`]
-[/==========================================================================================]
-
- thread::id get_id() const;
-
-[variablelist
-[[Returns:] [If `*this` refers to a thread of execution, an instance of __thread_id__ that represents that thread. Otherwise returns
-a default-constructed __thread_id__.]]
-[[Throws:] [Nothing]]
-]
-
-[endsect]
-
-[section:interrupt2 Member function `interrupt()`]
-[/==========================================================================================]
-
- void interrupt();
-
-[variablelist
-[[Effects:] [If `*this` refers to a thread of execution, request that the thread will be interrupted the next time it enters one of
-the predefined __interruption_points__ with interruption enabled, or if it is currently __blocked__ in a call to one of the
-predefined __interruption_points__ with interruption enabled .]]
-[[Throws:] [Nothing]]
-]
-
-
-[endsect]
-
-
-[section:nativehandle2 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:non_member_swap2 Non-member function `swap()`]
-
- void swap(shared_joiner& lhs,shared_joiner& rhs);
-
-[variablelist
-
-[[Effects:] [`lhs.swap(rhs)`.]]
-
-]
-
-[endsect]
-
-[/==================================================]
-[section Template Class `shared_threader`]
-[/==========================================================================================]
-
- class shared_threader {
- public:
- thread::native_handle_attr_type& attributes();
-
- template <typename T>
- struct handle {
- typedef shared_joiner<T> type;
- };
-
- template <typename F>
- shared_joiner<typename result_of<F()>::type>
- fork(F f);
-
- };
-
-[section Member function `shared_threader::attributes()`]
-[/==========================================================================================]
-
-Reference to the thread attributes accesor.
-
- thread::native_handle_attr_type& attributes();
-
-[variablelist
-[[Returns:] [A reference to the thread attributes.]]
-[[Complexity:] [constant.]]
-]
-
-
-[endsect]
-[section Metafunction `shared_threader::handle<>`]
-[/==========================================================================================]
-
-Metafunction that returns the result type of the fork function applied to a shared_threader and the value type.
-
- template <typename T>
- struct handle {
- typedef shared_joiner<T> type;
- };
-
-
-[variablelist
-[[Expression:] [L::handle<T>::type]]
-[[Return type:] [A shared_joiner<T>.]]
-[[Complexity:] [constant.]]
-
-]
-
-[endsect]
-
-[section Member function `shared_threader::fork`]
-[/==========================================================================================]
-
- template <typename F>
- shared_joiner<typename result_of<F()>::type>
- fork(F f);
-
-[variablelist
-[[Returns:] [A shared_joiner to the result of calling a function F.]]
-[[Effects:] [create a thread executing the function f.
- The result of the function will be stored on the resulting shared_joiner.]]
-
-]
-
-
-[endsect]
-
-[endsect]
-
-[endsect]
-
-

Deleted: sandbox/interthreads/libs/interthreads/doc/reference/wait.qbk
==============================================================================
--- sandbox/interthreads/libs/interthreads/doc/reference/wait.qbk 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
+++ (empty file)
@@ -1,51 +0,0 @@
-[/
- (C) Copyright 2008-2009 Vicente J. Botet Escriba
- Distributed under the Boost Software License, Version 1.0.
- (See accompanying file LICENSE_1_0.txt or copy at
- http://www.boost.org/LICENSE_1_0.txt).
-]
-
-[/==========================================================================================]
-[section:wait_hpp Header `<boost/interthreads/algorithm/wait.hpp>`]
-[/==========================================================================================]
-
-Defines a free function __wait__ which waits the __ACT__ passed as parameter.
-The default implementation applies the __wait__ member function to the __ACT__. A user adapting another __ACT__ could need
-to specialize the __wait__ free function if the __ACT__ do not provides a wait function with the same prototype.
-
-As for the moment we can not partially specialize a function a trick is used: instead of calling directly to the __wait__
-member function, __wait__ calls to the static operation apply on a class with the same name in the namespace __partial_specialization_workaround__.
-So the user can specialize partially this class.
-
-The template parameter ACT must be a model of __FutureBasedACT__.
-
- namespace boost {
- namespace interthreads {
-
- namespace result_of {
- template <typename ACT> struct wait {
- typedef void type;
- };
- }
-
- namespace partial_specialization_workaround {
- template <typename ACT> struct wait {
- static typename result_of::wait<ACT>::type apply( ACT& act ) {
- return act.wait();
- }
- };
- }
-
- template <typename ACT>
- typename boost::enable_if<has_future_if<ACT>,
- typename result_of::wait<ACT>::type
- >::type
- wait(ACT& act) {
- return partial_specialization_workaround::wait<ACT>::apply(act);
- }
-
- }
- } // namespace boost
-
-
-[endsect]

Deleted: sandbox/interthreads/libs/interthreads/doc/reference/wait_all.qbk
==============================================================================
--- sandbox/interthreads/libs/interthreads/doc/reference/wait_all.qbk 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
+++ (empty file)
@@ -1,40 +0,0 @@
-[/
- (C) Copyright 2008-2009 Vicente J. Botet Escriba
- Distributed under the Boost Software License, Version 1.0.
- (See accompanying file LICENSE_1_0.txt or copy at
- http://www.boost.org/LICENSE_1_0.txt).
-]
-
-[/==========================================================================================]
-[section:wait_all_hpp Header `<boost/interthreads/algorithm/wait_all.hpp>`]
-[/==========================================================================================]
-
-Defines a free function __wait_all__ which waits the completion of all the __ACT__ in the sequence passed as parameter.
-
- namespace boost {
- namespace interthreads {
-
- namespace fct {
- struct wait {
- typedef void result_type;
- template<typename ACT>
- void operator()(ACT& act) const;
- };
- }
-
- namespace result_of {
- template <typename Sequence>
- struct wait_all {
- typedef typename fusion::result_of::for_each<Sequence, fct::wait>::type type;
- };
- }
-
- template <typename Sequence>
- typename result_of::wait_all<Sequence>::type
- wait_all(Sequence& t);
-
- }
- } // namespace boost
-
-
-[endsect]

Deleted: sandbox/interthreads/libs/interthreads/doc/reference/wait_all_until.qbk
==============================================================================
--- sandbox/interthreads/libs/interthreads/doc/reference/wait_all_until.qbk 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
+++ (empty file)
@@ -1,54 +0,0 @@
-[/
- (C) Copyright 2008-2009 Vicente J. Botet Escriba
- Distributed under the Boost Software License, Version 1.0.
- (See accompanying file LICENSE_1_0.txt or copy at
- http://www.boost.org/LICENSE_1_0.txt).
-]
-
-[/==========================================================================================]
-[section:wait_all_until_hpp Header `<boost/interthreads/algorithm/wait_all_until.hpp>`]
-[/==========================================================================================]
-
-Defines two free function __wait_all_until__ and __wait_all_for__ which waits the completion of all the __ACT__ in the sequence passed as parameter or a given time is reached or elapsed respectively.
-
- namespace boost {
- namespace interthreads {
-
- namespace fct {
- struct wait_until {
- wait_until(const system_time& abs_time);
- template<typename ACT>
- bool operator()(ACT& act) const;
-
- struct wait_for {
- template <typename Duration>
- wait_for(const Duration& rel_time);
- template<typename ACT>
- bool operator()(ACT& act) const;
- }
-
- namespace result_of {
- template <typename Sequence>
- struct wait_all_until {
- typedef bool type;
- };
-
- template <typename Sequence>
- struct wait_all_for {
- typedef bool type;
- };
- }
-
- template <typename Sequence>
- typename result_of::wait_all_until<Sequence const>
- wait_all_until(Sequence const& t, const system_time& abs_time);
-
- template <typename Sequence, typename Duration>
- typename result_of::wait_all_for<Sequence>
- wait_all_for(Sequence& t, const Duration& rel_time);
-
- }
- }
-
-[endsect]
-

Deleted: sandbox/interthreads/libs/interthreads/doc/reference/wait_for_all.qbk
==============================================================================
--- sandbox/interthreads/libs/interthreads/doc/reference/wait_for_all.qbk 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
+++ (empty file)
@@ -1,89 +0,0 @@
-[/
- (C) Copyright 2008-2009 Vicente J. Botet Escriba
- Distributed under the Boost Software License, Version 1.0.
- (See accompanying file LICENSE_1_0.txt or copy at
- http://www.boost.org/LICENSE_1_0.txt).
-]
-
-[/==========================================================================================]
-[section:wait_for_all_hpp Header `<boost/interthreads/wait_for_all.hpp>`]
-[/==========================================================================================]
-
- namespace boost {
- namespace interthreads {
- namespace result_of {
- template <typename AE, typename F1, ..., typename Fn>
- struct wait_for_all {
- typedef fusion::tuple<
- typename result_of<F1()>::type,
- ...
- typename result_of<Fn()>::type,
- > type;
- };
- }
-
- template< typename AE, typename F1, ..., typename Fn>
- typename result_of::wait_for_all<AE, F1, ..., Fn>::type
- wait_for_all( AE& ae, F1 f1, ..., Fn fn );
- }
- }
-
-[section Metafunction `result_of::wait_for_all<AE,F1, ..., Fn> `]
-[/==========================================================================================]
-
-A metafunction returning the result type of applying get_all to a Sequence of asynchronous executor handles.
-
- namespace result_of {
- template <typename AE, typename F1, ..., typename Fn>
- struct wait_for_all {
- typedef fusion::tuple<
- typename result_of<F1()>::type,
- ...
- typename result_of<Fn()>::type,
- > type;
- };
- }
-
-[table wait_for_all Parameters
- [
- [[*Parameter]]
- [[*Requirement]]
- [[*Description]]
- ]
- [
- [`AE`]
- [A model of `AsynchrousExecutor`]
- [Operation's argument ]
- ]
- [
- [`Fk`]
- [A model of nullary function]
- [Operation's argument ]
- ]
-]
-
-[variablelist
-[[Expression:] [`result_of::wait_for_all<AE, F1, ..., Fn>::type`]]
-[[Return type:] [a fusion tuple of the result of applying get to each one of the asynchronous executors handles resulting of forking each function `Fk` by `AE`]]
-]
-
-[endsect]
-
-[section Non member function `wait_for_all`]
-[/==========================================================================================]
-
- template< typename AE, typename F1, ..., typename Fn>
- typename result_of::wait_for_all<AE, F1, ..., Fn>::type
- wait_for_all( AE& ae, F1 f1, ..., Fn fn );
-
-
-[variablelist
-[[Returns:] [a fusion tuple of the result of applying get to each one of the asynchronous executors handles resulting of forking each function `fk` by `ae`.]]
-[[Effect:] [Request the `AE` to creates a n thread of execution one for the function `fk` and
-blocks until all the AE handles are ready.]]
-
-]
-
-[endsect]
-[endsect]
-

Deleted: sandbox/interthreads/libs/interthreads/doc/reference/wait_for_any.qbk
==============================================================================
--- sandbox/interthreads/libs/interthreads/doc/reference/wait_for_any.qbk 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
+++ (empty file)
@@ -1,84 +0,0 @@
-[/
- (C) Copyright 2008-2009 Vicente J. Botet Escriba
- Distributed under the Boost Software License, Version 1.0.
- (See accompanying file LICENSE_1_0.txt or copy at
- http://www.boost.org/LICENSE_1_0.txt).
-]
-
-[/==========================================================================================]
-[section:wait_for_any_hpp Header `<boost/interthreads/wait_for_any.hpp>`]
-[/==========================================================================================]
-
- namespace boost { namespace interthreads {
- namespace result_of {
- template <typename AE, typename F1, ..., typename Fn>
- struct wait_for_any {
- // requires typename result_of<F1()>::type == typename result_of<Fk()>::type
- typedef std::pair<unsigned,typename result_of<F1()>::type> type;
- };
- }
-
- template< typename AE, typename F1, ..., typename Fn>
- typename result_of::wait_for_any<AE, F1, ..., Fn>::type
- wait_for_any( AE& ae, F1 f1, ..., Fn fn );
- }}
-
-[section Metafunction `result_of::wait_for_all<AE,F1, ..., Fn> `]
-[/==========================================================================================]
-
-A metafunction returning the a pair: the index of the first function executed by the AE and the result type
-of applying get on an asynchronous executor handles.
-
- namespace result_of {
- template <typename AE, typename F1, ..., typename Fn>
- struct wait_for_any {
- // requires typename result_of<F1()>::type == typename result_of<Fk()>::type
- typedef std::pair<unsigned,typename result_of<F1()>::type> type;
- };
- }
-
-[table wait_for_all Parameters
- [
- [[*Parameter]]
- [[*Requirement]]
- [[*Description]]
- ]
- [
- [`AE`]
- [A model of `AsynchrousExecutor`]
- [Operation's argument ]
- ]
- [
- [`Fk`]
- [A model of nullary function]
- [Operation's argument ]
- ]
-]
-
-[variablelist
-[[Expression:] [`result_of::wait_for_any<AE, F1, ..., Fn>::type`]]
-[[Return type:] [a pair: the index of the first function executed by the AE and the result type
-of applying get on an asynchronous executor handles created by `ae` to fork each `fk`]]
-]
-
-[endsect]
-
-[section Non member function `wait_for_any`]
-[/==========================================================================================]
-
- template< typename AE, typename F1, ..., typename Fn>
- typename result_of::wait_for_any<AE, F1, ..., Fn>::type
- wait_for_any( AE& ae, F1 f1, ..., Fn fn );
-
-
-[variablelist
-[[Returns:] [a fusion tuple of the result of applying get to each one of the asynchronous executors handles resulting of forking each function `fk` by `ae`.]]
-[[Effect:] [Request the `AE` to creates a n thread of execution one for the function `fk` and
-blocks until all the AE handles are ready.]]
-
-]
-
-[endsect]
-
-[endsect]
-

Deleted: sandbox/interthreads/libs/interthreads/doc/reference/wait_until.qbk
==============================================================================
--- sandbox/interthreads/libs/interthreads/doc/reference/wait_until.qbk 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
+++ (empty file)
@@ -1,63 +0,0 @@
-[/
- (C) Copyright 2008-2009 Vicente J. Botet Escriba
- Distributed under the Boost Software License, Version 1.0.
- (See accompanying file LICENSE_1_0.txt or copy at
- http://www.boost.org/LICENSE_1_0.txt).
-]
-
-[/==========================================================================================]
-[section:wait_until_hpp Header `<boost/interthreads/algorithm/wait_until.hpp>`]
-[/==========================================================================================]
-
-Defines a free function __wait_until__ which wait until the __ACT__ passed as parameter is ready or the given time is reached.
-The default implementation applies the __wait_until__ member function to the __ACT__. A user adapting another __ACT__ could need
-to specialize the __wait_until__ free function if the __ACT__ do not provides a wait_until function with the same prototype.
-
-As for the moment we can not partially specialize a function a trick is used: instead of calling directly to the __wait_until__
-member function, __wait_until__ calls to the static operation apply on a class with the same name in the namespace __partial_specialization_workaround__.
-So the user can specialize partially this class.
-
-Defines a free function __wait_for__ which wait until the __ACT__ passed as parameter is ready or the given time is elapsed.
-The default implementation applies the __wait_for__ member function to the __ACT__. A user adapting another __ACT__ could need
-to specialize the __wait_for__ free function if the __ACT__ do not provides a __wait_for__ function with the same prototype.
-
-As for the moment we can not partially specialize a function a trick is used: instead of calling directly to the __wait_until__
-member function, __wait_for__ calls to the static operation apply on a class with the same name in the namespace __partial_specialization_workaround__.
-So the user can specialize partially this class.
-
-The template parameter ACT must be a model of __FutureBasedACT__.
-
- namespace boost { namespace interthreads {
- namespace result_of {
- template <typename ACT> struct wait_until {
- typedef bool type;
- };
- template <typename ACT, typename Duration> struct wait_for {
- typedef bool type;
- };
- }
-
- namespace partial_specialization_workaround {
- template <typename ACT> struct wait_until {
- static typename result_of::template wait_until<ACT>::type apply( ACT& act, const system_time& abs_time );
- };
- template< typename ACT, typename Duration> struct wait_for {
- static typename result_of::template wait_for<ACT,Duration>::type apply( ACT& act, Duration abs_time );
- };
- }
-
- template <typename ACT>
- typename boost::enable_if<has_future_if<ACT>,
- typename result_of::template wait_until<ACT>::type
- >::type wait_until(ACT& act, const system_time& abs_time);
-
- template <typename ACT, typename Duration>
- typename boost::enable_if<has_future_if<ACT>,
- typename result_of::template wait_for<ACT,Duration>::type
- >::type wait_for(ACT& act, Duration rel_time);
-
- }
- } // namespace boost
-
-[endsect]
-

Modified: sandbox/interthreads/libs/interthreads/example/basic_keep_alive.cpp
==============================================================================
--- sandbox/interthreads/libs/interthreads/example/basic_keep_alive.cpp (original)
+++ sandbox/interthreads/libs/interthreads/example/basic_keep_alive.cpp 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
@@ -29,8 +29,8 @@
 #include <boost/interthreads/thread_decorator.hpp>
 #include <boost/interthreads/thread_keep_alive.hpp>
 
-#include <boost/interthreads/typeof/threader_decorator.hpp>
-#include <boost/interthreads/algorithm.hpp>
+//#include <boost/interthreads/typeof/threader_decorator.hpp>
+//#include <boost/interthreads/algorithm.hpp>
 
 #include "./async_ostream.hpp"
 #include <boost/thread/thread.hpp>
@@ -87,8 +87,13 @@
 }
     
 int main() {
+ boost::thread th1(bith::make_decorator(my_thread));
+ boost::thread th2(bith::make_decorator(my_thread));
+ boost::thread th3(bith::make_decorator(my_thread11));
+
+ th1.join();
+ th2.join();
+ th3.join();
     
- bith::shared_threader_decorator ae;
- bith::wait_for_all(ae, my_thread, my_thread, my_thread11);
     return 0;
 }

Modified: sandbox/interthreads/libs/interthreads/example/hello_world.cpp
==============================================================================
--- sandbox/interthreads/libs/interthreads/example/hello_world.cpp (original)
+++ sandbox/interthreads/libs/interthreads/example/hello_world.cpp 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
@@ -11,7 +11,7 @@
 //////////////////////////////////////////////////////////////////////////////
 #include <boost/thread/mutex.hpp>
 #include <boost/thread/thread.hpp>
-#include <boost/interthreads/typeof/threader_decorator.hpp>
+//#include <boost/interthreads/typeof/threader_decorator.hpp>
 
 boost::mutex out_global_mutex;
 

Modified: sandbox/interthreads/libs/interthreads/example/mono_thread_id.cpp
==============================================================================
--- sandbox/interthreads/libs/interthreads/example/mono_thread_id.cpp (original)
+++ sandbox/interthreads/libs/interthreads/example/mono_thread_id.cpp 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
@@ -27,9 +27,9 @@
 #include <boost/interthreads/thread_decorator.hpp>
 #include <boost/interthreads/thread_specific_shared_ptr.hpp>
 #include <boost/thread/thread.hpp>
-#include <boost/interthreads/fork_all.hpp>
-#include <boost/interthreads/algorithm.hpp>
-#include <boost/interthreads/typeof/threader_decorator.hpp>
+//#include <boost/interthreads/fork_all.hpp>
+//#include <boost/interthreads/algorithm.hpp>
+//#include <boost/interthreads/typeof/threader_decorator.hpp>
 
 #include <iostream>
         
@@ -105,36 +105,12 @@
     }
 }
 
-void doit() {
- bith::shared_threader_decorator ae;
- BOOST_AUTO(handles, bith::fork_all(ae, my_thread, my_thread));
-#if 0
- //bith::result_of::fork_all<bith::shared_threader_decorator, boost::fusion::tuple<void(*)(), void(*)()> >::type handles =
- {
- const boost::shared_ptr<unsigned> shp1 = mono_thread_id::current_.wait_and_get(boost::fusion::at_c<0>(handles).get_id());
- if (shp1.get()==0) {
- boost::lock_guard<boost::mutex> lock(out_global_mutex);
- std::cout << "ERROR 1" << std::endl;
- }
- }
- {
- const boost::shared_ptr<unsigned> shp1 = mono_thread_id::current_.wait_and_get(boost::fusion::at_c<1>(handles).get_id());
- if (shp1.get()==0) {
- boost::lock_guard<boost::mutex> lock(out_global_mutex);
- std::cout << "ERROR 1" << std::endl;
- }
- }
- //sleep(1);
- //boost::fusion::for_each(handles, mono_thread_id_wait_and_get());
-#endif
- boost::fusion::for_each(handles, mono_thread_id_out());
- bith::join_all(handles);
-}
 
-void doit_clasic() {
+void doit() {
     boost::thread th1(bith::make_decorator(my_thread));
     boost::thread th2(bith::make_decorator(my_thread));
-
+
+#if 0
     const boost::shared_ptr<unsigned> shp1 = mono_thread_id::current_.wait_and_get(th1.get_id());
     if (shp1.get()==0) {
         boost::lock_guard<boost::mutex> lock(out_global_mutex);
@@ -146,7 +122,7 @@
         boost::lock_guard<boost::mutex> lock(out_global_mutex);
         std::cout << "ERROR 2" << std::endl;
     }
-
+#endif
     {
         unsigned u = mono_thread_id::id(th1.get_id());
         boost::lock_guard<boost::mutex> lock(out_global_mutex);

Modified: sandbox/interthreads/libs/interthreads/test/Jamfile.v2
==============================================================================
--- sandbox/interthreads/libs/interthreads/test/Jamfile.v2 (original)
+++ sandbox/interthreads/libs/interthreads/test/Jamfile.v2 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
@@ -25,7 +25,7 @@
 # <library>/boost/thread//boost_thread/<link>static
         <library>../../../../../boost_1_38_0/libs/test/build//boost_unit_test_framework/<link>static
         <library>../build//boost_interthreads/<link>static
- <library>../../tp/build//boost_threadpool/<link>static
+# <library>../../tp/build//boost_threadpool/<link>static
         <library>../../../../../boost_1_38_0/libs/thread/build//boost_thread/<link>static
 
         <include>.
@@ -52,24 +52,13 @@
 {
     test-suite "tests"
         :
-# [ interthreads-run move_test.cpp ]
-# [ interthreads-run test_thread_move.cpp ]
-# [ interthreads-run test_basic_threader.cpp ]
- [ interthreads-run test_launcher.cpp ]
- [ interthreads-run test_threader.cpp ]
- [ interthreads-run test_thread_pool.cpp ]
           [ interthreads-run test_thread_decorator.cpp ]
           [ interthreads-run test_thread_shared_ptr.cpp ]
     ;
     test-suite "example"
         :
           [ interthreads-run ../example/hello_world.cpp ]
- [ interthreads-run ../example/mono_thread_id.cpp ]
           [ interthreads-run ../example/basic_keep_alive.cpp ../example/async_ostream.cpp ]
- [ interthreads-run ../example/multiple_algorithms.cpp ]
- [ interthreads-run ../example/parallel_sort.cpp ]
- [ interthreads-run ../example/parallel_sort2.cpp ]
-# [ interthreads-run parallel_sort.cpp ]
 
 
     ;

Deleted: sandbox/interthreads/libs/interthreads/test/data_types.hpp
==============================================================================
--- sandbox/interthreads/libs/interthreads/test/data_types.hpp 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
+++ (empty file)
@@ -1,101 +0,0 @@
-//////////////////////////////////////////////////////////////////////////////
-//
-// (C) Copyright Vicente J. Botet Escriba 2008-2009. Distributed under the Boost
-// Software License, Version 1.0. (See accompanying file
-// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
-//
-// See http://www.boost.org/libs/sync for documentation.
-//
-//////////////////////////////////////////////////////////////////////////////
-
-#ifndef BOOST_INTERTHREADS_TEST_DATA_TYPES__HPP
-#define BOOST_INTERTHREADS_TEST_DATA_TYPES__HPP
-
-
-#include <boost/thread/xtime.hpp>
-#include <boost/thread/thread.hpp>
-#include <iostream>
-#include <boost/test/unit_test.hpp>
-using namespace boost::unit_test;
-
-namespace
-{
-inline boost::xtime delay(int secs, int msecs=0, int nsecs=0)
-{
- const int MILLISECONDS_PER_SECOND = 1000;
- const int NANOSECONDS_PER_SECOND = 1000000000;
- const int NANOSECONDS_PER_MILLISECOND = 1000000;
-
- boost::xtime xt;
- if (boost::TIME_UTC != boost::xtime_get (&xt, boost::TIME_UTC))
- BOOST_ERROR ("boost::xtime_get != boost::TIME_UTC");
-
- nsecs += xt.nsec;
- msecs += nsecs / NANOSECONDS_PER_MILLISECOND;
- secs += msecs / MILLISECONDS_PER_SECOND;
- nsecs += (msecs % MILLISECONDS_PER_SECOND) * NANOSECONDS_PER_MILLISECOND;
- xt.nsec = nsecs % NANOSECONDS_PER_SECOND;
- xt.sec += secs + (nsecs / NANOSECONDS_PER_SECOND);
-
- return xt;
-}
-
-void sleep(int sec)
-{
- boost::xtime t;
- boost::xtime_get(&t,1);
- t.sec += sec;
- boost::thread::sleep(t);
-}
-}
-
-
-
-struct non_copyable_functor
- : boost::noncopyable
-{
- unsigned value;
- typedef unsigned result_type;
-
- non_copyable_functor():
- value(0)
- {}
-
- unsigned operator()()
- {
- value=999;
- return value;
- }
-};
-
-struct copyable_functor
-{
- unsigned value;
- typedef int result_type;
-
- copyable_functor():
- value(0)
- {}
-
- int operator()()
- {
- value=999;
- return value;
- }
-};
-
-struct print_xml
-{
- template <typename T>
- void operator()(T const& x) const
- {
- std::cout
-// << '<' << typeid(x).name() << '>'
- << x << " "
-// << "</" << typeid(x).name() << '>'
- //<< std::endl
- ;
- }
-};
-
-#endif

Deleted: sandbox/interthreads/libs/interthreads/test/test_ae.hpp
==============================================================================
--- sandbox/interthreads/libs/interthreads/test/test_ae.hpp 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
+++ (empty file)
@@ -1,573 +0,0 @@
-//////////////////////////////////////////////////////////////////////////////
-//
-// (C) Copyright Vicente J. Botet Escriba 2008-2009. Distributed under the Boost
-// Software License, Version 1.0. (See accompanying file
-// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
-//
-// See http://www.boost.org/libs/sync for documentation.
-//
-//////////////////////////////////////////////////////////////////////////////
-#ifndef BOOST_INTERTHREADS_TEST_AE__HPP
-#define BOOST_INTERTHREADS_TEST_AE__HPP
-
-#include <boost/interthreads/algorithm.hpp>
-#include <libs/interthreads/test/data_types.hpp>
-#include "boost/thread/mutex.hpp"
-#include "boost/thread/locks.hpp"
-#include "boost/thread/thread.hpp"
-#include <boost/typeof/typeof.hpp>
-
-#include <boost/test/unit_test.hpp>
-#include <iostream>
-
-using namespace boost::unit_test;
-namespace bith = boost::interthreads;
-namespace bfus = boost::fusion;
-
-int test_value;
-int test_value1;
-int test_value2;
-int test_value3;
-int simple_thread() {
- //std::cout << ">> simple_thread" << std::endl;
- test_value=999;
- sleep(2);
- //std::cout << "<< simple_thread" << std::endl;
- return test_value;
-}
-static std::string test_string_value;
-
-std::string simple_string_thread() {
- test_string_value="999";
- sleep(5);
- return test_string_value;
-}
-
-int simple_thread2() {
- //std::cout << ">>simple_thread2" << std::endl;
- test_value2=111;
- sleep(5);
- //std::cout << "<<simple_thread2" << std::endl;
- return test_value2;
-}
-
-int simple_thread_1(unsigned i) {
- test_value=i;
- sleep(5);
- return test_value;
-}
-
-bool interruption_point_thread(boost::mutex* m,bool* failed)
-{
- boost::mutex::scoped_lock lk(*m);
- boost::this_thread::interruption_point();
- *failed=true;
- return failed;
-}
-
-int my_simple_thread() {
- test_value1=111;
- sleep(2);
- return test_value1;
-}
-
-int my_simple_thread2() {
- test_value2=222;
- sleep(3);
- return test_value2;
-}
-
-int my_simple_thread3() {
- test_value3=333;
- sleep(1);
- return test_value3;
-}
-
-int my_simple_thread4(int i, std::string s) {
- test_value3=333;
- sleep(1);
- return test_value3;
-}
-
-namespace aetst {
-#if 0
-template <typename AE>
-void do_test_member_lazy_fork(AE& ae) {
- test_value=0;
- //BOOST_AUTO(act2, bith::lazy_fork(ae, simple_thread));
- //boost::packaged_task<int> act2(bith::lazy_fork(ae, simple_thread));
- //BOOST_AUTO(act, act2.get_future());
- boost::shared_ptr<boost::packaged_task<int> > tsk(new boost::packaged_task<int>(simple_thread));
- tsk->set_wait_callback(bith::detail::invoke_lazy_task<int>());
- boost::shared_ptr<boost::packaged_task<int> > tsk2(tsk);
- boost::unique_future<int> act=tsk2->get_future();
- int res_value = act.get();
- #if 1
- BOOST_CHECK_EQUAL(test_value, 999);
- BOOST_CHECK_EQUAL(res_value, 999);
- BOOST_CHECK_EQUAL(act.is_ready(), true);
- BOOST_CHECK_EQUAL(act.has_value(), true);
- BOOST_CHECK_EQUAL(act.has_exception(), false);
- #endif
-}
-#endif
-template <typename AE>
-void do_test_member_fork(AE& ae) {
- test_value=0;
- BOOST_AUTO(act, ae.fork(simple_thread));
- BOOST_CHECK_EQUAL(bith::is_ready(act), false);
- BOOST_CHECK_EQUAL(bith::has_value(act), false);
- BOOST_CHECK_EQUAL(bith::has_exception(act), false);
- int res_value = bith::get(act);
- BOOST_CHECK_EQUAL(test_value, 999);
- BOOST_CHECK_EQUAL(res_value, 999);
- BOOST_CHECK_EQUAL(bith::is_ready(act), true);
- BOOST_CHECK_EQUAL(bith::has_value(act), true);
- BOOST_CHECK_EQUAL(bith::has_exception(act), false);
- std::cout << "<<do_test_member_fork" << std::endl;
-
-}
-template <typename AE>
-void do_test_member_fork_thr(AE& ae) {
- test_value=0;
- BOOST_AUTO(act, ae.fork(simple_thread));
- BOOST_CHECK_EQUAL(bith::interruption_requested(act), false);
- BOOST_CHECK_EQUAL(bith::joinable(act), true);
- bith::join(act);
- BOOST_CHECK_EQUAL(test_value, 999);
- BOOST_CHECK_EQUAL(bith::interruption_requested(act), false);
- BOOST_CHECK_EQUAL(bith::joinable(act), false);
- std::cout << "<<do_test_member_fork" << std::endl;
-
-}
-template <typename AE>
-void do_test_member_fork_m_fut(AE& ae) {
- test_value=0;
- typename AE::template handle<int>::type act = ae.fork(simple_thread);
- BOOST_CHECK_EQUAL(act.is_ready(), false);
- BOOST_CHECK_EQUAL(act.has_value(), false);
- BOOST_CHECK_EQUAL(act.has_exception(), false);
- int res_value = bith::get(act);
- BOOST_CHECK_EQUAL(test_value, 999);
- BOOST_CHECK_EQUAL(res_value, 999);
- BOOST_CHECK_EQUAL(bith::is_ready(act), true);
- BOOST_CHECK_EQUAL(bith::has_value(act), true);
- BOOST_CHECK_EQUAL(bith::has_exception(act), false);
- std::cout << "<<do_test_member_fork_m_fut" << std::endl;
-}
-template <typename AE>
-void do_test_member_fork_m_thr(AE& ae) {
- test_value=0;
- typename AE::template handle<int>::type act;
- act = ae.fork(simple_thread);
- bith::join(act);
- BOOST_CHECK_EQUAL(test_value, 999);
- std::cout << "<<do_test_member_fork_m_thr" << std::endl;
-}
-
-template <typename AE>
-void do_test_member_fork_bind(AE& ae) {
- test_value=0;
- BOOST_AUTO(act, ae.fork(boost::bind(simple_thread_1, 2)));
- bith::wait(act);
- BOOST_CHECK_EQUAL(test_value, 2);
- std::cout << "<<do_test_member_fork_bind" << std::endl;
-}
-
-template <typename AE>
-void do_test_fork(AE& ae) {
- test_value=0;
- BOOST_AUTO(act, bith::fork(ae, simple_thread));
- int res_value = bith::get(act);
- BOOST_CHECK_EQUAL(test_value, 999);
- BOOST_CHECK_EQUAL(res_value, 999);
- std::cout << "<<do_test_fork" << std::endl;
-}
-
-template <typename AE>
-void do_test_fork_thr(AE& ae) {
- test_value=0;
- BOOST_AUTO(act, bith::fork(ae, simple_thread));
- bith::join(act);
- BOOST_CHECK_EQUAL(test_value, 999);
- std::cout << "<<do_test_fork_thr" << std::endl;
-}
-
-template <typename AE>
-void do_test_fork_1(AE& ae) {
- test_value=0;
- BOOST_AUTO(act, bith::fork<AE>(ae, simple_thread_1, 2));
- int res_value = bith::get(act);
- BOOST_CHECK_EQUAL(test_value, 2);
- BOOST_CHECK_EQUAL(res_value, 2);
- std::cout << "<<do_test_fork_1" << std::endl;
-}
-
-template <typename AE>
-void do_test_fork_1_thr(AE& ae) {
- test_value=0;
- BOOST_AUTO(act, bith::fork(ae, simple_thread_1, 2));
- bith::wait(act);
- BOOST_CHECK_EQUAL(test_value, 2);
- std::cout << "<<do_test_fork_1" << std::endl;
-}
-
-template <typename AE>
-void do_test_creation_through_functor(AE& ae)
-{
- copyable_functor f;
- BOOST_AUTO(act,bith::fork(ae, f));
- int res_value = bith::get(act);
- BOOST_CHECK_EQUAL(res_value, 999);
- std::cout << "<<do_test_creation_through_functor" << std::endl;
-}
-
-template <typename AE>
-void do_test_creation_through_functor_thr(AE& ae)
-{
- copyable_functor f;
- BOOST_AUTO(act,bith::fork(ae, f));
- bith::wait(act);
- BOOST_CHECK_EQUAL(test_value, 999);
- std::cout << "<<do_test_creation_through_functor_thr" << std::endl;
-}
-
-template <typename AE>
-void do_test_creation_through_reference_wrapper(AE& ae)
-{
- non_copyable_functor f;
- BOOST_AUTO(act,bith::fork(ae, boost::bind(boost::ref(f))));
-
- unsigned res_value = bith::get(act);
- BOOST_CHECK_EQUAL(res_value, 999u);
- BOOST_CHECK_EQUAL(f.value, 999u);
- std::cout << "<<do_test_creation_through_reference_wrapper" << std::endl;
-}
-
-template <typename AE>
-void do_test_creation_through_reference_wrapper_thr(AE& ae)
-{
- non_copyable_functor f;
- BOOST_AUTO(act,bith::fork(ae, boost::bind(boost::ref(f))));
- bith::wait(act);
- BOOST_CHECK_EQUAL(f.value, 999u);
- std::cout << "<<do_test_creation_through_reference_wrapper_thr" << std::endl;
-}
-
-template <typename AE>
-void do_test_wait(AE& ae) {
- BOOST_AUTO(act,bith::fork(ae, simple_thread));
- bith::wait(act);
- std::cout << "<<do_test_wait" << std::endl;
-}
-
-template <typename AE>
-void do_test_wait_all(AE& ae) {
- BOOST_AUTO(tple,bith::fork_all(ae, simple_thread, simple_thread));
- bith::wait_all(tple);
- std::cout << "<<do_test_wait_all" << std::endl;
-}
-
-template <typename AE>
-void do_test_wait_until(AE& ae) {
- BOOST_AUTO(act,bith::fork(ae, simple_thread));
- bool b = bith::wait_until(act,boost::get_system_time()+boost::posix_time::seconds(1));
- BOOST_CHECK_EQUAL(b, false);
- b = bith::wait_until(act,boost::get_system_time()+boost::posix_time::seconds(3));
- BOOST_CHECK_EQUAL(b, true);
- std::cout << "<<do_test_wait_until" << std::endl;
-}
-
-template <typename AE>
-void do_test_wait_all_until(AE& ae) {
- BOOST_AUTO(tple,bith::fork_all(ae, simple_thread, simple_thread));
- bool b = bith::wait_all_until(tple,boost::get_system_time()+boost::posix_time::seconds(1));
- BOOST_CHECK_EQUAL(b, false);
- b = bith::wait_all_until(tple,boost::get_system_time()+boost::posix_time::seconds(3));
- BOOST_CHECK_EQUAL(b, true);
- std::cout << "<<do_test_wait_all_until" << std::endl;
-}
-
-template <typename AE>
-void do_test_wait_for(AE& ae) {
- BOOST_AUTO(tple,bith::fork(ae, simple_thread));
- bool b = bith::wait_for(tple,boost::posix_time::seconds(1));
- BOOST_CHECK_EQUAL(b, false);
- b = bith::wait_for(tple,boost::posix_time::seconds(3));
- BOOST_CHECK_EQUAL(b, true);
- std::cout << "<<do_test_wait_for" << std::endl;
-}
-
-template <typename AE>
-void do_test_wait_all_for(AE& ae) {
- BOOST_AUTO(tple,bith::fork_all(ae, simple_thread, simple_thread));
- bool b = bith::wait_all_for(tple,boost::posix_time::seconds(1));
- BOOST_CHECK_EQUAL(b, false);
- b = bith::wait_all_for(tple,boost::posix_time::seconds(3));
- BOOST_CHECK_EQUAL(b, true);
- std::cout << "<<do_test_wait_all_for" << std::endl;
-}
-
-template <typename AE>
-void do_test_wait_for_any(AE& ae) {
- std::cout << ">>do_test_wait_for_any" << std::endl;
- BOOST_AUTO(res, bith::wait_for_any(ae, simple_thread2, simple_thread));
- BOOST_CHECK_EQUAL(res.first, 1u);
- BOOST_CHECK_EQUAL(res.second, 999);
- res = bith::wait_for_any(ae, simple_thread, simple_thread2);
- BOOST_CHECK_EQUAL(res.first, 0u);
- BOOST_CHECK_EQUAL(res.second, 999);
- boost::this_thread::sleep(boost::posix_time::milliseconds(5000));
- std::cout << "<<do_test_wait_for_any" << std::endl;
-
-
-}
-
-template <typename AE>
-void do_test_set_all(AE& ae) {
- BOOST_AUTO(tple,bith::fork_all(ae, simple_thread, simple_thread2));
- bfus::tuple<int,int> res;
- bith::set_all(tple,res);
- BOOST_CHECK_EQUAL(bfus::at_c<0>(res), 999);
- BOOST_CHECK_EQUAL(bfus::at_c<1>(res), 111);
-
- //bfus::for_each(res, print_xml());
- //std::cout << std::endl;
- std::cout << "<<do_test_fork_1" << std::endl;
-
-}
-template <typename AE>
-void do_test_get(AE& ae) {
- BOOST_AUTO(act,bith::fork(ae, simple_thread));
- bith::get(act);
- BOOST_AUTO(res_value,bith::get(act));
- BOOST_CHECK_EQUAL(test_value, 999);
- BOOST_CHECK_EQUAL(res_value, 999);
- std::cout << "<<do_test_get" << std::endl;
-}
-
-template <typename AE>
-void do_test_get_all(AE& ae) {
- BOOST_AUTO(tple,bith::fork_all(ae, simple_thread, simple_thread2));
-// bith::wait_all(tple);
- BOOST_AUTO(res,bith::get_all(tple));
- BOOST_CHECK_EQUAL(bfus::at_c<0>(res), 999);
- BOOST_CHECK_EQUAL(bfus::at_c<1>(res), 111);
- //bfus::for_each(res, print_xml());
- //std::cout << std::endl;
- std::cout << "<<do_test_get_all" << std::endl;
-}
-
-template <typename AE>
-void do_test_wait_for_all(AE& ae) {
- BOOST_AUTO(res, bith::wait_for_all(ae, simple_thread, simple_thread2));
- //bfus::for_each(res, print_xml());
- //std::cout << std::endl;
-
- BOOST_CHECK_EQUAL(bfus::at_c<0>(res), 999);
- BOOST_CHECK_EQUAL(bfus::at_c<1>(res), 111);
- res = bith::wait_for_all(ae, simple_thread2, simple_thread);
- //bfus::for_each(res, print_xml());
- //std::cout << std::endl;
-
- BOOST_CHECK_EQUAL(bfus::at_c<0>(res), 111);
- BOOST_CHECK_EQUAL(bfus::at_c<1>(res), 999);
- std::cout << "<<do_test_wait_for_all" << std::endl;
-}
-
-
-///////////////
-
-template <typename AE>
-void do_test_member_fork_detach(AE& ae) {
- test_value=0;
-
- BOOST_AUTO(act,ae.fork(simple_thread));
- BOOST_CHECK_EQUAL(bith::interruption_requested(act), false);
- BOOST_CHECK_EQUAL(bith::joinable(act), true);
- bith::detach(act);
- BOOST_CHECK_EQUAL(bith::joinable(act), false);
- bith::join(act);
- BOOST_CHECK_EQUAL(test_value, 999);
- std::cout << "<<do_test_member_fork_detach" << std::endl;
-}
-
-template <typename AE>
-void do_test_join(AE& ae) {
- BOOST_AUTO(act,bith::fork(ae, simple_thread));
- bith::join(act);
- std::cout << "<<do_test_join" << std::endl;
-}
-
-template <typename AE>
-void do_test_join_m(AE& ae) {
- typename AE::template handle<int>::type act = ae.fork(simple_thread);
- bith::join(act);
- std::cout << "<<do_test_join_m" << std::endl;
-}
-
-template <typename AE>
-void do_test_join_all(AE& ae) {
- BOOST_AUTO(tple,bith::fork_all(ae, simple_thread, simple_thread));
- bith::join_all(tple);
- std::cout << "<<do_test_join_all" << std::endl;
-}
-
-template <typename AE>
-void do_test_join_until(AE& ae) {
- BOOST_AUTO(act,bith::fork(ae, simple_thread));
- bool b = bith::join_until(act,boost::get_system_time()+boost::posix_time::seconds(1));
- BOOST_CHECK_EQUAL(b, false);
- b = bith::join_until(act,boost::get_system_time()+boost::posix_time::seconds(3));
- BOOST_CHECK_EQUAL(b, true);
- std::cout << "<<do_test_join_until" << std::endl;
-}
-
-template <typename AE>
-void do_test_join_until_m(AE& ae) {
- //BOOST_AUTO(act,bith::fork(ae, simple_thread));
- typename AE::template handle<int>::type act = ae.fork(simple_thread);
- bool b = bith::join_until(act,boost::get_system_time()+boost::posix_time::seconds(1));
- BOOST_CHECK_EQUAL(b, false);
- b = bith::join_until(act,boost::get_system_time()+boost::posix_time::seconds(3));
- BOOST_CHECK_EQUAL(b, true);
- std::cout << "<<do_test_join_until_m" << std::endl;
-}
-
-template <typename AE>
-void do_test_join_all_until(AE& ae) {
- BOOST_AUTO(tple,bith::fork_all(ae, simple_thread, simple_thread));
- bool b = bith::join_all_until(tple,boost::get_system_time()+boost::posix_time::seconds(1));
- BOOST_CHECK_EQUAL(b, false);
- b = bith::join_all_until(tple,boost::get_system_time()+boost::posix_time::seconds(3));
- BOOST_CHECK_EQUAL(b, true);
- std::cout << "<<do_test_join_all_until" << std::endl;
-}
-
-template <typename AE>
-void do_test_join_for(AE& ae) {
- BOOST_AUTO(act,bith::fork(ae, simple_thread));
- bool b = bith::join_for(act,boost::posix_time::seconds(1));
- BOOST_CHECK_EQUAL(b, false);
- b = bith::join_for(act,boost::posix_time::seconds(3));
- BOOST_CHECK_EQUAL(b, true);
- std::cout << "<<do_test_join_for" << std::endl;
-}
-
-template <typename AE>
-void do_test_join_for_m(AE& ae) {
- //BOOST_AUTO(act,boost::move(bith::fork(ae, simple_thread)));
- typename AE::template handle<int>::type act = ae.fork(simple_thread);
- bool b = bith::join_for(act,boost::posix_time::seconds(1));
- BOOST_CHECK_EQUAL(b, false);
- b = bith::join_for(act,boost::posix_time::seconds(3));
- BOOST_CHECK_EQUAL(b, true);
- std::cout << "<<do_test_join_for_m" << std::endl;
-}
-
-template <typename AE>
-void do_test_join_all_for(AE& ae) {
- BOOST_AUTO(tple,bith::fork_all(ae, simple_thread, simple_thread));
- bool b = bith::join_all_for(tple,boost::posix_time::seconds(1));
- BOOST_CHECK_EQUAL(b, false);
- b = bith::join_all_for(tple,boost::posix_time::seconds(3));
- BOOST_CHECK_EQUAL(b, true);
- std::cout << "<<do_test_join_all_for" << std::endl;
-}
-
-
-template <typename AE>
-void do_test_thread_interrupts_at_interruption_point(AE& ae) {
- boost::mutex m;
- bool failed=false;
- boost::mutex::scoped_lock lk(m);
- BOOST_AUTO(act,bith::fork(ae, interruption_point_thread, &m,&failed));
- bith::interrupt(act);
- //act.interrupt();
- BOOST_CHECK_EQUAL(bith::interruption_requested(act), true);
- lk.unlock();
- bith::wait(act);
- //boost::this_thread::sleep(boost::posix_time::milliseconds(5000));
-
- BOOST_CHECK(!failed);
- std::cout << "<<do_test_thread_interrupts_at_interruption_point" << std::endl;
-}
-
-template <typename AE>
-void do_test_thread_interrupts_at_interruption_point_m(AE& ae) {
- boost::mutex m;
- bool failed=false;
- boost::mutex::scoped_lock lk(m);
- BOOST_AUTO(act,bith::fork(ae, interruption_point_thread, &m,&failed));
- act.interrupt();
- BOOST_CHECK_EQUAL(bith::interruption_requested(act), true);
- lk.unlock();
- bith::wait(act);
- BOOST_CHECK(!failed);
- std::cout << "<<do_test_thread_interrupts_at_interruption_point_m" << std::endl;
-}
-
-template <typename AE>
-void do_test_fork_after_get(AE& ae) {
- test_value=0;
- test_value2=0;
- test_value3=0;
- BOOST_AUTO(actT, bith::fork_all(ae, my_simple_thread, my_simple_thread2));
-
- #ifndef ACT_WRAPPER
- typename AE:: template handle<int>::type res;
- bith::fork_after(ae, my_simple_thread3, actT, res);
- sleep(5);
- #else
- BOOST_AUTO(act,bith::fork_after(ae, my_simple_thread3, actT));
- #endif
-
- int res =bith::get(act);
- BOOST_CHECK_EQUAL(test_value3, 333);
- BOOST_CHECK_EQUAL(res, 333);
- std::cout << "<<do_test_fork_after_get" << std::endl;
-}
-
-template <typename AE>
-void do_test_fork_after_wait(AE& ae) {
- test_value=0;
- test_value2=0;
- test_value3=0;
- BOOST_AUTO(actT, bith::fork_all(ae, my_simple_thread, my_simple_thread2));
-
- #ifndef ACT_WRAPPER
- typename AE:: template handle<int>::type res;
- bith::fork_after(ae, my_simple_thread3, actT, res);
- sleep(5);
- #else
- BOOST_AUTO(act,bith::fork_after(ae, my_simple_thread3, actT));
- #endif
- bith::wait(act);
-
- BOOST_CHECK_EQUAL(test_value3, 333);
- std::cout << "<<do_test_fork_after_wait" << std::endl;
-
-}
-
-template <typename AE>
-void do_test_fork_after_join(AE& ae) {
- test_value=0;
- test_value2=0;
- test_value3=0;
- BOOST_AUTO(actT, bith::fork_all(ae, my_simple_thread, my_simple_thread2));
-
- #ifndef ACT_WRAPPER
- typename AE:: template handle<int>::type res;
- bith::fork_after(ae, my_simple_thread3, actT, res);
- sleep(5);
- #else
- BOOST_AUTO(act,bith::fork_after(ae, my_simple_thread3, actT));
- #endif
- bith::join(act);
-
- BOOST_CHECK_EQUAL(test_value3, 333);
- std::cout << "<<do_test_fork_after_join" << std::endl;
-
-}
-}
-#endif

Deleted: sandbox/interthreads/libs/interthreads/test/test_basic_threader.cpp
==============================================================================
--- sandbox/interthreads/libs/interthreads/test/test_basic_threader.cpp 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
+++ (empty file)
@@ -1,167 +0,0 @@
-//////////////////////////////////////////////////////////////////////////////
-//
-// (C) Copyright Vicente J. Botet Escriba 2008-2009. Distributed under the Boost
-// Software License, Version 1.0. (See accompanying file
-// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
-//
-// See http://www.boost.org/libs/sync for documentation.
-//
-//////////////////////////////////////////////////////////////////////////////
-
-#include "boost/interthreads/typeof/basic_threader.hpp"
-#include "boost/interthreads/algorithm.hpp"
-
-#include <iostream>
-#include <boost/test/unit_test.hpp>
-
-#include <libs/interthreads/test/data_types.hpp>
-#include <libs/interthreads/test/test_ae.hpp>
-
-using namespace boost::unit_test;
-namespace bith = boost::interthreads;
-namespace bfus = boost::fusion;
-
-
-#if 0
-void do_test_member_fork_detach() {
- bith::basic_threader ae;
- aetst::do_test_member_fork_detach(ae);
-}
-void do_test_member_fork_thr() {
- bith::basic_threader ae;
- aetst::do_test_member_fork_thr(ae);
-}
-
-void do_test_member_fork_m() {
- bith::basic_threader ae;
- #if 1
- aetst::do_test_member_fork_m_thr(ae);
- #endif
- test_value=0;
- boost::thread act(ae.fork(simple_thread));
- act.join();
- BOOST_CHECK_EQUAL(test_value, 999);
-}
-
-
-void do_test_member_fork_bind() {
- bith::basic_threader ae;
- aetst::do_test_member_fork_bind(ae);
-}
-
-void do_test_member_fork_bind2() {
- bith::basic_threader ae;
- #if 0
- aetst::do_test_member_fork_bind(ae);
- return;
- #endif
- test_value=0;
- boost::thread act(ae.fork(boost::bind(simple_thread_1, 2)));
- act.join();
- BOOST_CHECK_EQUAL(test_value, 2);
-}
-
-void do_test_fork_thr() {
- bith::basic_threader ae;
- aetst::do_test_fork_thr(ae);
- //test_value=0;
- //boost::thread act = bith::fork(ae, simple_thread);
- //act.join();
- //BOOST_CHECK_EQUAL(test_value, 999);
-}
-
-void do_test_fork_1_thr() {
- bith::basic_threader ae;
- aetst::do_test_fork_1_thr(ae);
- //test_value=0;
- //boost::thread act = bith::fork(ae, simple_thread_1, 2);
- //act.join();
- //BOOST_CHECK_EQUAL(test_value, 2);
-}
-
-void do_test_creation_through_reference_wrapper_thr()
-{
- bith::basic_threader ae;
- aetst::do_test_creation_through_reference_wrapper_thr(ae);
-}
-
-void do_test_creation_through_functor_thr()
-{
- bith::basic_threader ae;
- aetst::do_test_creation_through_functor_thr(ae);
-}
-
-void do_test_thread_interrupts_at_interruption_point() {
- bith::basic_threader ae;
- aetst::do_test_thread_interrupts_at_interruption_point(ae);
-}
-
-
-#if 0
-// this do not works because boost::thread is movable-only and boost::fusion::tuple works only with CopyContructible types
-void do_test_join_all() {
- bith::basic_threader ae;
- typedef bith::result_of::fork_all<bith::basic_threader,bfus::tuple<void(*)(),void(*)()> >::type type;
- type handles = bith::fork_all(ae, simple_thread, simple_thread);
- //BOOST_AUTO(handles,bith::fork_all(ae, simple_thread, simple_thread));
- bith::join_all(tple);
-
-}
-#endif
-
-
-void do_test_wait() {
- bith::basic_threader ae;
- aetst::do_test_wait(ae);
-}
-
-void do_test_wait_until() {
- bith::basic_threader ae;
- aetst::do_test_wait_until(ae);
-}
-
-void do_test_wait_for() {
- bith::basic_threader ae;
- aetst::do_test_wait_for(ae);
-}
-
-void do_test_join() {
- bith::basic_threader ae;
- aetst::do_test_join_m(ae);
-}
-
-void do_test_join_until() {
- bith::basic_threader ae;
- aetst::do_test_join_until_m(ae);
-}
-#endif
-void do_test_join_for_m() {
- bith::basic_threader ae;
- aetst::do_test_join_for_m(ae);
-}
-
-test_suite* init_unit_test_suite(int, char*[])
-{
- test_suite* test = BOOST_TEST_SUITE("basic_threader");
- test->add(BOOST_TEST_CASE(&do_test_join_for_m));
-
-#if 0
- //test->add(BOOST_TEST_CASE(&do_test_member_fork));
- //test->add(BOOST_TEST_CASE(&do_test_member_fork_m));
- test->add(BOOST_TEST_CASE(&do_test_member_fork_bind));
- test->add(BOOST_TEST_CASE(&do_test_fork_thr));
- test->add(BOOST_TEST_CASE(&do_test_fork_1_thr));
-
- test->add(BOOST_TEST_CASE(&do_test_wait));
- test->add(BOOST_TEST_CASE(&do_test_wait_until));
- test->add(BOOST_TEST_CASE(&do_test_wait_for));
-
- //test->add(BOOST_TEST_CASE(&do_test_member_fork_detach));
- test->add(BOOST_TEST_CASE(&do_test_join));
- test->add(BOOST_TEST_CASE(&do_test_join_until));
-
- test->add(BOOST_TEST_CASE(&do_test_join_all));
-#endif
- return test;
-}
-

Deleted: sandbox/interthreads/libs/interthreads/test/test_launcher.cpp
==============================================================================
--- sandbox/interthreads/libs/interthreads/test/test_launcher.cpp 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
+++ (empty file)
@@ -1,229 +0,0 @@
-//////////////////////////////////////////////////////////////////////////////
-//
-// (C) Copyright Vicente J. Botet Escriba 2008-2009. Distributed under the Boost
-// Software License, Version 1.0. (See accompanying file
-// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
-//
-// See http://www.boost.org/libs/sync for documentation.
-//
-//////////////////////////////////////////////////////////////////////////////
-
-#include <boost/interthreads/typeof/launcher.hpp>
-#include <boost/interthreads/typeof/future.hpp>
-#include <boost/interthreads/algorithm.hpp>
-
-#include <iostream>
-#include <boost/test/unit_test.hpp>
-#include <libs/interthreads/test/data_types.hpp>
-#include <libs/interthreads/test/test_ae.hpp>
-
-using namespace boost::unit_test;
-namespace bith = boost::interthreads;
-namespace bfus = boost::fusion;
-
-#if 0
-void do_test_member_lazy_fork() {
- bith::shared_launcher ae;
- aetst::do_test_member_lazy_fork(ae);
-}
-#endif
-void do_test_member_fork_move_unique() {
- bith::launcher ae;
- aetst::do_test_member_fork_m_fut(ae);
-}
-
-void do_test_member_fork() {
- bith::shared_launcher ae;
- aetst::do_test_member_fork(ae);
-}
-void do_test_member_fork_move() {
- bith::shared_launcher ae;
- aetst::do_test_member_fork_m_fut(ae);
-}
-
-void do_test_member_fork_bind() {
- bith::shared_launcher ae;
- aetst::do_test_member_fork_bind(ae);
-}
-
-void do_test_member_fork_bind_move() {
- bith::launcher ae;
- test_value=0;
- boost::unique_future<int> fut = ae.fork(boost::bind(simple_thread_1, 2));
- int res_value = fut.get();
- BOOST_CHECK_EQUAL(test_value, 2);
- BOOST_CHECK_EQUAL(res_value, 2);
-}
-
-void do_test_fork() {
- bith::shared_launcher ae;
- aetst::do_test_fork(ae);
-}
-
-void do_test_fork_move() {
- bith::launcher ae;
- test_value=0;
- boost::unique_future<int> fut = bith::fork(ae, simple_thread);
- int res_value = fut.get();
- BOOST_CHECK_EQUAL(test_value, 999);
- BOOST_CHECK_EQUAL(res_value, 999);
-}
-
-void do_test_fork_1() {
- bith::shared_launcher ae;
- aetst::do_test_fork_1(ae);
-}
-void do_test_fork_1_move() {
- bith::launcher ae;
- test_value=0;
- boost::unique_future<int> fut = fork(ae, simple_thread_1, 2);
- int res_value = fut.get();
- BOOST_CHECK_EQUAL(test_value, 2);
- BOOST_CHECK_EQUAL(res_value, 2);
-}
-
-void do_test_creation_through_functor()
-{
- bith::shared_launcher ae;
- aetst::do_test_creation_through_functor(ae);
-}
-
-void do_test_creation_through_functor_move()
-{
- bith::launcher ae;
- copyable_functor f;
- boost::unique_future<int> act=bith::fork(ae, f);
-
- int res = act.get();
- BOOST_CHECK_EQUAL(res, 999);
-}
-
-void do_test_creation_through_reference_wrapper()
-{
- bith::shared_launcher ae;
- aetst::do_test_creation_through_reference_wrapper(ae);
-}
-
-
-void do_test_wait() {
- bith::shared_launcher ae;
- aetst::do_test_wait(ae);
-}
-
-void do_test_wait_until() {
- bith::shared_launcher ae;
- aetst::do_test_wait_until(ae);
-}
-
-void do_test_wait_for() {
- bith::shared_launcher ae;
- aetst::do_test_wait_for(ae);
-}
-
-void do_test_join() {
- bith::shared_launcher ae;
- aetst::do_test_join(ae);
-}
-
-void do_test_join_until() {
- bith::shared_launcher ae;
- aetst::do_test_join_until(ae);
-}
-
-void do_test_join_for() {
- bith::shared_launcher ae;
- aetst::do_test_join_for(ae);
-}
-
-void do_test_join_all() {
- bith::shared_launcher ae;
- aetst::do_test_join_all(ae);
-}
-
-void do_test_wait_all() {
- bith::shared_launcher ae;
- aetst::do_test_wait_all(ae);
-}
-
-void do_test_wait_for_any() {
- bith::shared_launcher ae;
- aetst::do_test_wait_for_any(ae);
-}
-
-void do_test_set_all() {
- bith::shared_launcher ae;
- aetst::do_test_set_all(ae);
-}
-
-void do_test_get() {
- bith::shared_launcher ae;
- aetst::do_test_get(ae);
-}
-
-void do_test_get_all() {
- bith::shared_launcher ae;
- aetst::do_test_set_all(ae);
-}
-
-void do_test_wait_for_all() {
- bith::shared_launcher ae;
- aetst::do_test_wait_for_all(ae);
-}
-
-void do_test_wait_all_until() {
- bith::shared_launcher ae;
- aetst::do_test_wait_all_until(ae);
-}
-
-void do_test_fork_after_wait() {
- bith::shared_launcher ae;
- aetst::do_test_fork_after_wait(ae);
-}
-void do_test_fork_after_get() {
- bith::shared_launcher ae;
- aetst::do_test_fork_after_get(ae);
-}
-
-test_suite* init_unit_test_suite(int, char*[])
-{
- test_suite* test = BOOST_TEST_SUITE("launcher");
-
- test->add(BOOST_TEST_CASE(&do_test_member_fork));
- test->add(BOOST_TEST_CASE(&do_test_member_fork_move));
- test->add(BOOST_TEST_CASE(&do_test_member_fork_bind));
- test->add(BOOST_TEST_CASE(&do_test_member_fork_bind_move));
- test->add(BOOST_TEST_CASE(&do_test_fork));
- test->add(BOOST_TEST_CASE(&do_test_fork_move));
- test->add(BOOST_TEST_CASE(&do_test_fork_1));
- test->add(BOOST_TEST_CASE(&do_test_fork_1_move));
- test->add(BOOST_TEST_CASE(&do_test_creation_through_functor));
- test->add(BOOST_TEST_CASE(&do_test_creation_through_reference_wrapper));
-
- test->add(BOOST_TEST_CASE(&do_test_get));
- test->add(BOOST_TEST_CASE(&do_test_wait));
- test->add(BOOST_TEST_CASE(&do_test_wait_until));
- test->add(BOOST_TEST_CASE(&do_test_wait_for));
- test->add(BOOST_TEST_CASE(&do_test_wait_all));
- test->add(BOOST_TEST_CASE(&do_test_wait_all_until));
- test->add(BOOST_TEST_CASE(&do_test_set_all));
- test->add(BOOST_TEST_CASE(&do_test_get_all));
-
- test->add(BOOST_TEST_CASE(&do_test_join));
- test->add(BOOST_TEST_CASE(&do_test_join_until));
- test->add(BOOST_TEST_CASE(&do_test_join_for));
- test->add(BOOST_TEST_CASE(&do_test_join_all));
- //test->add(BOOST_TEST_CASE(&do_test_join_all_until));
- //test->add(BOOST_TEST_CASE(&do_test_join_all_for));
-
-
- test->add(BOOST_TEST_CASE(&do_test_wait_for_all));
- test->add(BOOST_TEST_CASE(&do_test_wait_for_any));
- test->add(BOOST_TEST_CASE(&do_test_fork_after_wait));
- test->add(BOOST_TEST_CASE(&do_test_fork_after_get));
-
-#if 0
- test->add(BOOST_TEST_CASE(&do_test_member_lazy_fork));
-#endif
- return test;
-}
-

Deleted: sandbox/interthreads/libs/interthreads/test/test_thread_pool.cpp
==============================================================================
--- sandbox/interthreads/libs/interthreads/test/test_thread_pool.cpp 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
+++ (empty file)
@@ -1,249 +0,0 @@
-//////////////////////////////////////////////////////////////////////////////
-//
-// (C) Copyright Vicente J. Botet Escriba 2008-2009. Distributed under the Boost
-// Software License, Version 1.0. (See accompanying file
-// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
-//
-// See http://www.boost.org/libs/sync for documentation.
-//
-//////////////////////////////////////////////////////////////////////////////
-
-
-#include "boost/interthreads/typeof/scheduler.hpp"
-#include "boost/interthreads/algorithm.hpp"
-#include <libs/interthreads/test/data_types.hpp>
-#include <libs/interthreads/test/test_ae.hpp>
-
-#include <iostream>
-#include <boost/test/unit_test.hpp>
-
-#include <boost/tp/unbounded_channel.hpp>
-#include <boost/tp/fifo.hpp>
-#include <boost/tp/default_pool.hpp>
-
-
-using namespace boost::unit_test;
-namespace bith = boost::interthreads;
-namespace bfus = boost::fusion;
-
-//#define SCHEDULER
-
-#ifdef SCHEDULER
-typedef bith::scheduler<
- boost::tp::unbounded_channel< boost::tp::fifo >
-> pool_type;
-#else
-//typedef boost::tp::pool<
-// boost::tp::unbounded_channel< boost::tp::fifo >
-//> pool_type;
-typedef boost::tp::default_pool& pool_type;
-#endif
-
-#if 0
-void do_test_member_fork_detach() {
- pool_type ae(boost::tp::poolsize(2));
- aetst::do_test_member_fork_detach(ae);
-}
-
-void do_test_member_fork() {
- pool_type ae(boost::tp::poolsize(2));
- aetst::do_test_member_fork(ae);
-}
-
-void do_test_member_fork_bind() {
- pool_type ae(boost::tp::poolsize(2));
- aetst::do_test_member_fork_bind(ae);
-}
-#endif
-void do_test_fork() {
- //pool_type ae(boost::tp::poolsize(2));
- pool_type ae(boost::tp::get_default_pool());
- aetst::do_test_fork(ae);
-}
-
-void do_test_fork_1() {
- //pool_type ae(boost::tp::poolsize(2));
- pool_type ae(boost::tp::get_default_pool());
- aetst::do_test_fork_1(ae);
-}
-
-void do_test_creation_through_reference_wrapper()
-{
- //pool_type ae(boost::tp::poolsize(2));
- pool_type ae(boost::tp::get_default_pool());
- aetst::do_test_creation_through_reference_wrapper(ae);
-}
-
-void do_test_creation_through_functor()
-{
- //pool_type ae(boost::tp::poolsize(2));
- pool_type ae(boost::tp::get_default_pool());
- aetst::do_test_creation_through_functor(ae);
-}
-void do_test_wait() {
- //pool_type ae(boost::tp::poolsize(2));
- pool_type ae(boost::tp::get_default_pool());
- aetst::do_test_wait(ae);
-}
-
-void do_test_wait_until() {
- //pool_type ae(boost::tp::poolsize(2));
- pool_type ae(boost::tp::get_default_pool());
- aetst::do_test_wait_until(ae);
-}
-
-void do_test_wait_for() {
- //pool_type ae(boost::tp::poolsize(2));
- pool_type ae(boost::tp::get_default_pool());
- aetst::do_test_wait_for(ae);
-}
-
-void do_test_join() {
- //pool_type ae(boost::tp::poolsize(2));
- pool_type ae(boost::tp::get_default_pool());
- aetst::do_test_join(ae);
-}
-
-void do_test_join_until() {
- //pool_type ae(boost::tp::poolsize(2));
- pool_type ae(boost::tp::get_default_pool());
- aetst::do_test_join_until(ae);
-}
-
-void do_test_join_for() {
- //pool_type ae(boost::tp::poolsize(2));
- pool_type ae(boost::tp::get_default_pool());
- aetst::do_test_join_for(ae);
-}
-
-void do_test_join_all() {
- //pool_type ae(boost::tp::poolsize(2));
- pool_type ae(boost::tp::get_default_pool());
- aetst::do_test_join_all(ae);
-}
-
-void do_test_join_all_until() {
- //pool_type ae(boost::tp::poolsize(2));
- pool_type ae(boost::tp::get_default_pool());
- aetst::do_test_join_all_until(ae);
-}
-
-void do_test_join_all_for() {
- //pool_type ae(boost::tp::poolsize(2));
- pool_type ae(boost::tp::get_default_pool());
- aetst::do_test_join_all_for(ae);
-}
-
-void do_test_thread_interrupts_at_interruption_point() {
- //pool_type ae(boost::tp::poolsize(2));
- pool_type ae(boost::tp::get_default_pool());
- aetst::do_test_thread_interrupts_at_interruption_point_m(ae);
-}
-
-void do_test_wait_all() {
- //pool_type ae(boost::tp::poolsize(2));
- pool_type ae(boost::tp::get_default_pool());
- aetst::do_test_wait_all(ae);
-}
-
-void do_test_wait_all_until() {
- //pool_type ae(boost::tp::poolsize(2));
- pool_type ae(boost::tp::get_default_pool());
- aetst::do_test_wait_all_until(ae);
-}
-
-void do_test_wait_all_for() {
- //pool_type ae(boost::tp::poolsize(2));
- pool_type ae(boost::tp::get_default_pool());
- aetst::do_test_wait_all_for(ae);
-}
-
-void do_test_wait_for_any() {
- //pool_type ae(boost::tp::poolsize(2));
- pool_type ae(boost::tp::get_default_pool());
- aetst::do_test_wait_for_any(ae);
-}
-
-void do_test_set_all() {
- //pool_type ae(boost::tp::poolsize(2));
- pool_type ae(boost::tp::get_default_pool());
- aetst::do_test_set_all(ae);
-}
-
-void do_test_get() {
- //pool_type ae(boost::tp::poolsize(2));
- pool_type ae(boost::tp::get_default_pool());
- aetst::do_test_get(ae);
-}
-
-
-void do_test_get_all() {
- //pool_type ae(boost::tp::poolsize(2));
- pool_type ae(boost::tp::get_default_pool());
- aetst::do_test_set_all(ae);
-}
-
-void do_test_wait_for_all() {
- //pool_type ae(boost::tp::poolsize(2));
- pool_type ae(boost::tp::get_default_pool());
- aetst::do_test_wait_for_all(ae);
-}
-#if 0
-void do_test_fork_after_wait() {
- //pool_type ae(boost::tp::poolsize(2));
- pool_type ae(boost::tp::get_default_pool());
- aetst::do_test_fork_after_wait(ae);
-}
-void do_test_fork_after_get() {
- //pool_type ae(boost::tp::poolsize(2));
- pool_type ae(boost::tp::get_default_pool());
- aetst::do_test_fork_after_get(ae);
-}
-#endif
-
-test_suite* init_unit_test_suite(int, char*[])
-{
- test_suite* test = BOOST_TEST_SUITE("scheduler");
-
-#if 0 // DO NOT WORK UNTIL tp::task has a fork member
- test->add(BOOST_TEST_CASE(&do_test_member_fork_detach));
- test->add(BOOST_TEST_CASE(&do_test_member_fork));
- test->add(BOOST_TEST_CASE(&do_test_member_fork_bind));
-#endif
- test->add(BOOST_TEST_CASE(&do_test_fork));
- test->add(BOOST_TEST_CASE(&do_test_fork_1));
- test->add(BOOST_TEST_CASE(&do_test_thread_interrupts_at_interruption_point));
- test->add(BOOST_TEST_CASE(&do_test_creation_through_functor));
-#if 0 // DO NOT WORK YET
- test->add(BOOST_TEST_CASE(&do_test_creation_through_reference_wrapper));
-#endif
-
- test->add(BOOST_TEST_CASE(&do_test_get));
- test->add(BOOST_TEST_CASE(&do_test_wait));
- test->add(BOOST_TEST_CASE(&do_test_wait_until));
- test->add(BOOST_TEST_CASE(&do_test_wait_for));
-
- test->add(BOOST_TEST_CASE(&do_test_wait_all));
- test->add(BOOST_TEST_CASE(&do_test_wait_all_until));
- test->add(BOOST_TEST_CASE(&do_test_wait_all_for));
- test->add(BOOST_TEST_CASE(&do_test_set_all));
- test->add(BOOST_TEST_CASE(&do_test_get_all));
-
- test->add(BOOST_TEST_CASE(&do_test_join));
- test->add(BOOST_TEST_CASE(&do_test_join_until));
- test->add(BOOST_TEST_CASE(&do_test_join_for));
- test->add(BOOST_TEST_CASE(&do_test_join_all));
- test->add(BOOST_TEST_CASE(&do_test_join_all_until));
- test->add(BOOST_TEST_CASE(&do_test_join_all_for));
-
-
- test->add(BOOST_TEST_CASE(&do_test_wait_for_all));
-
-#if 0 // DO NOT WORK YET
- test->add(BOOST_TEST_CASE(&do_test_wait_for_any));
- test->add(BOOST_TEST_CASE(&do_test_fork_after_wait));
- test->add(BOOST_TEST_CASE(&do_test_fork_after_get));
-#endif
-
- return test;
-}

Deleted: sandbox/interthreads/libs/interthreads/test/test_thread_shared_ptr.cpp
==============================================================================
--- sandbox/interthreads/libs/interthreads/test/test_thread_shared_ptr.cpp 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
+++ (empty file)
@@ -1,159 +0,0 @@
-//////////////////////////////////////////////////////////////////////////////
-//
-// (C) Copyright Roland Schwarz 2006.
-// (C) Copyright Vicente J. Botet Escriba 2008-2009.
-// Distributed under the Boost Software License, Version 1.0.
-// (See accompanying file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
-//
-// See http://www.boost.org/libs/interthreads for documentation.
-//
-// Based on the shared.cpp example from the threadalert library of Roland Schwarz
-//////////////////////////////////////////////////////////////////////////////
-#include <boost/thread/mutex.hpp>
-boost::mutex out_global_mutex;
-#include <boost/thread/locks.hpp>
-#include <boost/thread.hpp>
-#include <iostream>
-#include <boost/interthreads/thread_specific_shared_ptr.hpp>
-#include <boost/interthreads/thread_decorator.hpp>
-
-void sleep(int sec)
-{
- boost::xtime t;
- boost::xtime_get(&t,1); t.sec += sec; boost::thread::sleep(t);
-}
-
-// A state class living in shared memory.
-// The class must have its own sync mechanism.
-class state {
-public:
- state() : result(0)
- {}
- void set_result(int n)
- {
- boost::mutex::scoped_lock lock(monitor);
- result = n;
- }
- int get_result()
- {
- boost::mutex::scoped_lock lock(monitor);
- return result;
- }
- static void deleter(state * p) { delete p; }
-private:
- ~state() {}
- boost::mutex monitor;
- int result;
-};
-
-// The conventional tss pointer.
-// It can be seen as a memory space that is
-// only privately accessible by the thread,
-// when interpreted in our context.
-boost::thread_specific_ptr<int> private_int;
-
-// The thread member pointer.
-// Its syntax is almost the same when used
-// from "inside" a thread as that of the
-// thread_specific_ptr. I named it public
-// to underpin the fact it is accessible
-// from "outside" too. (Perhaps other names
-// than thread_specific_shared_ptr and thread_specific_ptr
-// would be more appropriate? Any suggestions?
-// E.g. thread_public_ptr and thread_private_ptr?)
-boost::interthreads::thread_specific_shared_ptr<state> public_state;
-
-// It might be convenient to have a function
-// that is called automatically on thread start
-// up to auto initialize the variables.
-void init_state_fn()
-{
- {
- boost::mutex::scoped_lock out_guard(out_global_mutex);
- std::cout << "init_state_fn" << " " << boost::this_thread::get_id()<<std::endl;
- }
-
- public_state.reset(new state(), state::deleter);
- private_int.reset(new int(0));
-}
-
-boost::interthreads::thread_decoration init_state(init_state_fn);
-
-
-void run()
-{
- init_state_fn();
- sleep(2);
- {
- boost::mutex::scoped_lock out_guard(out_global_mutex);
- std::cout << "run " << " " << boost::this_thread::get_id()<<std::endl;
- }
- public_state->set_result(42);
-
- boost::shared_ptr<state> ths = public_state[boost::this_thread::get_id()];
- int result;
- result = ths->get_result();
- {
- boost::mutex::scoped_lock out_guard(out_global_mutex);
- std::cout << "ahead " << result << " " << boost::this_thread::get_id()<<std::endl;
- }
- sleep(2);
-
-}
-
-int main(int argc, char* argv[])
-{
- int result;
-
- boost::thread* th = new boost::thread(boost::interthreads::make_decorator(run));
-
- const boost::shared_ptr<state> ths = public_state.wait_and_get(th->get_id());
- if (ths.get()!=0) {
- result = ths->get_result();
- {
- boost::mutex::scoped_lock out_guard(out_global_mutex);
- std::cout << "ahead " << result << " " << boost::this_thread::get_id()<<std::endl;
- }
- }
-
- private_int.reset(new int(0));
- ths->set_result(1111);
- if (ths.get()!=0) {
- result = ths->get_result();
- {
- boost::mutex::scoped_lock out_guard(out_global_mutex);
- std::cout << "ahead " << result << " " << boost::this_thread::get_id()<<std::endl;
- }
- }
-
- sleep(2);
- boost::shared_ptr<state> ths3 = public_state[th->get_id()];
- if (ths.get()!=0) {
- result = ths->get_result();
- {
- boost::mutex::scoped_lock out_guard(out_global_mutex);
- std::cout << "ahead " << result << " " << boost::this_thread::get_id()<<std::endl;
- }
- }
-
- th->join();
-
- delete th;
-
- // We still may access the state object by means of the shared_ptr.
- if (ths.get()!=0) {
- result = ths->get_result();
- {
- boost::mutex::scoped_lock out_guard(out_global_mutex);
- std::cout << "ahead " << result << " " << boost::this_thread::get_id()<<std::endl;
- }
- }
- const boost::shared_ptr<state> cths(new state(), state::deleter);
- cths->set_result(2);
- {
- boost::mutex::scoped_lock out_guard(out_global_mutex);
- std::cout << "xxx" << cths->get_result() << " " << boost::this_thread::get_id()<<std::endl;
- }
- return 0;
-}
-

Deleted: sandbox/interthreads/libs/interthreads/test/test_threader.cpp
==============================================================================
--- sandbox/interthreads/libs/interthreads/test/test_threader.cpp 2009-05-02 06:40:59 EDT (Sat, 02 May 2009)
+++ (empty file)
@@ -1,286 +0,0 @@
-//////////////////////////////////////////////////////////////////////////////
-//
-// (C) Copyright Vicente J. Botet Escriba 2008-2009. Distributed under the Boost
-// Software License, Version 1.0. (See accompanying file
-// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
-//
-// See http://www.boost.org/libs/sync for documentation.
-//
-//////////////////////////////////////////////////////////////////////////////
-
-#include "boost/thread/mutex.hpp"
-#include "boost/thread/locks.hpp"
-
-#include "boost/interthreads/typeof/launcher.hpp"
-#include "boost/interthreads/typeof/threader.hpp"
-#include "boost/interthreads/typeof/future.hpp"
-#include "boost/interthreads/algorithm.hpp"
-#include "boost/interthreads/fork_after.hpp"
-#include <boost/typeof/typeof.hpp>
-
-#include <libs/interthreads/test/data_types.hpp>
-#include <libs/interthreads/test/test_ae.hpp>
-
-#include <iostream>
-#include <string>
-#include <boost/test/unit_test.hpp>
-
-using namespace boost::unit_test;
-namespace bith = boost::interthreads;
-namespace bfus = boost::fusion;
-
-
-
-void do_test_member_fork_detach() {
- bith::shared_threader ae;
- aetst::do_test_member_fork_detach(ae);
-}
-
-void do_test_member_fork() {
- bith::shared_threader ae;
- aetst::do_test_member_fork(ae);
-}
-
-#if 0
-void do_test_member_lazy_fork() {
- bith::shared_threader ae;
- aetst::do_test_member_lazy_fork(ae);
-}
-#endif
-
-void do_test_member_fork_move_unique() {
- bith::unique_threader ae;
- aetst::do_test_member_fork_m_fut(ae);
-}
-
-void do_test_member_fork_bind() {
- bith::shared_threader ae;
- aetst::do_test_member_fork_bind(ae);
-}
-
-void do_test_fork() {
- bith::shared_threader ae;
- aetst::do_test_fork(ae);
-}
-
-void do_test_fork_1() {
- bith::shared_threader ae;
- aetst::do_test_fork_1(ae);
-}
-
-void do_test_creation_through_reference_wrapper()
-{
- bith::shared_threader ae;
- aetst::do_test_creation_through_reference_wrapper(ae);
-}
-
-void do_test_creation_through_functor()
-{
- bith::shared_threader ae;
- aetst::do_test_creation_through_functor(ae);
-}
-
-void do_test_wait() {
- bith::shared_threader ae;
- aetst::do_test_wait(ae);
-}
-
-void do_test_wait_until() {
- bith::shared_threader ae;
- aetst::do_test_wait_until(ae);
-}
-
-void do_test_wait_for() {
- bith::shared_threader ae;
- aetst::do_test_wait_for(ae);
-}
-
-void do_test_join() {
- bith::shared_threader ae;
- aetst::do_test_join(ae);
-}
-
-void do_test_join_until() {
- bith::shared_threader ae;
- aetst::do_test_join_until(ae);
-}
-
-void do_test_join_for() {
- bith::shared_threader ae;
- aetst::do_test_join_for(ae);
-}
-
-
-void do_test_thread_interrupts_at_interruption_point() {
- bith::shared_threader ae;
- aetst::do_test_thread_interrupts_at_interruption_point(ae);
-}
-
-void do_test_join_all() {
- bith::shared_threader ae;
- aetst::do_test_join_all(ae);
-}
-
-void do_test_join_all_until() {
- bith::shared_threader ae;
- aetst::do_test_join_all_until(ae);
-}
-
-void do_test_join_all_for() {
- bith::shared_threader ae;
- aetst::do_test_join_all_for(ae);
-}
-
-void do_test_wait_all() {
- bith::shared_threader ae;
- aetst::do_test_wait_all(ae);
-}
-
-void do_test_wait_all_until() {
- bith::shared_threader ae;
- aetst::do_test_wait_all_until(ae);
-}
-
-void do_test_wait_all_for() {
- bith::shared_threader ae;
- aetst::do_test_wait_all_for(ae);
-}
-
-void do_test_wait_for_any() {
- bith::shared_threader ae;
- aetst::do_test_wait_for_any(ae);
-}
-
-template<typename AE>
-struct waiter_add {
- waiter_add(boost::detail::future_waiter& waiter) : waiter_(waiter) {}
- boost::detail::future_waiter& waiter_;
- typedef void result_type;
- template<typename ACT>
- void operator()(ACT& act) const {
- waiter_.add(bith::get_future<AE>()(act));
- }
-};
-
-
-template<typename AE, typename FusionSequence>
-unsigned my_wait_for_any(FusionSequence& seq) {
- boost::detail::future_waiter waiter;
- boost::fusion::for_each(seq, waiter_add<AE>(waiter));
- return waiter.wait();
-}
-
-void do_test_wait_for_any_fusion_sequence()
-{
- typedef bith::shared_threader AE;
- AE ae;
- typedef bith::result_of::fork_all<AE,bfus::tuple<int(*)(),std::string(*)()> >::type type;
- type tple = bith::fork_all(ae, simple_thread, simple_string_thread);
- unsigned r = my_wait_for_any<AE>(tple);
- bith::interrupt_all(tple);
- BOOST_CHECK_EQUAL(r, 0u);
- boost::this_thread::sleep(boost::posix_time::milliseconds(5000));
- std::cout << "<<do_test_wait_for_any_fusion_sequence" << std::endl;
-
-}
-
-void do_test_get() {
- bith::shared_launcher ae;
- aetst::do_test_get(ae);
-}
-
-void do_test_get_all() {
- bith::shared_threader ae;
- aetst::do_test_set_all(ae);
-}
-
-void do_test_set_all() {
- bith::shared_threader ae;
- aetst::do_test_set_all(ae);
-}
-
-void do_test_wait_for_all() {
- bith::shared_threader ae;
- aetst::do_test_wait_for_all(ae);
-}
-
-void do_test_fork_after_join() {
- bith::shared_threader ae;
- aetst::do_test_fork_after_join(ae);
-}
-
-void do_test_fork_after_wait() {
- bith::shared_threader ae;
- aetst::do_test_fork_after_wait(ae);
-}
-
-void do_test_fork_after_get() {
- bith::shared_threader ae;
- aetst::do_test_fork_after_get(ae);
-}
-
-void do_test_other() {
- boost::mutex mtx_;
- int i=0;
- for (boost::mutex::scoped_lock lock_(mtx_), *continue_hlp_,**continue_=&continue_hlp_; continue_; continue_=0) {
- i++;
- }
- BOOST_CHECK_EQUAL(i, 1);
-
- for (boost::mutex::scoped_lock lock_(mtx_), *continue_=&lock_; continue_; continue_=0) {
- i++;
- }
- BOOST_CHECK_EQUAL(i, 2);
- if (bool __stop = false) {} else
- for (boost::mutex::scoped_lock lock_(mtx_) ; !__stop; __stop= true) {
- i++;
- }
- BOOST_CHECK_EQUAL(i, 3);
-}
-
-test_suite* init_unit_test_suite(int, char*[])
-{
- test_suite* test = BOOST_TEST_SUITE("shared_threader");
-
-
- test->add(BOOST_TEST_CASE(&do_test_member_fork));
- test->add(BOOST_TEST_CASE(&do_test_member_fork_bind));
- test->add(BOOST_TEST_CASE(&do_test_fork));
- test->add(BOOST_TEST_CASE(&do_test_fork_1));
- test->add(BOOST_TEST_CASE(&do_test_creation_through_functor));
- test->add(BOOST_TEST_CASE(&do_test_creation_through_reference_wrapper));
-
- test->add(BOOST_TEST_CASE(&do_test_get));
- test->add(BOOST_TEST_CASE(&do_test_wait));
- test->add(BOOST_TEST_CASE(&do_test_wait_until));
- test->add(BOOST_TEST_CASE(&do_test_wait_for));
-
- test->add(BOOST_TEST_CASE(&do_test_wait_all));
- test->add(BOOST_TEST_CASE(&do_test_wait_all_until));
- test->add(BOOST_TEST_CASE(&do_test_wait_all_for));
- test->add(BOOST_TEST_CASE(&do_test_set_all));
- test->add(BOOST_TEST_CASE(&do_test_get_all));
- test->add(BOOST_TEST_CASE(&do_test_member_fork_detach));
- test->add(BOOST_TEST_CASE(&do_test_thread_interrupts_at_interruption_point));
- test->add(BOOST_TEST_CASE(&do_test_join));
- test->add(BOOST_TEST_CASE(&do_test_join_until));
- test->add(BOOST_TEST_CASE(&do_test_join_for));
- test->add(BOOST_TEST_CASE(&do_test_join_all));
- test->add(BOOST_TEST_CASE(&do_test_join_all_until));
- test->add(BOOST_TEST_CASE(&do_test_join_all_for));
- test->add(BOOST_TEST_CASE(&do_test_wait_for_all));
- test->add(BOOST_TEST_CASE(&do_test_wait_for_any));
- test->add(BOOST_TEST_CASE(&do_test_wait_for_any_fusion_sequence));
- test->add(BOOST_TEST_CASE(&do_test_fork_after_join));
- test->add(BOOST_TEST_CASE(&do_test_fork_after_wait));
- test->add(BOOST_TEST_CASE(&do_test_fork_after_get));
-
-#if 0
- test->add(BOOST_TEST_CASE(&do_test_member_lazy_fork));
- test->add(BOOST_TEST_CASE(&do_test_other));
- test_suite* test = BOOST_TEST_SUITE("unique_threader");
-
- test->add(BOOST_TEST_CASE(&do_test_member_fork_move_unique));
-#endif
- return test;
-}


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