Boost logo

Boost-Commit :

From: stipe_at_[hidden]
Date: 2007-12-04 01:17:14


Author: srajko
Date: 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
New Revision: 41674
URL: http://svn.boost.org/trac/boost/changeset/41674

Log:
* Move functionality from port related concepts to the component concepts.
* Adapt the Dataflow.Signals layer and tests (most of the rest still broken).
* Start adding Doxygen-generated support layer reference.
Added:
   sandbox/SOC/2007/signals/boost/dataflow/support/default_port_provider.hpp (contents, props changed)
   sandbox/SOC/2007/signals/boost/dataflow/support/detail/
   sandbox/SOC/2007/signals/boost/dataflow/support/detail/make_specializable_operation.hpp (contents, props changed)
   sandbox/SOC/2007/signals/boost/dataflow/support/fusion_component.hpp (contents, props changed)
   sandbox/SOC/2007/signals/boost/dataflow/support/port/category.hpp
      - copied, changed from r41445, /sandbox/SOC/2007/signals/boost/dataflow/support/port.hpp
   sandbox/SOC/2007/signals/boost/dataflow/support/port/default_port_provider.hpp
      - copied, changed from r41445, /sandbox/SOC/2007/signals/boost/dataflow/support/port.hpp
   sandbox/SOC/2007/signals/boost/dataflow/support/port/port.hpp
      - copied, changed from r41445, /sandbox/SOC/2007/signals/boost/dataflow/support/port.hpp
   sandbox/SOC/2007/signals/boost/dataflow/support/port/port_adapter.hpp (contents, props changed)
   sandbox/SOC/2007/signals/boost/dataflow/support/port/traits.hpp
      - copied, changed from r41445, /sandbox/SOC/2007/signals/boost/dataflow/support/port.hpp
   sandbox/SOC/2007/signals/libs/dataflow/doc/support/concepts/
      - copied from r41445, /sandbox/SOC/2007/signals/libs/dataflow/doc/concepts/
   sandbox/SOC/2007/signals/libs/dataflow/doc/support/concepts/binary_operable.qbk
      - copied, changed from r41673, /sandbox/SOC/2007/signals/libs/dataflow/doc/concepts/binary_operable.qbk
   sandbox/SOC/2007/signals/libs/dataflow/doc/support/concepts/component.qbk
      - copied, changed from r41673, /sandbox/SOC/2007/signals/libs/dataflow/doc/concepts/component.qbk
   sandbox/SOC/2007/signals/libs/dataflow/doc/support/concepts/concepts.qbk
      - copied, changed from r41673, /sandbox/SOC/2007/signals/libs/dataflow/doc/concepts/concepts.qbk
   sandbox/SOC/2007/signals/libs/dataflow/doc/support/concepts/port.qbk
      - copied, changed from r41673, /sandbox/SOC/2007/signals/libs/dataflow/doc/concepts/port.qbk
   sandbox/SOC/2007/signals/libs/dataflow/doc/support/concepts/unary_operable.qbk
      - copied, changed from r41673, /sandbox/SOC/2007/signals/libs/dataflow/doc/concepts/unary_operable.qbk
   sandbox/SOC/2007/signals/libs/dataflow/doc/support/support.qbk (contents, props changed)
   sandbox/SOC/2007/signals/libs/dataflow/test/my_producer_consumer_operations.hpp (contents, props changed)
Removed:
   sandbox/SOC/2007/signals/boost/dataflow/support/common.hpp
   sandbox/SOC/2007/signals/boost/dataflow/support/filter.hpp
   sandbox/SOC/2007/signals/libs/dataflow/doc/concepts/
Text files modified:
   sandbox/SOC/2007/signals/boost/dataflow/blueprint/get_port.hpp | 4
   sandbox/SOC/2007/signals/boost/dataflow/connection/port_map.hpp | 43 +------
   sandbox/SOC/2007/signals/boost/dataflow/signals/component/chain.hpp | 13 +
   sandbox/SOC/2007/signals/boost/dataflow/signals/component/condition.hpp | 12 +
   sandbox/SOC/2007/signals/boost/dataflow/signals/component/counter.hpp | 23 ++--
   sandbox/SOC/2007/signals/boost/dataflow/signals/component/detail/generic_template.hpp | 38 +++---
   sandbox/SOC/2007/signals/boost/dataflow/signals/component/filter.hpp | 106 ++++++++++++-------
   sandbox/SOC/2007/signals/boost/dataflow/signals/component/filter_base.hpp | 52 ++++----
   sandbox/SOC/2007/signals/boost/dataflow/signals/component/function.hpp | 16 +-
   sandbox/SOC/2007/signals/boost/dataflow/signals/component/junction.hpp | 22 ++--
   sandbox/SOC/2007/signals/boost/dataflow/signals/component/multiplexer.hpp | 44 +++----
   sandbox/SOC/2007/signals/boost/dataflow/signals/component/mutex.hpp | 8
   sandbox/SOC/2007/signals/boost/dataflow/signals/component/socket_receiver.hpp | 9
   sandbox/SOC/2007/signals/boost/dataflow/signals/component/storage.hpp | 62 ++++------
   sandbox/SOC/2007/signals/boost/dataflow/signals/component/timed_generator.hpp | 8
   sandbox/SOC/2007/signals/boost/dataflow/signals/connection/operators.hpp | 91 ++-------------
   sandbox/SOC/2007/signals/boost/dataflow/signals/connection/slot_selector.hpp | 16 --
   sandbox/SOC/2007/signals/boost/dataflow/signals/support.hpp | 70 ++++--------
   sandbox/SOC/2007/signals/boost/dataflow/support.hpp | 2
   sandbox/SOC/2007/signals/boost/dataflow/support/binary_operation.hpp | 101 +++++-------------
   sandbox/SOC/2007/signals/boost/dataflow/support/complemented_port.hpp | 19 +-
   sandbox/SOC/2007/signals/boost/dataflow/support/component.hpp | 177 +++++++++++++++++++++++++++-----
   sandbox/SOC/2007/signals/boost/dataflow/support/keyed_port.hpp | 69 ++++--------
   sandbox/SOC/2007/signals/boost/dataflow/support/port.hpp | 196 -----------------------------------
   sandbox/SOC/2007/signals/boost/dataflow/support/port/category.hpp | 196 +++--------------------------------
   sandbox/SOC/2007/signals/boost/dataflow/support/port/default_port_provider.hpp | 218 ++++++---------------------------------
   sandbox/SOC/2007/signals/boost/dataflow/support/port/detail/port_traits_sequence.hpp | 22 +--
   sandbox/SOC/2007/signals/boost/dataflow/support/port/port.hpp | 205 +++++--------------------------------
   sandbox/SOC/2007/signals/boost/dataflow/support/port/traits.hpp | 202 +++++++++++++++----------------------
   sandbox/SOC/2007/signals/boost/dataflow/support/reflective_component.hpp | 14 +-
   sandbox/SOC/2007/signals/boost/dataflow/support/tags.hpp | 45 ++++++-
   sandbox/SOC/2007/signals/boost/dataflow/support/unary_operation.hpp | 67 ++---------
   sandbox/SOC/2007/signals/boost/dataflow/templates/binary_operation.hpp | 11 +
   sandbox/SOC/2007/signals/boost/dataflow/templates/operator.hpp | 61 +++-------
   sandbox/SOC/2007/signals/libs/dataflow/build/xcodeide/signal_network.xcodeproj/project.pbxproj | 96 +++++++++++-----
   sandbox/SOC/2007/signals/libs/dataflow/doc/Jamfile.v2 | 59 +++++----
   sandbox/SOC/2007/signals/libs/dataflow/doc/components.qbk | 10
   sandbox/SOC/2007/signals/libs/dataflow/doc/dataflow.qbk | 85 ++++++++------
   sandbox/SOC/2007/signals/libs/dataflow/doc/future.qbk | 4
   sandbox/SOC/2007/signals/libs/dataflow/doc/introduction/distributed_example.qbk | 16 +-
   sandbox/SOC/2007/signals/libs/dataflow/doc/introduction/gil_example.qbk | 2
   sandbox/SOC/2007/signals/libs/dataflow/doc/introduction/introduction.qbk | 13 +
   sandbox/SOC/2007/signals/libs/dataflow/doc/introduction/vtk_example.qbk | 48 ++++----
   sandbox/SOC/2007/signals/libs/dataflow/doc/phoenix/concepts.qbk | 26 ++--
   sandbox/SOC/2007/signals/libs/dataflow/doc/rationale.qbk | 8
   sandbox/SOC/2007/signals/libs/dataflow/doc/signals/components.qbk | 70 ++++++------
   sandbox/SOC/2007/signals/libs/dataflow/doc/signals/concepts.qbk | 38 +++---
   sandbox/SOC/2007/signals/libs/dataflow/doc/signals/connections.qbk | 12 +-
   sandbox/SOC/2007/signals/libs/dataflow/doc/support/concepts/binary_operable.qbk | 20 +-
   sandbox/SOC/2007/signals/libs/dataflow/doc/support/concepts/component.qbk | 32 ++--
   sandbox/SOC/2007/signals/libs/dataflow/doc/support/concepts/concepts.qbk | 20 +-
   sandbox/SOC/2007/signals/libs/dataflow/doc/support/concepts/port.qbk | 181 +++++++++++++++++---------------
   sandbox/SOC/2007/signals/libs/dataflow/doc/support/concepts/unary_operable.qbk | 4
   sandbox/SOC/2007/signals/libs/dataflow/example/Jamfile.v2 | 10
   sandbox/SOC/2007/signals/libs/dataflow/example/VTK/vtk_dataflow_support.hpp | 6
   sandbox/SOC/2007/signals/libs/dataflow/example/example.cpp | 8 +
   sandbox/SOC/2007/signals/libs/dataflow/test/Jamfile.v2 | 4
   sandbox/SOC/2007/signals/libs/dataflow/test/my_producer_consumer.hpp | 2
   sandbox/SOC/2007/signals/libs/dataflow/test/signals/Jamfile.v2 | 2
   sandbox/SOC/2007/signals/libs/dataflow/test/signals/test_branching.cpp | 11 +
   sandbox/SOC/2007/signals/libs/dataflow/test/signals/test_chain.cpp | 4
   sandbox/SOC/2007/signals/libs/dataflow/test/signals/test_connect.cpp | 17 ++
   sandbox/SOC/2007/signals/libs/dataflow/test/signals/test_disconnect.cpp | 38 ------
   sandbox/SOC/2007/signals/libs/dataflow/test/signals/test_filter.cpp | 51 ++++++---
   sandbox/SOC/2007/signals/libs/dataflow/test/signals/test_junction.cpp | 8
   sandbox/SOC/2007/signals/libs/dataflow/test/signals/test_multi_args.cpp | 2
   sandbox/SOC/2007/signals/libs/dataflow/test/signals/test_multi_out.cpp | 2
   sandbox/SOC/2007/signals/libs/dataflow/test/signals/test_pull.cpp | 2
   sandbox/SOC/2007/signals/libs/dataflow/test/signals/test_storage.cpp | 9 +
   sandbox/SOC/2007/signals/libs/dataflow/test/test_binary_op.cpp | 54 ++-------
   sandbox/SOC/2007/signals/libs/dataflow/test/test_component.cpp | 50 +++++++-
   sandbox/SOC/2007/signals/libs/dataflow/test/test_keyed_port.cpp | 24 ++--
   sandbox/SOC/2007/signals/libs/dataflow/test/test_port.cpp | 62 +++++------
   sandbox/SOC/2007/signals/libs/dataflow/test/test_reflective_component.cpp | 6
   sandbox/SOC/2007/signals/libs/dataflow/test/test_unary_op.cpp | 15 ++
   75 files changed, 1335 insertions(+), 2038 deletions(-)

Modified: sandbox/SOC/2007/signals/boost/dataflow/blueprint/get_port.hpp
==============================================================================
--- sandbox/SOC/2007/signals/boost/dataflow/blueprint/get_port.hpp (original)
+++ sandbox/SOC/2007/signals/boost/dataflow/blueprint/get_port.hpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -30,11 +30,11 @@
                 typename component_traits_of<Component>::type::ports,
                 Case::value
>::type,
- typename get_component_port_result_type<
+ typename get_port_result_type<
                 mpl::int_<Case::value>,
                 Component
>::type
- >(get_component_port<mpl::int_<Case::value>, Component >(c))); \
+ >(get_port<mpl::int_<Case::value>, Component >(c))); \
     }
     get_port_case(Component& c, std::auto_ptr<port> &ret) : c(c), ret(ret)
     {}

Modified: sandbox/SOC/2007/signals/boost/dataflow/connection/port_map.hpp
==============================================================================
--- sandbox/SOC/2007/signals/boost/dataflow/connection/port_map.hpp (original)
+++ sandbox/SOC/2007/signals/boost/dataflow/connection/port_map.hpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -18,44 +18,21 @@
 
 namespace boost { namespace dataflow {
 
-template<typename Mechanism, typename PortCategory>
+template<typename PortCategory, typename Tag=default_tag>
 struct fusion_map_port
- : public port_traits<Mechanism, PortCategory, concepts::keyed_port> {};
+ : public port_traits<PortCategory, concepts::keyed_port, Tag> {};
 
-template<typename Mechanism, typename PortCategory, typename T>
+template<typename PortCategory, typename T, typename Tag=default_tag>
 class port_map
 {
- struct get_proxied_object
- {
- typename port_map::proxy_port_for & operator()(const port_map &map)
- {
- return boost::fusion::front(map.t).second;
- }
- };
-// typedef typename boost::fusion::result_of::value_at_c<T, 0>::type::second_type
-// proxy_consumer_for;
- typedef
- typename boost::remove_reference<
- typename boost::remove_const<
- typename boost::remove_reference<
- typename boost::fusion::result_of::front<T>::type
- >::type
- >::type::second_type
- >::type proxy_port_for;
+
 public:
- typedef Mechanism mechanism_type;
- typedef PortCategory port_category_type;
     typedef T map_type;
     
     port_map(const T& t) : t(t) {}
     map_type &map() const {return t;}
     
- typedef fusion_map_port<Mechanism, PortCategory> port_traits;
- typedef mutable_proxy_port<
- Mechanism,
- typename PortCategory::complement,
- proxy_port_for,
- get_proxied_object> proxy_port_traits;
+ typedef fusion_map_port<PortCategory, Tag> port_traits;
 
 private:
     mutable map_type t;
@@ -63,17 +40,17 @@
 
 namespace extension
 {
- template<typename Mechanism, typename PortCategory, typename KeyTag>
- struct get_keyed_port_impl<fusion_map_port<Mechanism, PortCategory>, KeyTag>
+ template<typename PortCategory, typename Tag, typename KeyPortTraits>
+ struct get_keyed_port_impl<fusion_map_port<PortCategory, Tag>, KeyPortTraits>
     {
- template<typename Args> struct result;
+ template<typename FArgs> struct result;
         
         template<typename F, typename KeyedPort>
         struct result<F(KeyedPort &)>
         {
             typedef typename boost::fusion::result_of::at_key<
                 typename KeyedPort::map_type,
- KeyTag
+ KeyPortTraits
>::type type;
         };
 
@@ -82,7 +59,7 @@
             operator()(KeyedPort &port)
         {
             return boost::fusion::at_key<
- KeyTag
+ KeyPortTraits
>(port.map());
         }
     };

Modified: sandbox/SOC/2007/signals/boost/dataflow/signals/component/chain.hpp
==============================================================================
--- sandbox/SOC/2007/signals/boost/dataflow/signals/component/chain.hpp (original)
+++ sandbox/SOC/2007/signals/boost/dataflow/signals/component/chain.hpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -16,10 +16,13 @@
 
 namespace boost { namespace signals {
 
+template<typename Signature, typename T>
+class chain;
+
 namespace detail
 {
     template<typename Signature, typename T>
- class chain_impl : public filter_base<typename T::signal_type>
+ class chain_impl : public filter_base<chain<Signature, T>, typename T::signal_type>
     {
     protected:
         typedef typename boost::function_types::parameter_types<Signature>::type parameter_types;
@@ -49,13 +52,13 @@
             return boost::fusion::fused<T &>(components[0])(vec_par);
         }
         /// The default signal coming out of the chain is the default signal of the last component in the chain.
- typename T::signal_type &default_signal() const
+/* typename T::signal_type &default_signal() const
         {
             return components[size-1].default_signal();
- }
- typename T::signal_type &get_proxied_producer() const
+ }*/
+ typename T::signal_type &default_signal() const
         {
- return boost::dataflow::get_port<dataflow::signals::mechanism, dataflow::ports::producer>(components[size-1]);
+ return boost::dataflow::get_default_port<dataflow::directions::outgoing, dataflow::signals::connect_mechanism, dataflow::signals::tag >(components[size-1]);
         }
     private:
         void initialize(size_t copies, T *component=NULL)

Modified: sandbox/SOC/2007/signals/boost/dataflow/signals/component/condition.hpp
==============================================================================
--- sandbox/SOC/2007/signals/boost/dataflow/signals/component/condition.hpp (original)
+++ sandbox/SOC/2007/signals/boost/dataflow/signals/component/condition.hpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -37,14 +37,16 @@
 */
 template<typename Signature,
     typename OutSignal=SIGNAL_NETWORK_DEFAULT_OUT,
- typename Combiner = boost::last_value<typename boost::function_types::result_type<Signature>::type>,
- typename Group = int,
- typename GroupCompare = std::less<Group>
+ typename SignalArgs=typename default_signal_args<Signature>::type
>
 class condition : public
- applicator<detail::cond_and_mutex, detail::notify_all, Signature, OutSignal, Combiner, Group, GroupCompare>
+ applicator<
+ condition<Signature, OutSignal, SignalArgs>,
+ detail::cond_and_mutex, detail::notify_all, Signature, OutSignal, SignalArgs>
 {
- typedef applicator<detail::cond_and_mutex, detail::notify_all, Signature, OutSignal, Combiner, Group, GroupCompare> base_type;
+ typedef applicator<
+ condition<Signature, OutSignal, SignalArgs>,
+ detail::cond_and_mutex, detail::notify_all, Signature, OutSignal, SignalArgs> base_type;
 public:
     /** Initializes the internal counter to 0.
     */

Modified: sandbox/SOC/2007/signals/boost/dataflow/signals/component/counter.hpp
==============================================================================
--- sandbox/SOC/2007/signals/boost/dataflow/signals/component/counter.hpp (original)
+++ sandbox/SOC/2007/signals/boost/dataflow/signals/component/counter.hpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -27,18 +27,17 @@
     counter is an applicator with a postincrement application and default member of type volatile int.
     \param T Type of the internal counter variable.
 */
-template<typename Signature,
-typename OutSignal=SIGNAL_NETWORK_DEFAULT_OUT,
-typename T=int,
-typename Combiner = boost::last_value<typename boost::function_types::result_type<Signature>::type>,
-typename Group = int,
-typename GroupCompare = std::less<Group> >
-class counter : public applicator<T, detail::postincrement<T>, Signature, OutSignal, Combiner, Group, GroupCompare>
+template<
+ typename Signature,
+ typename OutSignal=SIGNAL_NETWORK_DEFAULT_OUT,
+ typename T=int,
+ typename SignalArgs=typename default_signal_args<Signature>::type
+ >
+class counter : public applicator<
+ counter<Signature, OutSignal, T, SignalArgs>,
+ T, detail::postincrement<T>, Signature, OutSignal, SignalArgs>
 {
-protected:
- typedef applicator<T, detail::postincrement<T>, Signature, OutSignal, Combiner, Group, GroupCompare> base_type;
 public:
-
     /** Initializes the internal counter to 0.
     */
     counter()
@@ -47,12 +46,12 @@
     /** Sets the internal counter to 0.
     */
     void reset()
- { base_type::member = 0; }
+ { counter::member = 0; }
 
     /** \return The internal signal counter.
     */
     T count() const
- { return base_type::member; }
+ { return counter::member; }
 };
 
 } } // namespace boost::signals

Modified: sandbox/SOC/2007/signals/boost/dataflow/signals/component/detail/generic_template.hpp
==============================================================================
--- sandbox/SOC/2007/signals/boost/dataflow/signals/component/detail/generic_template.hpp (original)
+++ sandbox/SOC/2007/signals/boost/dataflow/signals/component/detail/generic_template.hpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -25,22 +25,21 @@
 
 namespace detail
 {
- /** \brief fused implementation of conditional modifier
- */
- template<
+template<
+ typename Derived,
     typename SIGNAL_NETWORK_GENERIC_TYPENAME,
 #ifdef SIGNAL_NETWORK_GENERIC_TYPENAME2
     typename SIGNAL_NETWORK_GENERIC_TYPENAME2,
 #endif
     typename Signature,
- typename OutSignal=SIGNAL_NETWORK_DEFAULT_OUT,
- typename Combiner = boost::last_value<typename boost::function_types::result_type<Signature>::type>,
- typename Group = int,
- typename GroupCompare = std::less<Group> >
- class BOOST_PP_CAT(SIGNAL_NETWORK_GENERIC_CLASS,_impl) : public filter<Signature, typename OutSignal::filter_type, Combiner, Group, GroupCompare>
+ typename OutSignal,
+ typename SignalArgs
+ >
+class BOOST_PP_CAT(SIGNAL_NETWORK_GENERIC_CLASS,_impl)
+ : public filter<Derived, Signature, typename OutSignal::filter_type, SignalArgs>
 {
 protected:
- typedef filter<Signature, typename OutSignal::filter_type, Combiner, Group, GroupCompare> base_type;
+ typedef filter<Derived, Signature, typename OutSignal::filter_type, SignalArgs> base_type;
 
 public:
     SIGNAL_NETWORK_GENERIC_CLASS_IMPL() {}
@@ -65,35 +64,34 @@
 };
 }
 
-/** \brief Passes the incoming signal to a member modifier, and optionally forwards the returned result.
-*/
 template<
-typename SIGNAL_NETWORK_GENERIC_TYPENAME,
+ typename Derived,
+ typename SIGNAL_NETWORK_GENERIC_TYPENAME,
 #ifdef SIGNAL_NETWORK_GENERIC_TYPENAME2
-typename SIGNAL_NETWORK_GENERIC_TYPENAME2,
+ typename SIGNAL_NETWORK_GENERIC_TYPENAME2,
 #endif
-typename Signature,
-typename OutSignal=SIGNAL_NETWORK_DEFAULT_OUT,
-typename Combiner = boost::last_value<typename boost::function_types::result_type<Signature>::type>,
-typename Group = int,
-typename GroupCompare = std::less<Group> >
+ typename Signature,
+ typename OutSignal=SIGNAL_NETWORK_DEFAULT_OUT,
+ typename SignalArgs=typename default_signal_args<Signature>::type >
 class SIGNAL_NETWORK_GENERIC_CLASS
     : public boost::fusion::SIGNAL_NETWORK_GENERIC_UNFUSED_BASE
         <detail::SIGNAL_NETWORK_GENERIC_CLASS_IMPL<
+ Derived,
             SIGNAL_NETWORK_GENERIC_TYPENAME,
 #ifdef SIGNAL_NETWORK_GENERIC_TYPENAME2
             SIGNAL_NETWORK_GENERIC_TYPENAME2,
 #endif
- Signature, OutSignal, Combiner, Group, GroupCompare>,
+ Signature, OutSignal, SignalArgs>,
         typename boost::function_types::parameter_types<Signature>::type >
 {
     typedef boost::fusion::SIGNAL_NETWORK_GENERIC_UNFUSED_BASE
         <detail::SIGNAL_NETWORK_GENERIC_CLASS_IMPL<
+ Derived,
             SIGNAL_NETWORK_GENERIC_TYPENAME,
 #ifdef SIGNAL_NETWORK_GENERIC_TYPENAME2
             SIGNAL_NETWORK_GENERIC_TYPENAME2,
 #endif
- Signature, OutSignal, Combiner, Group, GroupCompare>,
+ Signature, OutSignal, SignalArgs>,
         typename boost::function_types::parameter_types<Signature>::type > base_type;
 public:
     SIGNAL_NETWORK_GENERIC_CLASS() {}

Modified: sandbox/SOC/2007/signals/boost/dataflow/signals/component/filter.hpp
==============================================================================
--- sandbox/SOC/2007/signals/boost/dataflow/signals/component/filter.hpp (original)
+++ sandbox/SOC/2007/signals/boost/dataflow/signals/component/filter.hpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -14,9 +14,7 @@
 #include <boost/fusion/include/as_vector.hpp>
 #include <boost/fusion/adapted/mpl.hpp>
 
-#ifndef SIGNAL_NETWORK_DEFAULT_OUT
 #define SIGNAL_NETWORK_DEFAULT_OUT unfused
-#endif
 
 namespace boost { namespace signals {
 
@@ -44,30 +42,62 @@
     typedef fused filter_type;
 };
 
+template<
+ typename Combiner,
+ typename Group=int,
+ typename GroupCompare=std::less<Group> >
+struct signal_args
+{
+ typedef Combiner combiner_type;
+ typedef Group group_type;
+ typedef GroupCompare group_compare_type;
+};
+
+template<typename Signature,
+ typename Combiner = boost::last_value<typename boost::function_traits<Signature>::result_type>,
+ typename Group = int,
+ typename GroupCompare = std::less<Group> >
+struct default_signal_args
+{
+ typedef signal_args<Combiner, Group, GroupCompare> type;
+};
+
+template<typename Signature, typename SignalArgs>
+struct signal_from_args
+{
+ typedef boost::signal<
+ Signature,
+ typename SignalArgs::combiner_type,
+ typename SignalArgs::group_type,
+ typename SignalArgs::group_compare_type
+ > type;
+};
+
 /// Provides a basis for filters (components that receive and send a signal).
 /** \param Signature The signature of the signal being sent out.
 
 Use this class as a base class for classes that produce a signal
 of a particular signature.
 */
-template<typename Signature,
-typename OutSignal=SIGNAL_NETWORK_DEFAULT_OUT,
-typename Combiner = boost::last_value<typename boost::function_traits<Signature>::result_type>,
-typename Group = int,
-typename GroupCompare = std::less<Group>
+template<
+ typename Derived,
+ typename Signature,
+ typename OutSignal=SIGNAL_NETWORK_DEFAULT_OUT,
+ typename SignalArgs=typename default_signal_args<Signature>::type
>
 class filter;
 
 /** \brief Unfused version of the filter class
 */
-template<typename Signature, typename Combiner, typename Group, typename GroupCompare>
-class filter<Signature, unfused, Combiner, Group, GroupCompare>
- : public filter_base<boost::signal<Signature, Combiner, Group, GroupCompare> >
+template<typename Derived, typename Signature, typename SignalArgs>
+class filter<Derived, Signature, unfused, SignalArgs>
+ : public filter_base<
+ Derived,
+ typename signal_from_args<Signature, SignalArgs>::type >
 {
 public:
     // the type of the signal
- typedef boost::signal<Signature, Combiner, Group, GroupCompare> signal_type;
-
+ typedef typename signal_from_args<Signature, SignalArgs>::type signal_type;
     // the signature of the output signal
         typedef Signature signature_type;
 
@@ -76,7 +106,7 @@
     const filter &operator = (const filter &) {return *this;}
 
         /// Returns the default out signal.
- signal_type &get_proxied_producer() const
+ signal_type &default_signal() const
         { return out; }
 
         /// Disconnects all slots connected to the signals::filter.
@@ -85,63 +115,61 @@
         mutable signal_type out;
 }; // class filter
 
+
 /** \brief Combined version of the filter class
 */
-template<typename Signature, typename Combiner, typename Group, typename GroupCompare>
-class filter<Signature, combined, Combiner, Group, GroupCompare>
-: public filter<Signature, unfused, Combiner, Group, GroupCompare>
+template<typename Derived, typename Signature, typename SignalArgs>
+class filter<Derived, Signature, combined, SignalArgs>
+: public filter<Derived, Signature, unfused, SignalArgs>
 {
- typedef filter<Signature, unfused, Combiner, Group, GroupCompare> base_type;
 public:
- filter() : fused_out(base_type::out) {}
- filter(const filter &) : fused_out(base_type::out){}
+ filter() : fused_out(filter::out) {}
+ filter(const filter &) : fused_out(filter::out){}
     const filter &operator = (const filter &) {return *this;}
-
- typedef typename base_type::signature_type signature_type;
- typedef typename base_type::signal_type signal_type;
     
     typedef typename boost::function_types::parameter_types<Signature>::type parameter_types;
     typedef typename boost::fusion::result_of::as_vector<parameter_types>::type parameter_vector;
- typedef typename signal_type::result_type fused_signature_type (const parameter_vector &);
+ typedef typename filter::signal_type::result_type fused_signature_type (const parameter_vector &);
 
 protected:
- boost::signal<fused_signature_type, Combiner, Group, GroupCompare> fusion_out;
- boost::fusion::fused<typename base_type::signal_type const &> fused_out;
+ typename signal_from_args<fused_signature_type, SignalArgs>::type fusion_out;
+ boost::fusion::fused<typename filter::signal_type const &> fused_out;
 }; // class filter
 
 namespace detail
 {
- template<typename Signature, typename Combiner, typename Group, typename GroupCompare>
+ template<typename Signature, typename SignalArgs=typename default_signal_args<Signature>::type>
     struct fused_signal_type
     {
         typedef typename boost::function_types::parameter_types<Signature>::type parameter_types;
         typedef typename boost::fusion::result_of::as_vector<parameter_types>::type parameter_vector;
- typedef typename Combiner::result_type signature_type (const parameter_vector &);
- typedef typename Combiner::result_type fused_signature_type (const parameter_vector &);
- typedef boost::signal<signature_type, Combiner, Group, GroupCompare> signal_type;
+ typedef typename SignalArgs::combiner_type::result_type signature_type (const parameter_vector &);
+ typedef typename SignalArgs::combiner_type::result_type fused_signature_type (const parameter_vector &);
+ typedef typename signal_from_args<fused_signature_type, SignalArgs>::type signal_type;
     };
 }
 
 /** \brief Fused version of the filter class
 */
-template<typename Signature, typename Combiner, typename Group, typename GroupCompare>
-class filter<Signature, fused, Combiner, Group, GroupCompare>
-: public filter_base<typename detail::fused_signal_type<Signature, Combiner, Group, GroupCompare>::signal_type>
+template<typename Derived, typename Signature, typename SignalArgs>
+class filter<Derived, Signature, fused, SignalArgs>
+: public filter_base<
+ Derived,
+ typename detail::fused_signal_type<Signature, SignalArgs>::signal_type>
 {
 public:
         filter(const filter &) {}
         filter(){}
     const filter &operator = (const filter &) {return *this;}
 
- typedef typename boost::function_types::parameter_types<Signature>::type parameter_types;
- typedef typename boost::fusion::result_of::as_vector<parameter_types>::type parameter_vector;
- typedef typename Combiner::result_type signature_type (const parameter_vector &);
- typedef typename Combiner::result_type fused_signature_type (const parameter_vector &);
- typedef boost::signal<signature_type, Combiner, Group, GroupCompare> signal_type;
- typedef signal_type proxy_producer_for;
+ typedef typename detail::fused_signal_type<Signature, SignalArgs>::parameter_types parameter_types;
+ typedef typename detail::fused_signal_type<Signature, SignalArgs>::parameter_vector parameter_vector;
+ typedef typename detail::fused_signal_type<Signature, SignalArgs>::signature_type signature_type;
+ typedef typename detail::fused_signal_type<Signature, SignalArgs>::fused_signature_type fused_signature_type;
+ typedef typename detail::fused_signal_type<Signature, SignalArgs>::signal_type signal_type;
 
         /// Returns the default out signal.
- proxy_producer_for &get_proxied_producer() const
+ signal_type &default_signal() const
         { return fused_out; }
         /// Disconnects all slots connected to the signals::filter.
         void disconnect_all_slots() {fused_out.disconnect_all_slots();}

Modified: sandbox/SOC/2007/signals/boost/dataflow/signals/component/filter_base.hpp
==============================================================================
--- sandbox/SOC/2007/signals/boost/dataflow/signals/component/filter_base.hpp (original)
+++ sandbox/SOC/2007/signals/boost/dataflow/signals/component/filter_base.hpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -7,41 +7,43 @@
 #define SIGNAL_NETWORK_FILTER_BASE_HPP
 
 #include <boost/dataflow/signals/support.hpp>
+#include <boost/dataflow/support/fusion_component.hpp>
+#include <boost/dataflow/support/port/port_adapter.hpp>
 
-#include <boost/type_traits/integral_constant.hpp>
-#include <boost/utility/enable_if.hpp>
 #include <boost/signal.hpp>
 
-#ifdef _THREAD_SAFE_SIGNAL_HPP
-#define SIGNAL_NETWORK_THREAD_SAFE
-#else
-#define SIGNAL_NETWORK_TRACKABLE
-#endif
 
 namespace boost { namespace signals {
 
-template<typename Signal>
-class filter_base
-#ifdef SIGNAL_NETWORK_TRACKABLE
-: public boost::signals::trackable
-#endif
+template<typename Filter, typename Signal>
+struct filter_component_traits
+ : public dataflow::fusion_component_traits<
+ fusion::vector<
+ Signal &,
+ const dataflow::port_adapter<Filter, dataflow::signals::call_consumer, dataflow::signals::tag> >,
+ mpl::map<
+ mpl::pair<dataflow::default_port_selector
+ <dataflow::directions::outgoing, dataflow::signals::connect_mechanism>,
+ mpl::int_<0> >,
+ mpl::pair<dataflow::default_port_selector
+ <dataflow::directions::incoming, dataflow::signals::connect_mechanism>,
+ mpl::int_<1> >
+ > >
+{};
+
+template<typename Filter, typename Signal>
+class filter_base : public dataflow::component<filter_component_traits<Filter, Signal> >
 {
 public:
- struct get_proxied_object
+// using dataflow::component<filter_component_traits<Filter, Signal> >::component_traits;
+
+ template<typename Component>
+ typename filter_base::component_traits::port_result_types get_ports(Component &component)
     {
- template<typename T>
- Signal &operator()(T &t)
- {
- return t.get_proxied_producer();
- }
+ return typename filter_base::component_traits::port_result_types(
+ component.default_signal(),
+ component);
     };
- typedef boost::dataflow::signals::call_consumer port_traits;
- typedef boost::dataflow::mutable_proxy_port<
- boost::dataflow::signals::mechanism,
- boost::dataflow::ports::producer,
- Signal,
- get_proxied_object
- > proxy_port_traits;
 };
 
 } }

Modified: sandbox/SOC/2007/signals/boost/dataflow/signals/component/function.hpp
==============================================================================
--- sandbox/SOC/2007/signals/boost/dataflow/signals/component/function.hpp (original)
+++ sandbox/SOC/2007/signals/boost/dataflow/signals/component/function.hpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -42,17 +42,21 @@
 The signals::function object will receive signals of signature void(<i>function arguments</i>),
 and send signals of signature void(<i>function return type</i>).
 */
-template<typename Signature,
+template<
+ typename Signature,
     typename FunctionSignature,
     typename OutSignal=SIGNAL_NETWORK_DEFAULT_OUT,
- typename Combiner = boost::last_value<void>,
- typename Group = int,
- typename GroupCompare = std::less<Group>
+ typename SignalArgs=typename default_signal_args<Signature>::type
>
-class function : public modifier<detail::function_adapter<FunctionSignature, Signature>, Signature, OutSignal, Combiner, Group, GroupCompare>
+class function
+ : public modifier<
+ function<Signature, FunctionSignature, OutSignal, SignalArgs>,
+ detail::function_adapter<FunctionSignature, Signature>, Signature, OutSignal, SignalArgs>
 {
 public:
- typedef modifier<detail::function_adapter<FunctionSignature, Signature>, Signature, OutSignal, Combiner, Group, GroupCompare> base_type;
+ typedef modifier<
+ function<Signature, FunctionSignature, OutSignal, SignalArgs>,
+ detail::function_adapter<FunctionSignature, Signature>, Signature, OutSignal, SignalArgs> base_type;
 
     function(const boost::function<FunctionSignature> &f) : base_type(f) {}
 };

Modified: sandbox/SOC/2007/signals/boost/dataflow/signals/component/junction.hpp
==============================================================================
--- sandbox/SOC/2007/signals/boost/dataflow/signals/component/junction.hpp (original)
+++ sandbox/SOC/2007/signals/boost/dataflow/signals/component/junction.hpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -26,30 +26,30 @@
 also be disabled to stop the flow of signals.
     junction is a conditional with Condition identity and Member volatile bool
 */
-template<typename Signature,
+template<
+ typename Signature,
     typename OutSignal=SIGNAL_NETWORK_DEFAULT_OUT,
- typename Combiner = boost::last_value<typename boost::function_types::result_type<Signature>::type>,
- typename Group = int,
- typename GroupCompare = std::less<Group>
+ typename SignalArgs=typename default_signal_args<Signature>::type
>
-class junction : public conditional<volatile bool, detail::identity<bool>, Signature, OutSignal, Combiner, Group, GroupCompare>
+class junction
+ : public conditional<
+ junction<Signature, OutSignal, SignalArgs>,
+ volatile bool, detail::identity<bool>, Signature, OutSignal, SignalArgs>
 {
-protected:
- typedef conditional<volatile bool, detail::identity<bool>, Signature, OutSignal, Combiner, Group, GroupCompare> base_type;
 public:
     
     /** Initializes the junction to be enabled.
     */
- junction(bool enabled=true)
+ junction(bool opened=true)
     {
- enable();
+ junction::member=opened;
     }
     /** Enables the junction (signals will be forwarded).
     */
- void enable() {base_type::member = true;}
+ void open() {junction::member = true;}
     /** Disables the junction (signals will not be forwarded).
     */
- void disable() {base_type::member = false;}
+ void close() {junction::member = false;}
 };
 
 } } // namespace boost::signals

Modified: sandbox/SOC/2007/signals/boost/dataflow/signals/component/multiplexer.hpp
==============================================================================
--- sandbox/SOC/2007/signals/boost/dataflow/signals/component/multiplexer.hpp (original)
+++ sandbox/SOC/2007/signals/boost/dataflow/signals/component/multiplexer.hpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -15,6 +15,11 @@
 
 #include <functional>
 
+#ifndef BOOST_MSVC
+#define BOOST_TEMPLATE_OPERATOR template operator
+#else
+#define BOOST_TEMPLATE_OPERATOR operator
+#endif
 
 namespace boost { namespace signals {
 
@@ -22,18 +27,17 @@
 also be disabled to stop the flow of signals.
     junction is a conditional with Condition identity and Member volatile bool
 */
-template<typename Signature,
+template<
+ typename Signature,
     typename OutSignal=SIGNAL_NETWORK_DEFAULT_OUT,
- typename Combiner = boost::last_value<typename boost::function_types::result_type<Signature>::type>,
- typename Group = int,
- typename GroupCompare = std::less<Group>
+ typename SignalArgs=typename default_signal_args<Signature>::type
>
-class multiplexer : public conditional_templated<int, std::equal_to<int>, Signature, OutSignal, Combiner, Group, GroupCompare>
+class multiplexer
+ : public conditional_templated<
+ multiplexer<Signature, OutSignal, SignalArgs>,
+ int, std::equal_to<int>, Signature, OutSignal, SignalArgs>
 {
-protected:
- typedef conditional_templated<int, std::equal_to<int>, Signature, OutSignal, Combiner, Group, GroupCompare> base_type;
 public:
-
     /** Initializes the multiplexer to forward the specified input.
     */
     multiplexer(int selector=0)
@@ -41,7 +45,7 @@
     /** Enables the junction (signals will be forwarded).
     */
     void select(int selector)
- { base_type::member = selector; }
+ { multiplexer::member = selector; }
     
     slot_selector<void(int), multiplexer>
     select_slot()
@@ -52,29 +56,19 @@
     typedef boost::fusion::map<
         boost::fusion::pair<boost::dataflow::signals::producer<Signature>, slot_selector<Signature, multiplexer> >,
         boost::fusion::pair<
- boost::dataflow::signals::producer<typename base_type::fused_signature_type>,
- slot_selector<typename base_type::fused_signature_type, multiplexer>
+ boost::dataflow::signals::producer<typename multiplexer::fused_signature_type>,
+ slot_selector<typename multiplexer::fused_signature_type, multiplexer>
>
> slot_map;
     
     template<int N>
- boost::dataflow::port_map<boost::dataflow::signals::mechanism, boost::dataflow::ports::consumer, slot_map>
- //slot_selector<Signature, multiplexer>
+ boost::dataflow::port_map<boost::dataflow::ports::consumer, slot_map, boost::dataflow::signals::tag>
     slot()
     {
- //return make_slot_selector<Signature> (&multiplexer::template operator()<N>, *this);
         return slot_map
- (make_slot_selector<Signature> (&multiplexer::
-#ifndef BOOST_MSVC
- template
-#endif
- operator()<N>, *this),
- make_slot_selector<typename base_type::fused_signature_type>
- (&multiplexer::
-#ifndef BOOST_MSVC
- template
-#endif
- operator()<N>, *this));
+ (make_slot_selector<Signature> (&multiplexer::BOOST_TEMPLATE_OPERATOR()<N>, *this),
+ make_slot_selector<typename multiplexer::fused_signature_type>
+ (&multiplexer::BOOST_TEMPLATE_OPERATOR()<N>, *this));
 
     }
 };

Modified: sandbox/SOC/2007/signals/boost/dataflow/signals/component/mutex.hpp
==============================================================================
--- sandbox/SOC/2007/signals/boost/dataflow/signals/component/mutex.hpp (original)
+++ sandbox/SOC/2007/signals/boost/dataflow/signals/component/mutex.hpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -15,12 +15,12 @@
 */
 template<typename Signature,
     typename OutSignal=SIGNAL_NETWORK_DEFAULT_OUT,
- typename Combiner = boost::last_value<typename boost::function_types::result_type<Signature>::type>,
- typename Group = int,
- typename GroupCompare = std::less<Group>
+ typename SignalArgs=typename default_signal_args<Signature>::type
>
 class mutex : public
- instantiator<boost::mutex, boost::mutex::scoped_lock, Signature, OutSignal, Combiner, Group, GroupCompare>
+ instantiator<
+ mutex<Signature, OutSignal, SignalArgs>,
+ boost::mutex, boost::mutex::scoped_lock, Signature, OutSignal, SignalArgs>
 {
 };
 

Modified: sandbox/SOC/2007/signals/boost/dataflow/signals/component/socket_receiver.hpp
==============================================================================
--- sandbox/SOC/2007/signals/boost/dataflow/signals/component/socket_receiver.hpp (original)
+++ sandbox/SOC/2007/signals/boost/dataflow/signals/component/socket_receiver.hpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -25,12 +25,11 @@
 */
 template<typename Signature,
     typename OutSignal=SIGNAL_NETWORK_DEFAULT_OUT,
- typename Combiner = boost::last_value<typename boost::function_types::result_type<Signature>::type>,
- typename Group = int,
- typename GroupCompare = std::less<Group> >
-class socket_receiver : public storage<Signature, OutSignal, Combiner, Group, GroupCompare>
+ typename SignalArgs=typename default_signal_args<Signature>::type
+>
+class socket_receiver : public storage<Signature, OutSignal, SignalArgs>
 {
- typedef storage<Signature, OutSignal, Combiner, Group, GroupCompare> base_type;
+ typedef storage<Signature, OutSignal, SignalArgs> base_type;
 
 public:
     /// Initializes the socket_sender to use the provided socket.

Modified: sandbox/SOC/2007/signals/boost/dataflow/signals/component/storage.hpp
==============================================================================
--- sandbox/SOC/2007/signals/boost/dataflow/signals/component/storage.hpp (original)
+++ sandbox/SOC/2007/signals/boost/dataflow/signals/component/storage.hpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -6,36 +6,26 @@
 #ifndef BOOST_DATAFLOW_SIGNALS_COMPONENT_STORAGE_HPP
 #define BOOST_DATAFLOW_SIGNALS_COMPONENT_STORAGE_HPP
 
+#include <boost/dataflow/connection/port_map.hpp>
+#include <boost/dataflow/detail/make_ref.hpp>
 #include <boost/dataflow/signals/component/conditional_modifier.hpp>
 #include <boost/dataflow/signals/component/detail/storable.hpp>
 #include <boost/dataflow/signals/connection/slot_selector.hpp>
-#include <boost/dataflow/connection/port_map.hpp>
 
+#include <boost/mpl/map.hpp>
 #include <boost/fusion/container/vector.hpp>
 #include <boost/fusion/view/transform_view.hpp>
 #include <boost/fusion/container/map.hpp>
-#include <boost/dataflow/detail/make_ref.hpp>
 
 
 namespace boost { namespace signals {
 
- template<typename Signature,
- typename OutSignal,
- typename Combiner,
- typename Group,
- typename GroupCompare
->
+template<typename Signature, typename OutSignal, typename SignalArgs>
 class storage;
 
-template<typename T>
+template<typename Storage>
 struct storage_component_traits
- : public dataflow::component_traits<
- mpl::vector<
- dataflow::signals::producer<T>, // outgoing signal
- dataflow::signals::consumer<T>, // incoming signal
- dataflow::signals::extract_producer<T>, // outgoing extraction port
- dataflow::signals::extract_consumer<T> // incoming extraction port
- > >
+ : public filter_component_traits<Storage, typename Storage::signal_type>
 {};
 
 namespace detail
@@ -81,7 +71,7 @@
         storable_vector stored;
         volatile bool opened;
 
- template<typename Sig, typename OutSignal, typename Combiner, typename Group, typename GroupCompare>
+ template<typename Sig, typename OutSignal, typename SignalArgs>
         friend class storage;
     };
 
@@ -89,31 +79,27 @@
 /** \brief Stores and transmits arguments received from a signal.
     \param Signature Signature of the signal sent.
 */
-template<typename Signature,
+template<
+ typename Signature,
     typename OutSignal=SIGNAL_NETWORK_DEFAULT_OUT,
- typename Combiner = boost::last_value<typename boost::function_traits<Signature>::result_type>,
- typename Group = int,
- typename GroupCompare = std::less<Group>
+ typename SignalArgs=typename default_signal_args<Signature>::type
>
-class storage : public conditional_modifier<storage_modifier<Signature>, Signature, OutSignal, Combiner, Group, GroupCompare>
+class storage : public conditional_modifier<
+ storage<Signature,OutSignal,SignalArgs>,
+ storage_modifier<Signature>,
+ Signature,
+ OutSignal,
+ SignalArgs>
 {
 protected:
- typedef conditional_modifier<storage_modifier<Signature>, Signature, OutSignal, Combiner, Group, GroupCompare> base_type;
+ typedef conditional_modifier<storage, storage_modifier<Signature>, Signature, OutSignal, SignalArgs> base_type;
         using base_type::modification;
 public:
     typedef typename storage_modifier<Signature>::parameter_types parameter_types;
-
     typedef typename storage_modifier<Signature>::storable_types storable_types;
     typedef typename storage_modifier<Signature>::storable_vector storable_vector;
     
- typedef storage_component_traits<Signature> component_traits;
-
- typedef mpl::vector<
- typename boost::dataflow::signals::call_consumer,
- typename boost::dataflow::signals::extract_producer<Signature>,
- typename boost::dataflow::signals::extract_call_consumer
- > port_traits;
-
+ typedef storage_component_traits<storage> component_traits;
 
         storage(const storage &rhs) : base_type(rhs.modification) {}
 
@@ -179,7 +165,7 @@
>
> send_map;
 
- boost::dataflow::port_map<boost::dataflow::signals::mechanism, boost::dataflow::ports::consumer, send_map>
+ boost::dataflow::port_map<boost::dataflow::ports::consumer, send_map, dataflow::signals::tag>
     send_slot()
     {
         return send_map
@@ -190,7 +176,7 @@
     */
     template<int N>
         slot_selector
-#ifndef DOXYGEN_DOCS_ONLY
+#ifndef DOXYGEN_DOCS_BUILD
         <typename boost::fusion::result_of::at_c<storable_vector, N>::type (), storage>
 #endif
     at_slot()
@@ -233,8 +219,8 @@
         }
     };
     
- template<typename T>
- struct get_component_port_impl<boost::signals::storage_component_traits<T> >
+/* template<typename T>
+ struct get_port_impl<boost::signals::storage_component_traits<T> >
     {
         template<typename Component>
         struct port_types
@@ -264,7 +250,7 @@
         };
         
         template<typename Component, typename N>
- typename result<get_component_port_impl(Component &, N)>::type
+ typename result<get_port_impl(Component &, N)>::type
         operator()(Component &component, N)
         {
             return fusion::at<N>(ports(component));
@@ -279,7 +265,7 @@
         {
             producer.call(consumer);
         }
- };
+ };*/
 }
 
 } } // namespace boost::dataflow

Modified: sandbox/SOC/2007/signals/boost/dataflow/signals/component/timed_generator.hpp
==============================================================================
--- sandbox/SOC/2007/signals/boost/dataflow/signals/component/timed_generator.hpp (original)
+++ sandbox/SOC/2007/signals/boost/dataflow/signals/component/timed_generator.hpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -15,13 +15,11 @@
 */
 template<typename Signature,
     typename OutSignal=SIGNAL_NETWORK_DEFAULT_OUT,
- typename Combiner = boost::last_value<typename boost::function_traits<Signature>::result_type>,
- typename Group = int,
- typename GroupCompare = std::less<Group>
+ typename SignalArgs=typename default_signal_args<Signature>::type
>
-class timed_generator : public storage<Signature, OutSignal, Combiner, Group, GroupCompare>
+class timed_generator : public storage<Signature, OutSignal, SignalArgs>
 {
- typedef storage<Signature, OutSignal, Combiner, Group, GroupCompare> base_type;
+ typedef storage<Signature, OutSignal, SignalArgs> base_type;
 public:
         /// Default constructor. Starts the thread, but signals won't be sent until the enable() function is called.
         timed_generator() : terminating(false), enabled(false)

Modified: sandbox/SOC/2007/signals/boost/dataflow/signals/connection/operators.hpp
==============================================================================
--- sandbox/SOC/2007/signals/boost/dataflow/signals/connection/operators.hpp (original)
+++ sandbox/SOC/2007/signals/boost/dataflow/signals/connection/operators.hpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -9,84 +9,23 @@
 #include <boost/dataflow/signals/support.hpp>
 
 namespace boost { namespace signals {
-
- /// Connects two components (typically as a part of a chain of components).
- /** This operator is identical to signals::operator| (it connects the
- left component to the right component, and returns a reference to the left component),
- except it is evaluated right to left. This makes it semantics more suitable for
- connecting a chain of components.
- */
-template<typename Input, typename Output>
-typename boost::enable_if<
- boost::mpl::and_<
- boost::dataflow::is_port<boost::dataflow::signals::mechanism, boost::dataflow::ports::producer, Input>,
- boost::dataflow::is_port<boost::dataflow::signals::mechanism, boost::dataflow::ports::consumer, Output>
- >,
- Input &
->::type
-operator >>= (Input &input, Output &output)
-{ connect(input, output); return input;}
-
-template<typename Input, typename Output>
-typename boost::enable_if<
- boost::mpl::and_<
- boost::dataflow::is_port<boost::dataflow::signals::mechanism, boost::dataflow::ports::producer, Input>,
- boost::dataflow::is_port<boost::dataflow::signals::mechanism, boost::dataflow::ports::consumer, Output>
- >,
- Input &
->::type
-operator >>= (Input &input, const Output &output)
-{ connect(input, output); return input;}
 
-template<typename Input, typename Output>
-typename boost::enable_if<
- boost::mpl::and_<
- boost::dataflow::is_port<boost::dataflow::signals::mechanism, boost::dataflow::ports::producer, Input>,
- boost::dataflow::is_port<boost::dataflow::signals::mechanism, boost::dataflow::ports::consumer, Output>
- >,
- const Input &
->::type
-operator >>= (const Input &input, Output &output)
-{ connect(input, output); return input;}
-
-template<typename Input, typename Output>
-typename boost::enable_if<
- boost::mpl::and_<
- boost::dataflow::is_port<boost::dataflow::signals::mechanism, boost::dataflow::ports::producer, Input>,
- boost::dataflow::is_port<boost::dataflow::signals::mechanism, boost::dataflow::ports::consumer, Output>
- >,
- const Input &
->::type
-operator >>= (const Input &input, const Output &output)
-{ connect(input, output); return input;}
+// the include templates expect DATAFLOW_TEMPLATE_TAG to have
+// the mechanism type
+#define DATAFLOW_TEMPLATE_TAG boost::dataflow::signals::tag
+
+# define DATAFLOW_TEMPLATE_MECHANISM boost::dataflow::signals::connect_mechanism
+# define DATAFLOW_TEMPLATE_BINARY_OPERATION connect
+# define DATAFLOW_TEMPLATE_OPERATOR >>=
+# include <boost/dataflow/templates/operator.hpp>
+# undef DATAFLOW_TEMPLATE_OPERATOR
+# define DATAFLOW_TEMPLATE_OPERATOR |
+# include <boost/dataflow/templates/operator.hpp>
+# undef DATAFLOW_TEMPLATE_OPERATOR
+# undef DATAFLOW_TEMPLATE_BINARY_OPERATION
+# undef DATAFLOW_TEMPLATE_MECHANISM
+#undef DATAFLOW_TEMPLATE_TAG
     
- /// Connects two components (typically as a part of branching from a single component).
- /** This operator is identical to signals::operator>>=, (it connects the
- left component to the right component, and returns a reference to the left component)
- except it is evaluated left to right. This makes its semantics more suitable for
- branching connections.
- */
-template<typename Input, typename Output>
-typename boost::enable_if<
- boost::mpl::and_<
- boost::dataflow::is_port<boost::dataflow::signals::mechanism, boost::dataflow::ports::producer, Input>,
- boost::dataflow::is_port<boost::dataflow::signals::mechanism, boost::dataflow::ports::consumer, Output>
- >,
- Input &
->::type
-operator | (Input &input, Output &output)
-{ connect(input, output); return input;}
-
-template<typename Input, typename Output>
-typename boost::enable_if<
- boost::mpl::and_<
- boost::dataflow::is_port<boost::dataflow::signals::mechanism, boost::dataflow::ports::producer, Input>,
- boost::dataflow::is_port<boost::dataflow::signals::mechanism, boost::dataflow::ports::consumer, Output>
- >,
- Input &
->::type
-operator | (Input &input, const Output &output)
-{ connect(input, output); return input;}
     
 } } // namespace boost::dataflow
 

Modified: sandbox/SOC/2007/signals/boost/dataflow/signals/connection/slot_selector.hpp
==============================================================================
--- sandbox/SOC/2007/signals/boost/dataflow/signals/connection/slot_selector.hpp (original)
+++ sandbox/SOC/2007/signals/boost/dataflow/signals/connection/slot_selector.hpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -17,7 +17,7 @@
 namespace boost { namespace dataflow { namespace signals {
 
 struct slot_selector_consumer
- : public boost::dataflow::port_traits<mechanism, ports::consumer, concepts::keyed_port> {};
+ : public boost::dataflow::port_traits<ports::consumer, concepts::keyed_port, tag> {};
 
 } } // namespace dataflow::signals
 
@@ -28,21 +28,7 @@
 template<typename Signature, typename T>
 struct slot_selector
 {
- struct get_proxied_object
- {
- T &operator()(const slot_selector<Signature, T> &t)
- {
- return t.object;
- };
- };
-
     typedef boost::dataflow::signals::slot_selector_consumer port_traits;
- typedef boost::dataflow::mutable_proxy_port<
- boost::dataflow::signals::mechanism,
- boost::dataflow::ports::producer,
- T,
- get_proxied_object
- > proxy_port_traits;
 
     typedef Signature signature_type;
     typedef T class_type;

Modified: sandbox/SOC/2007/signals/boost/dataflow/signals/support.hpp
==============================================================================
--- sandbox/SOC/2007/signals/boost/dataflow/signals/support.hpp (original)
+++ sandbox/SOC/2007/signals/boost/dataflow/signals/support.hpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -15,67 +15,49 @@
 
 namespace signals {
 
-struct mechanism {};
+struct tag {};
+struct connect_mechanism {};
+struct extract_mechanism {};
 
 template<typename T>
 struct producer
- : public complemented_port_traits<mechanism, ports::producer, boost::function<T> >
+ : public complemented_port_traits<ports::producer, boost::function<T>, tag>
 {
     typedef T signature_type;
 };
 
 template<typename T>
 struct consumer
- : public port_traits<mechanism, ports::consumer, concepts::port>
+ : public port_traits<ports::consumer, concepts::port, tag>
 {
     typedef T signature_type;
 };
 
 struct call_consumer
- : public port_traits<mechanism, ports::consumer, concepts::keyed_port>
+ : public port_traits<ports::consumer, concepts::keyed_port, tag>
 {};
 
- // mechanism used for data extraction
- struct extract_mechanism {};
-
- template<typename T>
- struct extract_producer
- : public complemented_port_traits<extract_mechanism, ports::producer, boost::function<T> >
- {
- typedef T signature_type;
- };
-
- template<typename T>
- struct extract_consumer
- : public port_traits<extract_mechanism, ports::consumer, concepts::port>
- {
- typedef T signature_type;
- };
-
- struct extract_call_consumer
- : public port_traits<extract_mechanism, ports::consumer, concepts::keyed_port>
- {};
+template<typename T>
+struct extract_producer
+ : public complemented_port_traits<ports::producer, boost::function<T>, tag>
+{
+ typedef T signature_type;
+};
 
 } // namespace signals
 
 template<typename Signature, typename Combiner, typename Group, typename GroupCompare>
-struct register_port_traits<signals::mechanism, ports::producer, boost::signal<Signature, Combiner, Group, GroupCompare> >
+struct register_port_traits<boost::signal<Signature, Combiner, Group, GroupCompare>, signals::tag >
 {
     typedef signals::producer<Signature> type;
 };
 
 template<typename Signature>
-struct register_port_traits<signals::mechanism, ports::consumer, boost::function<Signature> >
+struct register_port_traits<boost::function<Signature>, signals::tag >
 {
     typedef signals::consumer<Signature> type;
 };
 
-template<typename Signature>
-struct register_port_traits<signals::extract_mechanism, ports::consumer, boost::function<Signature> >
-{
- typedef signals::extract_consumer<Signature> type;
-};
-
 namespace extension
 {
     template<typename Signature>
@@ -90,23 +72,12 @@
             (static_cast<typename boost::signals::detail::slot_type<Signature, ConsumerPort>::type>(&ConsumerPort::operator()), consumer);
         };
     };
-
- template<typename Signature>
- struct get_keyed_port_impl<signals::extract_call_consumer, signals::extract_producer<Signature> >
- {
- typedef const boost::function<Signature> result_type;
-
- template<typename ConsumerPort>
- result_type operator()(ConsumerPort &consumer)
- {
- return boost::signals::detail::bind_object<Signature, ConsumerPort>()
- (static_cast<typename boost::signals::detail::slot_type<Signature, ConsumerPort>::type>(&ConsumerPort::operator()), consumer);
- };
- };
-
+
     template<typename T>
- struct binary_operation_impl<operations::connect, signals::producer<T>, signals::consumer<T> >
+ struct binary_operation_impl<signals::producer<T>, signals::consumer<T>, operations::connect>
     {
+ typedef void result_type;
+
         template<typename Producer, typename Consumer>
         void operator()(Producer &producer, Consumer &consumer)
         {
@@ -119,7 +90,9 @@
 
 namespace boost { namespace signals {
 
-#define DATAFLOW_TEMPLATE_MECHANISM boost::dataflow::signals::mechanism
+#define DATAFLOW_TEMPLATE_TAG boost::dataflow::signals::tag
+
+#define DATAFLOW_TEMPLATE_MECHANISM boost::dataflow::signals::connect_mechanism
 #define DATAFLOW_TEMPLATE_BINARY_OPERATION connect
 #include <boost/dataflow/templates/binary_operation.hpp>
 #undef DATAFLOW_TEMPLATE_BINARY_OPERATION
@@ -130,6 +103,7 @@
 #include <boost/dataflow/templates/binary_operation.hpp>
 #undef DATAFLOW_TEMPLATE_BINARY_OPERATION
 #undef DATAFLOW_TEMPLATE_MECHANISM
+#undef DATAFLOW_TEMPLATE_TAG
 
 template<typename Component>
 inline void invoke(Component &component)

Modified: sandbox/SOC/2007/signals/boost/dataflow/support.hpp
==============================================================================
--- sandbox/SOC/2007/signals/boost/dataflow/support.hpp (original)
+++ sandbox/SOC/2007/signals/boost/dataflow/support.hpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -7,7 +7,7 @@
 #define BOOST_DATAFLOW_SUPPORT_HPP
 
 #include <boost/dataflow/support/port.hpp>
-#include <boost/dataflow/support/proxy_port.hpp>
+//#include <boost/dataflow/support/proxy_port.hpp>
 #include <boost/dataflow/support/complemented_port.hpp>
 #include <boost/dataflow/support/binary_operation.hpp>
 #include <boost/dataflow/support/keyed_port.hpp>

Modified: sandbox/SOC/2007/signals/boost/dataflow/support/binary_operation.hpp
==============================================================================
--- sandbox/SOC/2007/signals/boost/dataflow/support/binary_operation.hpp (original)
+++ sandbox/SOC/2007/signals/boost/dataflow/support/binary_operation.hpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -6,88 +6,45 @@
 #ifndef BOOST_DATAFLOW_SUPPORT_BINARY_OPERATION_HPP
 #define BOOST_DATAFLOW_SUPPORT_BINARY_OPERATION_HPP
 
-#include <boost/dataflow/support/proxy_port.hpp>
+#include <boost/dataflow/support/port.hpp>
 
-#include <boost/static_assert.hpp>
-#include <boost/type_traits/remove_reference.hpp>
+// ***************************************
+// * binary_operation, are_binary_operable
+// ***************************************
+#define DATAFLOW_SPECIALIZABLE_OPERATION_NAME binary_operation
+#define DATAFLOW_SPECIALIZABLE_OPERATION_CHECK are_binary_operable
+#define DATAFLOW_SPECIALIZABLE_OPERATION_TYPENAME_TEMPLATES typename Operation
+#define DATAFLOW_SPECIALIZABLE_OPERATION_TEMPLATES Operation
+#define DATAFLOW_SPECIALIZABLE_OPERATION_ARITY 2
+#define DATAFLOW_SPECIALIZABLE_OPERATION_TRAITS_OF port_traits_of
+#define DATAFLOW_SPECIALIZABLE_OPERATION_HAS_TRAITS is_port
+#include <boost/dataflow/support/detail/make_specializable_operation.hpp>
 
 
 namespace boost { namespace dataflow {
 
-namespace extension
-{
- template<typename Operation, typename ProducerTag, typename ConsumerTag, typename Enable=void>
- struct binary_operation_impl
- {
- typedef void not_specialized;
-
- template<typename Producer, typename Consumer>
- void operator()(Producer &, Consumer &)
- {
- // Error: binary_operation_impl has not been implemented
- // for ProducerTag and ConsumerTag.
- BOOST_STATIC_ASSERT(sizeof(Producer)==0);
- }
- };
-}
-
-template<typename Operation, typename Mechanism, typename Producer, typename Consumer>
-inline void binary_operation(Producer &producer, Consumer &consumer)
+template<typename Operation, typename Mechanism, typename Tag, typename OutgoingPort, typename IncomingPort>
+inline void
+binary_operation(OutgoingPort &outgoing, IncomingPort &incoming)
 {
     extension::binary_operation_impl<
- Operation,
- typename port_traits_of<Mechanism, ports::producer, Producer>::type,
- typename port_traits_of<Mechanism, ports::consumer, Consumer>::type>
- ()(get_port<Mechanism, ports::producer>(producer),
- get_port<Mechanism, ports::consumer>(consumer));
+ typename default_port_traits_of<OutgoingPort, directions::outgoing, Mechanism, Tag>::type,
+ typename default_port_traits_of<IncomingPort, directions::incoming, Mechanism, Tag>::type,
+ Operation>
+ ()(get_default_port<directions::outgoing, Mechanism, Tag>(outgoing),
+ get_default_port<directions::incoming, Mechanism, Tag>(incoming));
 }
 
-template<typename Operation, typename Mechanism, typename ProducerPort, typename ConsumerPort, typename Enable=void>
-struct are_binary_operable
- : public mpl::false_
-{
- BOOST_MPL_ASSERT((is_same<Enable, void>));
-};
-
-template<typename Operation, typename Mechanism, typename Producer, typename Consumer, typename Enable=void>
-struct specialized_binary_operation
- : public mpl::true_
+template<typename OutgoingPort, typename IncomingPort>
+inline typename enable_if<
+ mpl::and_<
+ has_default_port<OutgoingPort, directions::outgoing, default_mechanism, default_tag>,
+ has_default_port<IncomingPort, directions::incoming, default_mechanism, default_tag>
+ > >::type
+connect(OutgoingPort &outgoing, IncomingPort &incoming)
 {
- BOOST_MPL_ASSERT((is_same<Enable, void>));
-};
-
-template<typename Operation, typename Mechanism, typename Producer, typename Consumer>
-struct specialized_binary_operation<
- Operation,
- Mechanism,
- Producer,
- Consumer,
- typename detail::enable_if_defined<
- typename extension::binary_operation_impl<
- Operation,
- typename port_traits_of<Mechanism, ports::producer, Producer>::type,
- typename port_traits_of<Mechanism, ports::consumer, Consumer>::type
- >::not_specialized
- >::type
->
- : public mpl::false_ {};
-
-template<typename Operation, typename Mechanism, typename Producer, typename Consumer>
-struct are_binary_operable<
- Operation,
- Mechanism,
- Producer,
- Consumer,
- typename enable_if<
- mpl::and_<
- is_port<Mechanism, ports::producer, Producer>,
- is_port<Mechanism, ports::consumer, Consumer>,
- specialized_binary_operation<Operation,Mechanism,Producer,Consumer>
- >
- >::type
->
- : public mpl::true_ {};
-
+ binary_operation<operations::connect, default_mechanism, default_tag>(outgoing, incoming);
+}
 
 } } // namespace boost::dataflow
 

Deleted: sandbox/SOC/2007/signals/boost/dataflow/support/common.hpp
==============================================================================
--- sandbox/SOC/2007/signals/boost/dataflow/support/common.hpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
+++ (empty file)
@@ -1,23 +0,0 @@
-// Copyright 2007 Stjepan Rajko.
-// 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)
-
-#ifndef BOOST_DATAFLOW_SUPPORT_COMMON_HPP
-#define BOOST_DATAFLOW_SUPPORT_COMMON_HPP
-
-namespace boost { namespace dataflow {
-
-/// Tag describing that dataflow properties should apply to all mechanisms.
-struct all_mechanisms;
-
-namespace connections
-{
- struct none;
- struct one;
- struct many;
-}
-
-} } // namespace boost::dataflow
-
-#endif // BOOST_DATAFLOW_SUPPORT_COMMON_HPP
\ No newline at end of file

Modified: sandbox/SOC/2007/signals/boost/dataflow/support/complemented_port.hpp
==============================================================================
--- sandbox/SOC/2007/signals/boost/dataflow/support/complemented_port.hpp (original)
+++ sandbox/SOC/2007/signals/boost/dataflow/support/complemented_port.hpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -10,21 +10,20 @@
 
 namespace boost { namespace dataflow {
 
-/// Convenience class for PortTraits types.
-template<typename Mechanism, typename PortCategory, typename ComplementPort>
+/// Convenience class for ComplementedPortTraits types.
+template<typename PortCategory, typename ComplementPort, typename Tag=default_tag>
 struct complemented_port_traits
+ : public port_traits<PortCategory, concepts::complemented_port, Tag>
 {
- typedef Mechanism mechanism;
- typedef PortCategory category;
- typedef concepts::complemented_port concept;
- typedef ComplementPort complement_port_type;
+ typedef ComplementPort complement_port_type; ///< complement Port type.
 };
 
-/// Boolean metafunction determining whether a type is a PortTraits.
+/// Boolean metafunction determining whether a type is a ComplementedPortTraits.
 template<typename PortTraits, typename Enable=void>
 struct is_complemented_port_traits : public mpl::false_
 {};
 
+/// INTERNAL ONLY
 template<typename PortTraits>
 struct is_complemented_port_traits<PortTraits,
     typename detail::enable_if_defined<
@@ -37,14 +36,16 @@
>::type>
  : public mpl::true_
 {
+ /// INTERNAL ONLY
     BOOST_MPL_ASSERT(( is_port_category<typename PortTraits::category> ));
 };
 
-/// Boolean metafunction determining whether a type is a PortTraits.
+/// Boolean metafunction determining whether a type is a ComplementedPort.
 template<typename Mechanism, typename PortCategory, typename T, typename Enable=void>
 struct is_complemented_port : public mpl::false_
 {};
 
+/// INTERNAL ONLY
 template<typename Mechanism, typename PortCategory, typename T>
 struct is_complemented_port<Mechanism, PortCategory, T,
         typename enable_if<
@@ -52,7 +53,7 @@
                 typename port_traits_of<
                     Mechanism,
                     PortCategory,
- typename utility::underlying_type<T>::type
+ typename remove_cv<T>::type
>::type
>
>::type >

Modified: sandbox/SOC/2007/signals/boost/dataflow/support/component.hpp
==============================================================================
--- sandbox/SOC/2007/signals/boost/dataflow/support/component.hpp (original)
+++ sandbox/SOC/2007/signals/boost/dataflow/support/component.hpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -10,71 +10,121 @@
 
 #include <boost/mpl/and.hpp>
 #include <boost/mpl/assert.hpp>
+#include <boost/mpl/at.hpp>
 #include <boost/mpl/bool.hpp>
+#include <boost/mpl/has_key.hpp>
 #include <boost/mpl/is_sequence.hpp>
+#include <boost/mpl/map.hpp>
 #include <boost/type_traits/is_same.hpp>
 #include <boost/type_traits/remove_cv.hpp>
-#include <boost/static_assert.hpp>
+#include <boost/type_traits/is_base_of.hpp>
 #include <boost/utility/result_of.hpp>
 
 
 namespace boost { namespace dataflow {
 
-template<typename PortSequence>
+/// Convenience base class for ComponentTraits types.
+template<typename PortSequence, typename DefaultPorts=mpl::map<>, typename ComponentConcept=concepts::component, typename Tag=default_tag>
 struct component_traits
 {
+ /// MPL Sequence of exposed port types.
     typedef PortSequence ports;
+ /// MPL Sequence of default ports.
+ typedef DefaultPorts default_ports;
+ /// Concept the Component models.
+ typedef ComponentConcept concept;
+ /// Tag.
+ typedef Tag tag;
+ /// INTERNAL ONLY
     BOOST_MPL_ASSERT((mpl::is_sequence<PortSequence>));
+ /// INTERNAL ONLY
+ BOOST_MPL_ASSERT((mpl::is_sequence<DefaultPorts>));
+ /// INTERNAL ONLY
+ BOOST_MPL_ASSERT((is_base_of<concepts::component, ComponentConcept>));
 };
 
 /// Boolean metafunction determining whether a type is a ComponentTraits.
 template<typename ComponentTraits, typename Enable=void>
 struct is_component_traits : public mpl::false_
 {
+ /// INTERNAL ONLY
     BOOST_MPL_ASSERT((is_same<Enable, void>));
 };
 
+/// INTERNAL ONLY
 template<typename ComponentTraits>
 struct is_component_traits<ComponentTraits,
     typename detail::enable_if_defined<
- typename ComponentTraits::ports
+ detail::all_of<
+ typename ComponentTraits::ports,
+ typename ComponentTraits::default_ports,
+ typename ComponentTraits::concept,
+ typename ComponentTraits::tag
+ >
>::type>
  : public mpl::true_
 {};
 
-/// Metafunction returning the ComponentTraits of a type.
-template<typename T, typename Enable=void>
+/// Metafunction returning the ComponentTraits of a Component.
+template<typename T, typename Tag=default_tag, typename Enable=void>
 struct component_traits_of
 {
+ /// INTERNAL ONLY
     BOOST_MPL_ASSERT((is_same<Enable, void>));
 };
 
-/// Specialization allowing intrusive specification of the ComponentTraits.
-template<typename T>
-struct component_traits_of<T>
+#ifndef DOXYGEN_DOCS_BUILD
+// Specialization allowing intrusive specification of the ComponentTraits.
+template<typename T, typename Tag>
+struct component_traits_of<
+ T,
+ Tag,
+ typename detail::enable_if_defined<typename T::component_traits>::type >
 {
     typedef typename T::component_traits type;
     BOOST_MPL_ASSERT(( is_component_traits<type> ));
 };
+#endif // DOXYGEN_DOCS_BUILD
 
+/// Boolean metafunction determining whether a type is a Component.
+template<typename T, typename Tag=default_tag, typename Enable=void>
+struct is_component
+ : public mpl::false_ {};
+
+/// INTERNAL ONLY
+template<typename T, typename Tag>
+struct is_component<
+ T,
+ Tag,
+ typename detail::enable_if_defined<
+ typename component_traits_of<T, Tag>::type
+ >::type >
+ : public mpl::true_ {};
+
+/// Convenience base class for Component types.
+template<typename ComponentTraits>
+struct component
+{
+ /// ComponentTraits of the Component.
+ typedef ComponentTraits component_traits;
+};
+
+#ifndef DOXYGEN_DOCS_BUILD
 namespace extension {
 
     template<typename ComponentTraits, typename Enable=void>
- struct get_component_port_impl
+ struct get_port_impl
     {
         BOOST_MPL_ASSERT((is_same<Enable, void>));
 
         typedef void result_type;
         
- struct detail
- {
- typedef void not_specialized;
- };
+ typedef void not_specialized;
 
- template<typename Component, typename T>
- void operator()(Component &, T)
+ template<typename Component, int N>
+ void operator()(Component &, mpl::int_<N>)
         {
- // Error: get_component_port_impl has not been
+ // Error: get_port_impl has not been
             // implemented for ComponentTraits.
             BOOST_STATIC_ASSERT(sizeof(Component)==0);
         }
@@ -82,25 +132,96 @@
     
 } // namespace extension
 
-template<typename T, typename Component>
-struct get_component_port_result_type
+namespace result_of
 {
- typedef typename result_of<
- extension::get_component_port_impl<
- typename component_traits_of<Component>::type
- >(Component &, T)>::type type;
-};
+ template<typename Component, int N>
+ struct get_port_c
+ {
+ typedef typename boost::result_of<
+ extension::get_port_impl<
+ typename component_traits_of<Component>::type
+ >(Component &, mpl::int_<N>)>::type type;
+ };
+
+ template<typename Component, typename N>
+ struct get_port
+ {
+ typedef typename get_port_c<Component, N::value>::type type;
+ };
+}
+
+template<int N, typename Component>
+inline typename result_of::get_port_c<Component, N>::type
+get_port_c(Component &component)
+{
+ return
+ extension::get_port_impl<
+ typename component_traits_of<Component>::type
+ >()(component, mpl::int_<N>());
+}
 
-template<typename T, typename Component>
-typename get_component_port_result_type<T, Component>::type
-get_component_port(Component &component)
+template<typename N, typename Component>
+inline typename result_of::get_port<Component, N>::type
+get_port(Component &component)
 {
     return
- extension::get_component_port_impl<
+ extension::get_port_impl<
             typename component_traits_of<Component>::type
- >()(component, T());
+ >()(component, mpl::int_<N::value>());
 }
 
+template<typename Direction, typename Mechanism=default_mechanism>
+struct default_port_selector
+{
+ typedef Direction direction;
+ typedef Mechanism mechanism;
+};
+
+template<typename T, typename Tag>
+struct traits_of<T, Tag, typename enable_if<is_component<T> >::type>
+ : public component_traits_of<T>
+{};
+
+namespace extension {
+
+ template<typename ComponentTraits, typename Direction, typename Mechanism>
+ struct get_default_port_impl<
+ ComponentTraits,
+ Direction,
+ Mechanism,
+ typename enable_if<
+ mpl::and_<
+ is_component_traits<ComponentTraits>,
+ mpl::has_key<
+ typename ComponentTraits::default_ports,
+ default_port_selector<Direction, Mechanism>
+ >
+ >
+ >::type >
+ {
+ typedef typename mpl::at<
+ typename ComponentTraits::default_ports,
+ default_port_selector<Direction, Mechanism>
+ >::type port_number;
+
+ template<typename FArgs>
+ struct result;
+
+ template<typename F, typename Component>
+ struct result<F(Component &)>
+ {
+ typedef typename result_of::get_port<Component, port_number>::type type;
+ };
+
+ template<typename Component>
+ typename result<get_default_port_impl(Component &)>::type operator()(Component &c)
+ {
+ return get_port<port_number>(c);
+ }
+ };
+
+} // namespace extension
+#endif // DOXYGEN_DOCS_BUILD
 
 } } // namespace boost::dataflow
 

Added: sandbox/SOC/2007/signals/boost/dataflow/support/default_port_provider.hpp
==============================================================================
--- (empty file)
+++ sandbox/SOC/2007/signals/boost/dataflow/support/default_port_provider.hpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -0,0 +1,111 @@
+// Copyright 2007 Stjepan Rajko.
+// 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)
+
+#ifndef BOOST_DATAFLOW_SUPPORT_DEFAULT_PORT_PROVIDER_HPP
+#define BOOST_DATAFLOW_SUPPORT_DEFAULT_PORT_PROVIDER_HPP
+
+#include <boost/dataflow/detail/enable_if_defined.hpp>
+#include <boost/dataflow/support/tags.hpp>
+
+#include <boost/mpl/bool.hpp>
+#include <boost/type_traits/remove_reference.hpp>
+
+namespace boost { namespace dataflow {
+
+/// Metafunction returning the traits of a type.
+template<typename T, typename Tag=default_tag, typename Enable=void>
+struct traits_of
+{
+#ifdef DOXYGEN_DOCS_BUILD
+ /// The traits of T.
+ typedef detail::unspecified type;
+#endif
+};
+
+/// Boolean Metafunction determining whether a type has traits.
+template<typename T, typename Tag=default_tag, typename Enable=void>
+struct has_traits : public mpl::false_
+{
+#ifdef DOXYGEN_DOCS_BUILD
+ /// Integral Constant value type
+ typedef bool value_type;
+ /// true if T has traits, false otherwise.
+ typedef detail::unspecified value;
+ /// Boolean Integral Constant
+ typedef detail::unspecified type;
+#endif
+};
+
+/// INTERNAL ONLY
+template<typename T, typename Tag>
+struct has_traits<
+ T,
+ Tag,
+ typename detail::enable_if_defined<typename traits_of<T, Tag>::type>::type >
+ : public mpl::true_
+{};
+
+} } // namespace boost::dataflow
+
+// ***************************************
+// * get_default_port, has_default_port
+// ***************************************
+#ifdef DOXYGEN_DOCS_BUILD
+
+namespace boost { namespace dataflow {
+
+// THIS IS A DOXYGEN DEFINITION ONLY!
+/// Returns the default port for a Direction and Mechanism.
+template<typename Direction, typename Mechanism,
+ Tag=default_tag, typename T1>
+inline detail::unspecified get_default_port(T1 &t1);
+
+// THIS IS A DOXYGEN DEFINITION ONLY!
+/// Boolean Metafunction determining whether a type has a default port.
+template<
+ typename T,
+ typename Direction, typename Mechanism=default_mechanism,
+ typename Tag=default_tag,
+ typename Enable=void>
+struct has_default_port
+{};
+
+}}
+
+#else
+
+#define DATAFLOW_SPECIALIZABLE_OPERATION_NAME get_default_port
+#define DATAFLOW_SPECIALIZABLE_OPERATION_CHECK has_default_port
+#define DATAFLOW_SPECIALIZABLE_OPERATION_TYPENAME_TEMPLATES_WDEFAULTS typename Direction, typename Mechanism=default_mechanism
+#define DATAFLOW_SPECIALIZABLE_OPERATION_TYPENAME_TEMPLATES typename Direction, typename Mechanism
+#define DATAFLOW_SPECIALIZABLE_OPERATION_TEMPLATES Direction, Mechanism
+#define DATAFLOW_SPECIALIZABLE_OPERATION_USE_TAG_IN_IMPL
+#define DATAFLOW_SPECIALIZABLE_OPERATION_ARITY 1
+#define DATAFLOW_SPECIALIZABLE_OPERATION_TRAITS_OF traits_of
+#define DATAFLOW_SPECIALIZABLE_OPERATION_HAS_TRAITS has_traits
+#include <boost/dataflow/support/detail/make_specializable_operation.hpp>
+
+#endif // DOXYGEN_DOCS_BUILD
+namespace boost { namespace dataflow {
+
+/// Metafunction returning the PortTraits of a default Port.
+template<typename T, typename Direction, typename Mechanism=default_mechanism, typename Tag=default_tag, typename Enable=void>
+struct default_port_traits_of
+{
+#ifndef DOXYGEN_DOCS_BUILD
+ typedef typename port_traits_of<
+ typename remove_reference<
+ typename result_of::get_default_port<T, Direction, Mechanism, Tag>::type
+ >::type,
+ Tag
+ >::type type;
+#else
+ typedef detail::unspecified type; ///< A PortTraits type.
+#endif
+};
+
+} } // namespace boost::dataflow
+
+#endif // BOOST_DATAFLOW_SUPPORT_DEFAULT_PORT_PROVIDER_HPP

Added: sandbox/SOC/2007/signals/boost/dataflow/support/detail/make_specializable_operation.hpp
==============================================================================
--- (empty file)
+++ sandbox/SOC/2007/signals/boost/dataflow/support/detail/make_specializable_operation.hpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -0,0 +1,228 @@
+// Copyright 2007 Stjepan Rajko.
+// 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)
+
+// expects:
+// DATAFLOW_SPECIALIZABLE_OPERATION_NAME
+// DATAFLOW_SPECIALIZABLE_OPERATION_TYPENAME_TEMPLATES
+// DATAFLOW_SPECIALIZABLE_OPERATION_TEMPLATES
+// DATAFLOW_SPECIALIZABLE_OPERATION_ARITY
+// DATAFLOW_SPECIALIZABLE_OPERATION_CHECK
+// DATAFLOW_SPECIALIZABLE_OPERATION_TRAITS_OF
+
+#ifndef DATAFLOW_SPECIALIZABLE_OPERATION_NAME
+#error DATAFLOW_SPECIALIZABLE_OPERATION_NAME undefined
+#endif
+#ifndef DATAFLOW_SPECIALIZABLE_OPERATION_TYPENAME_TEMPLATES
+#error DATAFLOW_SPECIALIZABLE_OPERATION_TYPENAME_TEMPLATES undefined
+#endif
+#ifndef DATAFLOW_SPECIALIZABLE_OPERATION_TEMPLATES
+#error DATAFLOW_SPECIALIZABLE_OPERATION_TEMPLATES undefined
+#endif
+#ifndef DATAFLOW_SPECIALIZABLE_OPERATION_ARITY
+#error DATAFLOW_SPECIALIZABLE_OPERATION_ARITY undefined
+#endif
+#ifndef DATAFLOW_SPECIALIZABLE_OPERATION_CHECK
+#error DATAFLOW_SPECIALIZABLE_OPERATION_CHECK undefined
+#endif
+#ifndef DATAFLOW_SPECIALIZABLE_OPERATION_TRAITS_OF
+#error DATAFLOW_SPECIALIZABLE_OPERATION_TRAITS_OF undefined
+#endif
+#ifndef DATAFLOW_SPECIALIZABLE_OPERATION_HAS_TRAITS
+#error DATAFLOW_SPECIALIZABLE_OPERATION_HAS_TRAITS undefined
+#endif
+
+// optional:
+// DATAFLOW_SPECIALIZABLE_OPERATION_TYPENAME_TEMPLATES_WDEFAULTS
+#ifndef DATAFLOW_SPECIALIZABLE_OPERATION_TYPENAME_TEMPLATES_WDEFAULTS
+#define DATAFLOW_SPECIALIZABLE_OPERATION_TYPENAME_TEMPLATES_WDEFAULTS DATAFLOW_SPECIALIZABLE_OPERATION_TYPENAME_TEMPLATES
+#endif
+
+#ifndef BOOST_DATAFLOW_DETAIL_MAKE_SPECIALIZABLE_OPERATION
+#define BOOST_DATAFLOW_DETAIL_MAKE_SPECIALIZABLE_OPERATION
+
+#include <boost/mpl/assert.hpp>
+#include <boost/mpl/bool.hpp>
+#include <boost/preprocessor/cat.hpp>
+#include <boost/utility/result_of.hpp>
+
+namespace boost { namespace dataflow { namespace detail {
+
+struct not_specialized {};
+
+} } }
+
+#endif
+
+
+#define DATAFLOW_SPECIALIZABLE_OPERATION_IMPL BOOST_PP_CAT(DATAFLOW_SPECIALIZABLE_OPERATION_NAME,_impl)
+#define DATAFLOW_SPECIALIZABLE_OPERATION_CHECK_SPECIALIZED BOOST_PP_CAT(DATAFLOW_SPECIALIZABLE_OPERATION_CHECK,_specialized)
+#if DATAFLOW_SPECIALIZABLE_OPERATION_ARITY==1
+# define DATAFLOW_SPECIALIZABLE_OPERATION_TYPENAME_TRAITS typename Traits
+# define DATAFLOW_SPECIALIZABLE_OPERATION_TYPENAME_TS typename T1
+# define DATAFLOW_SPECIALIZABLE_OPERATION_TS T1
+# define DATAFLOW_SPECIALIZABLE_OPERATION_TARGS T1 &
+# define DATAFLOW_SPECIALIZABLE_OPERATION_NAMED_TARGS T1 &t1
+# define DATAFLOW_SPECIALIZABLE_OPERATION_TARGS_NAMES t1
+# define DATAFLOW_SPECIALIZABLE_OPERATION_GET_TRAITS \
+ typename DATAFLOW_SPECIALIZABLE_OPERATION_TRAITS_OF<T1, Tag>::type
+# define DATAFLOW_SPECIALIZABLE_OPERATION_CHECK_TRAITS \
+ typename DATAFLOW_SPECIALIZABLE_OPERATION_HAS_TRAITS<T1, Tag>::type
+#elif DATAFLOW_SPECIALIZABLE_OPERATION_ARITY==2
+# define DATAFLOW_SPECIALIZABLE_OPERATION_TYPENAME_TRAITS typename Traits1, typename Traits2
+# define DATAFLOW_SPECIALIZABLE_OPERATION_TYPENAME_TS typename T1, typename T2
+# define DATAFLOW_SPECIALIZABLE_OPERATION_TS T1, T2
+# define DATAFLOW_SPECIALIZABLE_OPERATION_TARGS T1 &, T2 &
+# define DATAFLOW_SPECIALIZABLE_OPERATION_NAMED_TARGS T1 &t1, T2 &t2
+# define DATAFLOW_SPECIALIZABLE_OPERATION_TARGS_NAMES t1, t2
+# define DATAFLOW_SPECIALIZABLE_OPERATION_GET_TRAITS \
+ typename DATAFLOW_SPECIALIZABLE_OPERATION_TRAITS_OF<T1, Tag>::type, \
+ typename DATAFLOW_SPECIALIZABLE_OPERATION_TRAITS_OF<T2, Tag>::type
+# define DATAFLOW_SPECIALIZABLE_OPERATION_CHECK_TRAITS \
+ typename DATAFLOW_SPECIALIZABLE_OPERATION_HAS_TRAITS<T1, Tag>::type, \
+ typename DATAFLOW_SPECIALIZABLE_OPERATION_HAS_TRAITS<T2, Tag>::type
+#endif
+
+namespace boost { namespace dataflow {
+
+namespace extension
+{
+ template<
+ DATAFLOW_SPECIALIZABLE_OPERATION_TYPENAME_TRAITS,
+ DATAFLOW_SPECIALIZABLE_OPERATION_TYPENAME_TEMPLATES,
+ typename Enable=void>
+ struct DATAFLOW_SPECIALIZABLE_OPERATION_IMPL
+ {
+ BOOST_MPL_ASSERT(( is_same<Enable, void> ));
+
+ typedef detail::not_specialized result_type;
+
+ template<DATAFLOW_SPECIALIZABLE_OPERATION_TYPENAME_TS>
+ result_type operator()(DATAFLOW_SPECIALIZABLE_OPERATION_TARGS)
+ {
+ // Error: DATAFLOW_SPECIALIZABLE_OPERATION_IMPL has not been
+ // specialized appropriately.
+ BOOST_MPL_ASSERT(( mpl::bool_<sizeof(T1)==0> ));
+ return result_type();
+ }
+ };
+}
+
+namespace detail
+{
+
+ template<
+ DATAFLOW_SPECIALIZABLE_OPERATION_TYPENAME_TS,
+ DATAFLOW_SPECIALIZABLE_OPERATION_TYPENAME_TEMPLATES_WDEFAULTS,
+ typename Tag=default_tag,
+ typename Enable=void>
+ struct DATAFLOW_SPECIALIZABLE_OPERATION_CHECK_SPECIALIZED
+ : public mpl::true_
+ {};
+
+ template<
+ DATAFLOW_SPECIALIZABLE_OPERATION_TYPENAME_TS,
+ DATAFLOW_SPECIALIZABLE_OPERATION_TYPENAME_TEMPLATES,
+ typename Tag>
+ struct DATAFLOW_SPECIALIZABLE_OPERATION_CHECK_SPECIALIZED<
+ DATAFLOW_SPECIALIZABLE_OPERATION_TS,
+ DATAFLOW_SPECIALIZABLE_OPERATION_TEMPLATES,
+ Tag,
+ typename enable_if<
+ is_same<
+ typename extension::DATAFLOW_SPECIALIZABLE_OPERATION_IMPL<
+ DATAFLOW_SPECIALIZABLE_OPERATION_GET_TRAITS,
+ DATAFLOW_SPECIALIZABLE_OPERATION_TEMPLATES
+ >::result_type,
+ detail::not_specialized>
+ >::type>
+ : public mpl::false_
+ {};
+
+}
+
+template<
+ DATAFLOW_SPECIALIZABLE_OPERATION_TYPENAME_TS,
+ DATAFLOW_SPECIALIZABLE_OPERATION_TYPENAME_TEMPLATES_WDEFAULTS,
+ typename Tag=default_tag,
+ typename Enable=void>
+struct DATAFLOW_SPECIALIZABLE_OPERATION_CHECK
+ : public mpl::false_
+{};
+
+template<
+ DATAFLOW_SPECIALIZABLE_OPERATION_TYPENAME_TS,
+ DATAFLOW_SPECIALIZABLE_OPERATION_TYPENAME_TEMPLATES,
+ typename Tag>
+struct DATAFLOW_SPECIALIZABLE_OPERATION_CHECK<
+ DATAFLOW_SPECIALIZABLE_OPERATION_TS,
+ DATAFLOW_SPECIALIZABLE_OPERATION_TEMPLATES,
+ Tag,
+ typename enable_if<
+ mpl::and_<
+ DATAFLOW_SPECIALIZABLE_OPERATION_CHECK_TRAITS,
+ detail::DATAFLOW_SPECIALIZABLE_OPERATION_CHECK_SPECIALIZED<
+ DATAFLOW_SPECIALIZABLE_OPERATION_TS,
+ DATAFLOW_SPECIALIZABLE_OPERATION_TEMPLATES,
+ Tag>
+ >
+ >::type>
+ : public mpl::true_
+{};
+
+
+namespace result_of {
+
+ template<
+ DATAFLOW_SPECIALIZABLE_OPERATION_TYPENAME_TS,
+ DATAFLOW_SPECIALIZABLE_OPERATION_TYPENAME_TEMPLATES_WDEFAULTS,
+ typename Tag=default_tag>
+ struct DATAFLOW_SPECIALIZABLE_OPERATION_NAME
+ {
+ typedef typename boost::result_of<
+ extension::DATAFLOW_SPECIALIZABLE_OPERATION_IMPL<
+ DATAFLOW_SPECIALIZABLE_OPERATION_GET_TRAITS,
+ DATAFLOW_SPECIALIZABLE_OPERATION_TEMPLATES
+ >
+ (DATAFLOW_SPECIALIZABLE_OPERATION_TARGS)
+ >::type type;
+ };
+
+}
+
+template<
+ DATAFLOW_SPECIALIZABLE_OPERATION_TYPENAME_TEMPLATES,
+ typename Tag,
+ DATAFLOW_SPECIALIZABLE_OPERATION_TYPENAME_TS>
+inline typename result_of::DATAFLOW_SPECIALIZABLE_OPERATION_NAME<
+ DATAFLOW_SPECIALIZABLE_OPERATION_TS,
+ DATAFLOW_SPECIALIZABLE_OPERATION_TEMPLATES,
+ Tag>::type
+DATAFLOW_SPECIALIZABLE_OPERATION_NAME(DATAFLOW_SPECIALIZABLE_OPERATION_NAMED_TARGS)
+{
+ return extension::DATAFLOW_SPECIALIZABLE_OPERATION_IMPL<
+ DATAFLOW_SPECIALIZABLE_OPERATION_GET_TRAITS,
+ DATAFLOW_SPECIALIZABLE_OPERATION_TEMPLATES
+ >()(DATAFLOW_SPECIALIZABLE_OPERATION_TARGS_NAMES);
+}
+
+}}
+
+#undef DATAFLOW_SPECIALIZABLE_OPERATION_NAME
+#undef DATAFLOW_SPECIALIZABLE_OPERATION_CHECK_SPECIALIZED
+#undef DATAFLOW_SPECIALIZABLE_OPERATION_TYPENAME_TEMPLATES
+#undef DATAFLOW_SPECIALIZABLE_OPERATION_TYPENAME_TEMPLATES_WDEFAULTS
+#undef DATAFLOW_SPECIALIZABLE_OPERATION_TEMPLATES
+#undef DATAFLOW_SPECIALIZABLE_OPERATION_ARITY
+#undef DATAFLOW_SPECIALIZABLE_OPERATION_CHECK
+#undef DATAFLOW_SPECIALIZABLE_OPERATION_TRAITS_OF
+#undef DATAFLOW_SPECIALIZABLE_OPERATION_HAS_TRAITS
+#undef DATAFLOW_SPECIALIZABLE_OPERATION_TYPENAME_TRAITS
+#undef DATAFLOW_SPECIALIZABLE_OPERATION_TYPENAME_TS
+#undef DATAFLOW_SPECIALIZABLE_OPERATION_TS
+#undef DATAFLOW_SPECIALIZABLE_OPERATION_TARGS
+#undef DATAFLOW_SPECIALIZABLE_OPERATION_NAMED_TARGS
+#undef DATAFLOW_SPECIALIZABLE_OPERATION_TARGS_NAMES
+#undef DATAFLOW_SPECIALIZABLE_OPERATION_GET_TRAITS
+#undef DATAFLOW_SPECIALIZABLE_OPERATION_CHECK_TRAITS

Deleted: sandbox/SOC/2007/signals/boost/dataflow/support/filter.hpp
==============================================================================
--- sandbox/SOC/2007/signals/boost/dataflow/support/filter.hpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
+++ (empty file)
@@ -1,62 +0,0 @@
-// Copyright 2007 Stjepan Rajko.
-// 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)
-
-#ifndef BOOST_DATAFLOW_SUPPORT_FILTER_HPP
-#define BOOST_DATAFLOW_SUPPORT_FILTER_HPP
-
-#include <boost/dataflow/support/producer.hpp>
-#include <boost/dataflow/support/consumer.hpp>
-
-namespace boost { namespace dataflow {
-
-// trait giving the producer category of a type.
-template<typename Mechanism, typename T, typename Enable=void>
-struct filter_category_of
-{
-};
-
-template<typename Mechanism, typename T>
-struct filter_category_of<Mechanism, T,
- typename detail::enable_if_defined<typename T::template dataflow<Mechanism>::filter_category>::type >
-{
- typedef typename T::template dataflow<Mechanism>::filter_category type;
-};
-
-template<typename Mechanism, typename T>
-struct producer_category_of<Mechanism, T,
- typename detail::enable_if_defined<
- typename filter_category_of<Mechanism, T>::type
- >::type >
-{
- typedef typename filter_category_of<Mechanism, T>::type type;
-};
-
-template<typename Mechanism, typename T>
-struct consumer_category_of<Mechanism, T,
- typename detail::enable_if_defined<typename filter_category_of<Mechanism, T>::type>::type >
-{
- typedef typename filter_category_of<Mechanism, T>::type type;
-};
-
-} } // namespace boost::dataflow
-
-#define DATAFLOW_FILTER_CATEGORY(m,p,pc) \
-template<> \
-struct filter_category_of<m, p> \
-{ \
- typedef pc type; \
- BOOST_MPL_ASSERT(( is_producer_category<type> )); \
- BOOST_MPL_ASSERT(( is_consumer_category<type> )); \
-};
-
-#define DATAFLOW_FILTER_CATEGORY_ENABLE_IF(m,P,Cond,pc) \
-template<typename P> \
-struct filter_category_of<m, P, typename boost::enable_if< Cond >::type> \
-{ \
- typedef pc type; \
- BOOST_MPL_ASSERT(( mpl::and_<is_producer_category<type>,is_consumer_category<type> > )); \
-};
-
-#endif // BOOST_DATAFLOW_SUPPORT_FILTER_HPP

Added: sandbox/SOC/2007/signals/boost/dataflow/support/fusion_component.hpp
==============================================================================
--- (empty file)
+++ sandbox/SOC/2007/signals/boost/dataflow/support/fusion_component.hpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -0,0 +1,81 @@
+// Copyright Stjepan Rajko 2007. Use, modification and
+// distribution is subject to 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)
+
+#ifndef BOOST_DATAFLOW_SUPPORT_FUSION_COMPONENT_HPP
+#define BOOST_DATAFLOW_SUPPORT_FUSION_COMPONENT_HPP
+
+#include <boost/dataflow/support/component.hpp>
+
+#include <boost/mpl/map.hpp>
+#include <boost/mpl/transform.hpp>
+#include <boost/fusion/container/vector.hpp>
+#include <boost/fusion/sequence/intrinsic/value_at.hpp>
+#include <boost/fusion/sequence/intrinsic/at.hpp>
+#include <boost/fusion/include/mpl.hpp>
+#include <boost/fusion/include/adapted.hpp>
+
+namespace boost { namespace dataflow {
+
+#ifndef DOXYGEN_DOCS_BUILD
+namespace detail
+{
+ template<typename T>
+ struct transform_remove_reference
+ {
+ typedef typename boost::mpl::transform<T,
+ boost::remove_reference<boost::mpl::_> >::type type;
+ };
+} // namespace detail
+#endif // DOXYGEN_DOCS_BUILD
+
+/// Convenience base class for FusionComponentTraits types.
+template<typename Sequence, typename DefaultPorts=mpl::map<> >
+struct fusion_component_traits
+ : public component_traits<
+ typename detail::transform_remove_reference<Sequence>::type,
+ DefaultPorts,
+ concepts::fusion_component>
+{
+ /// MPL Sequence of result types for get_port
+ typedef Sequence port_result_types;
+};
+
+#ifndef DOXYGEN_DOCS_BUILD
+namespace extension {
+
+ template<typename ComponentTraits>
+ struct get_port_impl<
+ ComponentTraits,
+ typename enable_if<
+ is_same<
+ typename ComponentTraits::concept,
+ concepts::fusion_component>
+ >::type >
+ {
+ template<typename FArgs>
+ struct result;
+
+ template<typename F, typename Component, typename N>
+ struct result<F(Component &, N)>
+ {
+ typedef typename fusion::result_of::value_at<
+ typename ComponentTraits::port_result_types,
+ N>::type type;
+ };
+
+ template<typename Component, typename N>
+ typename result<get_port_impl(Component &, N)>::type
+ operator()(Component &c, N)
+ {
+ return fusion::at<N>(c.get_ports(c));
+ }
+ };
+
+} // namespace extension
+#endif // DOXYGEN_DOCS_BUILD
+
+}}
+
+#endif // BOOST_DATAFLOW_SUPPORT_FUSION_COMPONENT_HPP

Modified: sandbox/SOC/2007/signals/boost/dataflow/support/keyed_port.hpp
==============================================================================
--- sandbox/SOC/2007/signals/boost/dataflow/support/keyed_port.hpp (original)
+++ sandbox/SOC/2007/signals/boost/dataflow/support/keyed_port.hpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -8,6 +8,7 @@
 
 #include <boost/dataflow/support/binary_operation.hpp>
 
+#include <boost/utility/result_of.hpp>
 #include <boost/static_assert.hpp>
 #include <boost/type_traits/integral_constant.hpp>
 #include <boost/type_traits/is_same.hpp>
@@ -20,91 +21,65 @@
     template<typename KeyedPortTag, typename KeyPortTag>
     struct get_keyed_port_impl
     {
- typedef void result_type;
+ typedef detail::not_specialized result_type;
 
         template<typename KeyedPort, typename Key>
- void operator()(KeyedPort &)
+ result_type operator()(KeyedPort &)
         {
             // Error: get_keyed_port_impl has not been implemented
             // for KeyedPortTag and KeyPort.
             BOOST_STATIC_ASSERT(sizeof(KeyedPort)==0);
+ return result_type();
         }
     };
 }
 
-/*template<typename Mechanism, typename PortCategory, typename KeyPort, typename T>
-inline typename result_of<
+template<typename KeyPortTraits, typename Tag, typename KeyedPort>
+inline typename boost::result_of<
     extension::get_keyed_port_impl<
- typename port_traits_of<
- Mechanism, PortCategory, typename boost::remove_cv<T>::type
- >::type,
- typename port_traits_of<
- Mechanism, typename PortCategory::complement, typename boost::remove_cv<KeyPort>::type
- >::type
- > (T &)
->::type
-get_keyed_port(T1 &t1, T2 &t2)
-{
- return extension::get_keyed_port_impl<
- typename port_traits_of<
- Mechanism, PortCategory, typename boost::remove_cv<T1>::type
- >::type,
- typename port_traits_of<
- Mechanism, typename PortCategory::complement, typename boost::remove_cv<T2>::type
- >::type
- >()(t1, t2);
-}*/
-
-template<typename KeyPortTraits, typename KeyPort>
-inline typename result_of<
- extension::get_keyed_port_impl<
- typename port_traits_of<
- typename KeyPortTraits::mechanism,
- typename KeyPortTraits::category::complement,
- typename boost::remove_cv<KeyPort>::type
- >::type,
+ typename port_traits_of<KeyedPort, Tag>::type,
         KeyPortTraits
- > (KeyPort &)
+ > (KeyedPort &)
>::type
-get_keyed_port(KeyPort &p)
+get_keyed_port(KeyedPort &p)
 {
     return extension::get_keyed_port_impl<
- typename port_traits_of<
- typename KeyPortTraits::mechanism,
- typename KeyPortTraits::category::complement,
- typename boost::remove_cv<KeyPort>::type
- >::type,
+ typename port_traits_of<KeyedPort, Tag>::type,
         KeyPortTraits
>()(p);
 }
 
 namespace extension
 {
- template<typename Operation, typename ProducerTag, typename ConsumerTag>
- struct binary_operation_impl<Operation, ProducerTag, ConsumerTag,
+ template<typename ProducerTag, typename ConsumerTag, typename Operation>
+ struct binary_operation_impl<ProducerTag, ConsumerTag, Operation,
             typename enable_if<
             boost::is_same<typename ProducerTag::concept, concepts::keyed_port>
>::type >
     {
+ typedef void result_type;
+
         template<typename Producer, typename Consumer>
         void operator()(Producer &producer, Consumer &consumer)
         {
- binary_operation<Operation, typename ProducerTag::mechanism>
- (get_keyed_port<ConsumerTag>(producer), consumer);
+ binary_operation<Operation, typename ConsumerTag::tag>
+ (get_keyed_port<ConsumerTag, typename ProducerTag::tag>(producer), consumer);
         }
     };
     
- template<typename Operation, typename ProducerTag, typename ConsumerTag>
- struct binary_operation_impl<Operation, ProducerTag, ConsumerTag,
+ template<typename ProducerTag, typename ConsumerTag, typename Operation>
+ struct binary_operation_impl<ProducerTag, ConsumerTag, Operation,
             typename enable_if<
             boost::is_same<typename ConsumerTag::concept, concepts::keyed_port>
>::type >
     {
+ typedef void result_type;
+
         template<typename Producer, typename Consumer>
         void operator()(Producer &producer, Consumer &consumer)
         {
- binary_operation<Operation, typename ProducerTag::mechanism>
- (producer, get_keyed_port<ProducerTag>(consumer));
+ binary_operation<Operation, typename ProducerTag::tag>
+ (producer, get_keyed_port<ProducerTag, typename ConsumerTag::tag>(consumer));
         }
     };
 

Modified: sandbox/SOC/2007/signals/boost/dataflow/support/port.hpp
==============================================================================
--- sandbox/SOC/2007/signals/boost/dataflow/support/port.hpp (original)
+++ sandbox/SOC/2007/signals/boost/dataflow/support/port.hpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -6,198 +6,8 @@
 #ifndef BOOST_DATAFLOW_SUPPORT_PORT_HPP
 #define BOOST_DATAFLOW_SUPPORT_PORT_HPP
 
-#include <boost/dataflow/detail/enable_if_defined.hpp>
-#include <boost/dataflow/support/tags.hpp>
-#include <boost/dataflow/utility/underlying_type.hpp>
-
-#include <boost/mpl/and.hpp>
-#include <boost/mpl/at.hpp>
-#include <boost/mpl/assert.hpp>
-#include <boost/mpl/bool.hpp>
-#include <boost/mpl/is_sequence.hpp>
-#include <boost/type_traits/is_same.hpp>
-#include <boost/type_traits/add_reference.hpp>
-#include <boost/type_traits/remove_cv.hpp>
-
-
-namespace boost { namespace dataflow {
-
-/// Boolean metafunction determining whether a type is a PortCategory.
-template<typename T, typename Enable=void>
-struct is_port_category : public mpl::false_
-{};
-
-template<typename PortCategory>
-struct is_port_category<
- PortCategory,
- typename detail::enable_if_defined<
- typename PortCategory::complement
- >::type>
- : public mpl::true_
-{};
-
-/// Convenience class for PortTraits types.
-template<typename Mechanism, typename PortCategory, typename PortConcept>
-struct port_traits
-{
- typedef Mechanism mechanism;
- typedef PortCategory category;
- typedef PortConcept concept;
-};
-
-namespace detail {
- struct enable_guard;
-}
-
-/// Boolean metafunction determining whether a type is a PortTraits.
-template<typename PortTraits, typename Enable=detail::enable_guard>
-struct is_port_traits : public mpl::false_
-{};
-
-template<typename PortTraits>
-struct is_port_traits<PortTraits,
- typename detail::enable_if_defined<
- detail::all_of<
- typename PortTraits::mechanism,
- typename PortTraits::category,
- typename PortTraits::concept
- >,
- detail::enable_guard
- >::type>
- : public mpl::true_
-{
- BOOST_MPL_ASSERT(( is_port_category<typename PortTraits::category> ));
-};
-
-/// Metafunction returning the PortTraits of a type.
-template<typename Mechanism, typename PortCategory, typename T, typename Enable=void>
-struct port_traits_of
-{};
-
-/// Specialization allowing intrusive specification of the PortTraits.
-template<typename Mechanism, typename PortCategory, typename T>
-struct port_traits_of<Mechanism, PortCategory, T,
- typename enable_if<
- mpl::and_<
- mpl::not_<mpl::is_sequence<typename T::port_traits> >,
- is_same<Mechanism, typename T::port_traits::mechanism>,
- is_same<PortCategory, typename T::port_traits::category>
- >
- >::type
->
-{
- typedef typename T::port_traits type;
- BOOST_MPL_ASSERT(( is_port_traits<type> ));
-};
-
-} }
-
-/// Specialization allowing intrusive specification of a sequence of PortTraits.
-#include <boost/dataflow/support/port/detail/port_traits_sequence.hpp>
-
-namespace boost { namespace dataflow {
-
-template<typename Mechanism, typename PortCategory, typename T, typename Enable=void>
-struct register_port_traits
-{};
-
-/// Specialization allowing non-intrusive specification of the PortTraits.
-template<typename Mechanism, typename PortCategory, typename T>
-struct port_traits_of<Mechanism, PortCategory, T,
- typename detail::enable_if_defined<
- typename register_port_traits<
- Mechanism,
- PortCategory,
- typename remove_cv<T>::type
- >::type
- >::type
->
-{
- typedef typename register_port_traits<
- Mechanism,
- PortCategory,
- typename remove_cv<T>::type
- >::type type;
- BOOST_MPL_ASSERT(( is_port_traits<type> ));
-};
-
-/// Boolean metafunction determining whether a type is a Port.
-template<typename Mechanism, typename PortCategory, typename T, typename Enable=void>
-struct is_port
- : public mpl::false_ {};
-
-template<typename Mechanism, typename PortCategory, typename T>
-struct is_port<Mechanism, PortCategory, T,
- typename detail::enable_if_defined<
- typename port_traits_of<Mechanism,PortCategory,T>::type
- >::type >
- : public mpl::true_ {};
-
-/// Convenience base class for Port types.
-template<typename PortTraits>
-struct port
-{
- typedef PortTraits port_traits;
-};
-
-// trait determining whether a type is a port proxy.
-template<typename Mechanism, typename PortCategory, typename T, typename Enable=void>
-struct is_proxy_port
- : public mpl::false_ {};
-
-namespace extension
-{
- template<typename Traits>
- struct get_port_impl;
-}
-
-// T might be a reference to a Port type
-template<typename Mechanism, typename PortCategory, typename T, typename Enable=void>
-struct get_port_result_type
-{
- typedef typename add_reference<T>::type type;
-};
-
-template<typename Mechanism, typename PortCategory, typename T>
-typename disable_if<
- is_proxy_port<Mechanism, PortCategory, T>,
- typename get_port_result_type<Mechanism, PortCategory, T>::type
->::type
-get_port(T &p)
-{
- return p;
-}
-
-} } // namespace boost::dataflow
-
-/// Macro simplifying non-intrusive specification of a type's PortTraits.
-#define DATAFLOW_PORT_TRAITS(Type,PortTraits) \
-namespace boost { namespace dataflow { \
-template<> \
-struct register_port_traits< \
- PortTraits::mechanism, \
- PortTraits::category, \
- Type> \
-{ \
- typedef PortTraits type; \
- BOOST_MPL_ASSERT(( is_port_traits<type> )); \
-}; \
-}}
-
-/// Macro simplifying non-intrusive specification of multiple types'
-/// PortTraits, using a boost::enable_if condition.
-#define DATAFLOW_PORT_TRAITS_ENABLE_IF(Type,Cond,PortTraits) \
-namespace boost { namespace dataflow { \
-template<typename Type> \
-struct register_port_traits< \
- typename PortTraits::mechanism, \
- typename PortTraits::category, \
- Type, \
- typename boost::enable_if< Cond >::type> \
-{ \
- typedef PortTraits type; \
- BOOST_MPL_ASSERT(( is_port_traits<type> )); \
-}; \
-}}
+#include <boost/dataflow/support/port/traits.hpp>
+#include <boost/dataflow/support/port/port.hpp>
+#include <boost/dataflow/support/port/default_port_provider.hpp>
 
 #endif // BOOST_DATAFLOW_SUPPORT_PORT_HPP

Copied: sandbox/SOC/2007/signals/boost/dataflow/support/port/category.hpp (from r41445, /sandbox/SOC/2007/signals/boost/dataflow/support/port.hpp)
==============================================================================
--- /sandbox/SOC/2007/signals/boost/dataflow/support/port.hpp (original)
+++ sandbox/SOC/2007/signals/boost/dataflow/support/port/category.hpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -3,30 +3,32 @@
 // accompanying file LICENSE_1_0.txt or copy at
 // http://www.boost.org/LICENSE_1_0.txt)
 
-#ifndef BOOST_DATAFLOW_SUPPORT_PORT_HPP
-#define BOOST_DATAFLOW_SUPPORT_PORT_HPP
+#ifndef BOOST_DATAFLOW_SUPPORT_PORT_CATEGORY_HPP
+#define BOOST_DATAFLOW_SUPPORT_PORT_CATEGORY_HPP
 
 #include <boost/dataflow/detail/enable_if_defined.hpp>
-#include <boost/dataflow/support/tags.hpp>
-#include <boost/dataflow/utility/underlying_type.hpp>
-
-#include <boost/mpl/and.hpp>
-#include <boost/mpl/at.hpp>
-#include <boost/mpl/assert.hpp>
 #include <boost/mpl/bool.hpp>
-#include <boost/mpl/is_sequence.hpp>
-#include <boost/type_traits/is_same.hpp>
-#include <boost/type_traits/add_reference.hpp>
-#include <boost/type_traits/remove_cv.hpp>
-
 
 namespace boost { namespace dataflow {
 
-/// Boolean metafunction determining whether a type is a PortCategory.
+/// Boolean Metafunction determining whether a type is a PortCategory.
+/** is_port_category<T> is an Integral Constant of type bool.
+ It evaluates to true if T models PortCategory, false otherwise.
+*/
 template<typename T, typename Enable=void>
 struct is_port_category : public mpl::false_
-{};
+{
+#ifdef DOXYGEN_DOCS_BUILD
+ /// Integral Constant value type
+ typedef bool value_type;
+ /// true if T models PortCategory, false otherwise.
+ typedef detail::unspecified value;
+ /// Integral Constant
+ typedef detail::unspecified type;
+#endif
+};
 
+/// INTERNAL ONLY
 template<typename PortCategory>
 struct is_port_category<
     PortCategory,
@@ -36,168 +38,6 @@
  : public mpl::true_
 {};
 
-/// Convenience class for PortTraits types.
-template<typename Mechanism, typename PortCategory, typename PortConcept>
-struct port_traits
-{
- typedef Mechanism mechanism;
- typedef PortCategory category;
- typedef PortConcept concept;
-};
-
-namespace detail {
- struct enable_guard;
-}
-
-/// Boolean metafunction determining whether a type is a PortTraits.
-template<typename PortTraits, typename Enable=detail::enable_guard>
-struct is_port_traits : public mpl::false_
-{};
-
-template<typename PortTraits>
-struct is_port_traits<PortTraits,
- typename detail::enable_if_defined<
- detail::all_of<
- typename PortTraits::mechanism,
- typename PortTraits::category,
- typename PortTraits::concept
- >,
- detail::enable_guard
- >::type>
- : public mpl::true_
-{
- BOOST_MPL_ASSERT(( is_port_category<typename PortTraits::category> ));
-};
-
-/// Metafunction returning the PortTraits of a type.
-template<typename Mechanism, typename PortCategory, typename T, typename Enable=void>
-struct port_traits_of
-{};
-
-/// Specialization allowing intrusive specification of the PortTraits.
-template<typename Mechanism, typename PortCategory, typename T>
-struct port_traits_of<Mechanism, PortCategory, T,
- typename enable_if<
- mpl::and_<
- mpl::not_<mpl::is_sequence<typename T::port_traits> >,
- is_same<Mechanism, typename T::port_traits::mechanism>,
- is_same<PortCategory, typename T::port_traits::category>
- >
- >::type
->
-{
- typedef typename T::port_traits type;
- BOOST_MPL_ASSERT(( is_port_traits<type> ));
-};
-
-} }
-
-/// Specialization allowing intrusive specification of a sequence of PortTraits.
-#include <boost/dataflow/support/port/detail/port_traits_sequence.hpp>
-
-namespace boost { namespace dataflow {
-
-template<typename Mechanism, typename PortCategory, typename T, typename Enable=void>
-struct register_port_traits
-{};
-
-/// Specialization allowing non-intrusive specification of the PortTraits.
-template<typename Mechanism, typename PortCategory, typename T>
-struct port_traits_of<Mechanism, PortCategory, T,
- typename detail::enable_if_defined<
- typename register_port_traits<
- Mechanism,
- PortCategory,
- typename remove_cv<T>::type
- >::type
- >::type
->
-{
- typedef typename register_port_traits<
- Mechanism,
- PortCategory,
- typename remove_cv<T>::type
- >::type type;
- BOOST_MPL_ASSERT(( is_port_traits<type> ));
-};
-
-/// Boolean metafunction determining whether a type is a Port.
-template<typename Mechanism, typename PortCategory, typename T, typename Enable=void>
-struct is_port
- : public mpl::false_ {};
-
-template<typename Mechanism, typename PortCategory, typename T>
-struct is_port<Mechanism, PortCategory, T,
- typename detail::enable_if_defined<
- typename port_traits_of<Mechanism,PortCategory,T>::type
- >::type >
- : public mpl::true_ {};
-
-/// Convenience base class for Port types.
-template<typename PortTraits>
-struct port
-{
- typedef PortTraits port_traits;
-};
-
-// trait determining whether a type is a port proxy.
-template<typename Mechanism, typename PortCategory, typename T, typename Enable=void>
-struct is_proxy_port
- : public mpl::false_ {};
-
-namespace extension
-{
- template<typename Traits>
- struct get_port_impl;
-}
-
-// T might be a reference to a Port type
-template<typename Mechanism, typename PortCategory, typename T, typename Enable=void>
-struct get_port_result_type
-{
- typedef typename add_reference<T>::type type;
-};
-
-template<typename Mechanism, typename PortCategory, typename T>
-typename disable_if<
- is_proxy_port<Mechanism, PortCategory, T>,
- typename get_port_result_type<Mechanism, PortCategory, T>::type
->::type
-get_port(T &p)
-{
- return p;
-}
-
 } } // namespace boost::dataflow
 
-/// Macro simplifying non-intrusive specification of a type's PortTraits.
-#define DATAFLOW_PORT_TRAITS(Type,PortTraits) \
-namespace boost { namespace dataflow { \
-template<> \
-struct register_port_traits< \
- PortTraits::mechanism, \
- PortTraits::category, \
- Type> \
-{ \
- typedef PortTraits type; \
- BOOST_MPL_ASSERT(( is_port_traits<type> )); \
-}; \
-}}
-
-/// Macro simplifying non-intrusive specification of multiple types'
-/// PortTraits, using a boost::enable_if condition.
-#define DATAFLOW_PORT_TRAITS_ENABLE_IF(Type,Cond,PortTraits) \
-namespace boost { namespace dataflow { \
-template<typename Type> \
-struct register_port_traits< \
- typename PortTraits::mechanism, \
- typename PortTraits::category, \
- Type, \
- typename boost::enable_if< Cond >::type> \
-{ \
- typedef PortTraits type; \
- BOOST_MPL_ASSERT(( is_port_traits<type> )); \
-}; \
-}}
-
-#endif // BOOST_DATAFLOW_SUPPORT_PORT_HPP
+#endif // BOOST_DATAFLOW_SUPPORT_PORT_CATEGORY_HPP

Copied: sandbox/SOC/2007/signals/boost/dataflow/support/port/default_port_provider.hpp (from r41445, /sandbox/SOC/2007/signals/boost/dataflow/support/port.hpp)
==============================================================================
--- /sandbox/SOC/2007/signals/boost/dataflow/support/port.hpp (original)
+++ sandbox/SOC/2007/signals/boost/dataflow/support/port/default_port_provider.hpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -3,201 +3,51 @@
 // accompanying file LICENSE_1_0.txt or copy at
 // http://www.boost.org/LICENSE_1_0.txt)
 
-#ifndef BOOST_DATAFLOW_SUPPORT_PORT_HPP
-#define BOOST_DATAFLOW_SUPPORT_PORT_HPP
+#ifndef BOOST_DATAFLOW_SUPPORT_PORT_DEFAULT_PORT_PROVIDER_HPP
+#define BOOST_DATAFLOW_SUPPORT_PORT_DEFAULT_PORT_PROVIDER_HPP
 
-#include <boost/dataflow/detail/enable_if_defined.hpp>
+#include <boost/dataflow/support/default_port_provider.hpp>
+#include <boost/dataflow/support/port/port.hpp>
 #include <boost/dataflow/support/tags.hpp>
-#include <boost/dataflow/utility/underlying_type.hpp>
 
-#include <boost/mpl/and.hpp>
-#include <boost/mpl/at.hpp>
 #include <boost/mpl/assert.hpp>
 #include <boost/mpl/bool.hpp>
-#include <boost/mpl/is_sequence.hpp>
-#include <boost/type_traits/is_same.hpp>
-#include <boost/type_traits/add_reference.hpp>
-#include <boost/type_traits/remove_cv.hpp>
-
+#include <boost/utility/enable_if.hpp>
 
 namespace boost { namespace dataflow {
 
-/// Boolean metafunction determining whether a type is a PortCategory.
-template<typename T, typename Enable=void>
-struct is_port_category : public mpl::false_
-{};
-
-template<typename PortCategory>
-struct is_port_category<
- PortCategory,
- typename detail::enable_if_defined<
- typename PortCategory::complement
- >::type>
- : public mpl::true_
-{};
-
-/// Convenience class for PortTraits types.
-template<typename Mechanism, typename PortCategory, typename PortConcept>
-struct port_traits
-{
- typedef Mechanism mechanism;
- typedef PortCategory category;
- typedef PortConcept concept;
-};
-
-namespace detail {
- struct enable_guard;
-}
-
-/// Boolean metafunction determining whether a type is a PortTraits.
-template<typename PortTraits, typename Enable=detail::enable_guard>
-struct is_port_traits : public mpl::false_
-{};
-
-template<typename PortTraits>
-struct is_port_traits<PortTraits,
- typename detail::enable_if_defined<
- detail::all_of<
- typename PortTraits::mechanism,
- typename PortTraits::category,
- typename PortTraits::concept
- >,
- detail::enable_guard
- >::type>
- : public mpl::true_
-{
- BOOST_MPL_ASSERT(( is_port_category<typename PortTraits::category> ));
-};
-
-/// Metafunction returning the PortTraits of a type.
-template<typename Mechanism, typename PortCategory, typename T, typename Enable=void>
-struct port_traits_of
+template<typename T, typename Tag>
+struct traits_of<T, Tag, typename enable_if<is_port<T, Tag> >::type>
+ : public port_traits_of<T, Tag>
 {};
 
-/// Specialization allowing intrusive specification of the PortTraits.
-template<typename Mechanism, typename PortCategory, typename T>
-struct port_traits_of<Mechanism, PortCategory, T,
- typename enable_if<
- mpl::and_<
- mpl::not_<mpl::is_sequence<typename T::port_traits> >,
- is_same<Mechanism, typename T::port_traits::mechanism>,
- is_same<PortCategory, typename T::port_traits::category>
- >
- >::type
->
-{
- typedef typename T::port_traits type;
- BOOST_MPL_ASSERT(( is_port_traits<type> ));
-};
+namespace extension {
 
-} }
-
-/// Specialization allowing intrusive specification of a sequence of PortTraits.
-#include <boost/dataflow/support/port/detail/port_traits_sequence.hpp>
-
-namespace boost { namespace dataflow {
-
-template<typename Mechanism, typename PortCategory, typename T, typename Enable=void>
-struct register_port_traits
-{};
-
-/// Specialization allowing non-intrusive specification of the PortTraits.
-template<typename Mechanism, typename PortCategory, typename T>
-struct port_traits_of<Mechanism, PortCategory, T,
- typename detail::enable_if_defined<
- typename register_port_traits<
- Mechanism,
- PortCategory,
- typename remove_cv<T>::type
- >::type
- >::type
->
-{
- typedef typename register_port_traits<
- Mechanism,
- PortCategory,
- typename remove_cv<T>::type
- >::type type;
- BOOST_MPL_ASSERT(( is_port_traits<type> ));
-};
-
-/// Boolean metafunction determining whether a type is a Port.
-template<typename Mechanism, typename PortCategory, typename T, typename Enable=void>
-struct is_port
- : public mpl::false_ {};
-
-template<typename Mechanism, typename PortCategory, typename T>
-struct is_port<Mechanism, PortCategory, T,
- typename detail::enable_if_defined<
- typename port_traits_of<Mechanism,PortCategory,T>::type
- >::type >
- : public mpl::true_ {};
-
-/// Convenience base class for Port types.
-template<typename PortTraits>
-struct port
-{
- typedef PortTraits port_traits;
-};
-
-// trait determining whether a type is a port proxy.
-template<typename Mechanism, typename PortCategory, typename T, typename Enable=void>
-struct is_proxy_port
- : public mpl::false_ {};
-
-namespace extension
-{
- template<typename Traits>
- struct get_port_impl;
-}
-
-// T might be a reference to a Port type
-template<typename Mechanism, typename PortCategory, typename T, typename Enable=void>
-struct get_port_result_type
-{
- typedef typename add_reference<T>::type type;
-};
-
-template<typename Mechanism, typename PortCategory, typename T>
-typename disable_if<
- is_proxy_port<Mechanism, PortCategory, T>,
- typename get_port_result_type<Mechanism, PortCategory, T>::type
->::type
-get_port(T &p)
-{
- return p;
-}
+ template<typename PortTraits, typename Direction, typename Mechanism>
+ struct get_default_port_impl<
+ PortTraits,
+ Direction,
+ Mechanism,
+ typename enable_if<is_port_traits<PortTraits> >::type >
+ {
+ template<typename FArgs>
+ struct result;
+
+ template<typename F, typename Port>
+ struct result<F(Port &)>
+ {
+ typedef Port & type;
+ };
+
+ template<typename Port>
+ Port &operator()(Port &p)
+ {
+ return p;
+ }
+ };
+
+} // namespace extension
 
 } } // namespace boost::dataflow
 
-/// Macro simplifying non-intrusive specification of a type's PortTraits.
-#define DATAFLOW_PORT_TRAITS(Type,PortTraits) \
-namespace boost { namespace dataflow { \
-template<> \
-struct register_port_traits< \
- PortTraits::mechanism, \
- PortTraits::category, \
- Type> \
-{ \
- typedef PortTraits type; \
- BOOST_MPL_ASSERT(( is_port_traits<type> )); \
-}; \
-}}
-
-/// Macro simplifying non-intrusive specification of multiple types'
-/// PortTraits, using a boost::enable_if condition.
-#define DATAFLOW_PORT_TRAITS_ENABLE_IF(Type,Cond,PortTraits) \
-namespace boost { namespace dataflow { \
-template<typename Type> \
-struct register_port_traits< \
- typename PortTraits::mechanism, \
- typename PortTraits::category, \
- Type, \
- typename boost::enable_if< Cond >::type> \
-{ \
- typedef PortTraits type; \
- BOOST_MPL_ASSERT(( is_port_traits<type> )); \
-}; \
-}}
-
-#endif // BOOST_DATAFLOW_SUPPORT_PORT_HPP
+#endif // BOOST_DATAFLOW_SUPPORT_PORT_DEFAULT_PORT_PROVIDER_HPP

Modified: sandbox/SOC/2007/signals/boost/dataflow/support/port/detail/port_traits_sequence.hpp
==============================================================================
--- sandbox/SOC/2007/signals/boost/dataflow/support/port/detail/port_traits_sequence.hpp (original)
+++ sandbox/SOC/2007/signals/boost/dataflow/support/port/detail/port_traits_sequence.hpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -10,25 +10,22 @@
 
     #include <boost/preprocessor/iteration/iterate.hpp>
 
+ #include <boost/mpl/at.hpp>
     #include <boost/mpl/int.hpp>
     #include <boost/mpl/less.hpp>
     #include <boost/mpl/size.hpp>
 
+
 namespace boost { namespace dataflow {
 
 namespace detail {
 
- template<typename Mechanism, typename T, int N>
- struct lazy_is_same_port_traits_mechanism
+ template<typename Tag, typename T, int N>
+ struct lazy_is_same_port_traits_tag
     {
- typedef typename is_same<Mechanism, typename mpl::at_c<typename T::port_traits, N>::type::mechanism>::type type;
+ typedef typename is_same<Tag, typename mpl::at_c<typename T::port_traits, N>::type::tag>::type type;
     };
     
- template<typename PortCategory, typename T, int N>
- struct lazy_is_same_port_traits_port_category
- {
- typedef typename is_same<PortCategory, typename mpl::at_c<typename T::port_traits, N>::type::category>::type type;
- };
 }
 
 } }
@@ -43,8 +40,10 @@
 namespace boost { namespace dataflow {
 
 
-template<typename Mechanism, typename PortCategory, typename T>
-struct port_traits_of<Mechanism, PortCategory, T,
+template<typename T, typename Tag>
+struct port_traits_of<
+ T,
+ Tag,
     typename enable_if<
         mpl::and_<
             mpl::is_sequence<typename T::port_traits>,
@@ -52,8 +51,7 @@
                 mpl::int_<BOOST_PP_ITERATION()>,
                 typename mpl::size<typename T::port_traits>::type
>::type,
- detail::lazy_is_same_port_traits_mechanism<Mechanism, T, BOOST_PP_ITERATION()>,
- detail::lazy_is_same_port_traits_port_category<PortCategory, T, BOOST_PP_ITERATION()>
+ detail::lazy_is_same_port_traits_tag<Tag, T, BOOST_PP_ITERATION()>
>
>::type
>

Copied: sandbox/SOC/2007/signals/boost/dataflow/support/port/port.hpp (from r41445, /sandbox/SOC/2007/signals/boost/dataflow/support/port.hpp)
==============================================================================
--- /sandbox/SOC/2007/signals/boost/dataflow/support/port.hpp (original)
+++ sandbox/SOC/2007/signals/boost/dataflow/support/port/port.hpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -3,201 +3,54 @@
 // accompanying file LICENSE_1_0.txt or copy at
 // http://www.boost.org/LICENSE_1_0.txt)
 
-#ifndef BOOST_DATAFLOW_SUPPORT_PORT_HPP
-#define BOOST_DATAFLOW_SUPPORT_PORT_HPP
+#ifndef BOOST_DATAFLOW_SUPPORT_PORT_PORT_HPP
+#define BOOST_DATAFLOW_SUPPORT_PORT_PORT_HPP
 
 #include <boost/dataflow/detail/enable_if_defined.hpp>
+#include <boost/dataflow/support/port/traits.hpp>
 #include <boost/dataflow/support/tags.hpp>
-#include <boost/dataflow/utility/underlying_type.hpp>
 
-#include <boost/mpl/and.hpp>
-#include <boost/mpl/at.hpp>
 #include <boost/mpl/assert.hpp>
 #include <boost/mpl/bool.hpp>
-#include <boost/mpl/is_sequence.hpp>
-#include <boost/type_traits/is_same.hpp>
-#include <boost/type_traits/add_reference.hpp>
-#include <boost/type_traits/remove_cv.hpp>
-
 
 namespace boost { namespace dataflow {
 
-/// Boolean metafunction determining whether a type is a PortCategory.
-template<typename T, typename Enable=void>
-struct is_port_category : public mpl::false_
-{};
-
-template<typename PortCategory>
-struct is_port_category<
- PortCategory,
- typename detail::enable_if_defined<
- typename PortCategory::complement
- >::type>
- : public mpl::true_
-{};
-
-/// Convenience class for PortTraits types.
-template<typename Mechanism, typename PortCategory, typename PortConcept>
-struct port_traits
+/// Boolean Metafunction determining whether a type is a Port.
+/** is_port<T, Tag> is an Integral Constant of type bool.
+ It evaluates to true if T models Port, false otherwise.
+*/
+template<typename T, typename Tag=default_tag, typename Enable=void>
+struct is_port
+ : public mpl::false_
 {
- typedef Mechanism mechanism;
- typedef PortCategory category;
- typedef PortConcept concept;
-};
-
-namespace detail {
- struct enable_guard;
-}
-
-/// Boolean metafunction determining whether a type is a PortTraits.
-template<typename PortTraits, typename Enable=detail::enable_guard>
-struct is_port_traits : public mpl::false_
-{};
-
-template<typename PortTraits>
-struct is_port_traits<PortTraits,
+#ifdef DOXYGEN_DOCS_BUILD
+ /// Integral Constant value type
+ typedef bool value_type;
+ /// true if T models Port, false otherwise.
+ typedef detail::unspecified value;
+ /// Integral Constant
+ typedef detail::unspecified type;
+#endif
+};
+
+/// INTERNAL ONLY
+template<typename T, typename Tag>
+struct is_port<
+ T,
+ Tag,
     typename detail::enable_if_defined<
- detail::all_of<
- typename PortTraits::mechanism,
- typename PortTraits::category,
- typename PortTraits::concept
- >,
- detail::enable_guard
- >::type>
- : public mpl::true_
-{
- BOOST_MPL_ASSERT(( is_port_category<typename PortTraits::category> ));
-};
-
-/// Metafunction returning the PortTraits of a type.
-template<typename Mechanism, typename PortCategory, typename T, typename Enable=void>
-struct port_traits_of
-{};
-
-/// Specialization allowing intrusive specification of the PortTraits.
-template<typename Mechanism, typename PortCategory, typename T>
-struct port_traits_of<Mechanism, PortCategory, T,
- typename enable_if<
- mpl::and_<
- mpl::not_<mpl::is_sequence<typename T::port_traits> >,
- is_same<Mechanism, typename T::port_traits::mechanism>,
- is_same<PortCategory, typename T::port_traits::category>
- >
- >::type
->
-{
- typedef typename T::port_traits type;
- BOOST_MPL_ASSERT(( is_port_traits<type> ));
-};
-
-} }
-
-/// Specialization allowing intrusive specification of a sequence of PortTraits.
-#include <boost/dataflow/support/port/detail/port_traits_sequence.hpp>
-
-namespace boost { namespace dataflow {
-
-template<typename Mechanism, typename PortCategory, typename T, typename Enable=void>
-struct register_port_traits
-{};
-
-/// Specialization allowing non-intrusive specification of the PortTraits.
-template<typename Mechanism, typename PortCategory, typename T>
-struct port_traits_of<Mechanism, PortCategory, T,
- typename detail::enable_if_defined<
- typename register_port_traits<
- Mechanism,
- PortCategory,
- typename remove_cv<T>::type
- >::type
- >::type
->
-{
- typedef typename register_port_traits<
- Mechanism,
- PortCategory,
- typename remove_cv<T>::type
- >::type type;
- BOOST_MPL_ASSERT(( is_port_traits<type> ));
-};
-
-/// Boolean metafunction determining whether a type is a Port.
-template<typename Mechanism, typename PortCategory, typename T, typename Enable=void>
-struct is_port
- : public mpl::false_ {};
-
-template<typename Mechanism, typename PortCategory, typename T>
-struct is_port<Mechanism, PortCategory, T,
- typename detail::enable_if_defined<
- typename port_traits_of<Mechanism,PortCategory,T>::type
- >::type >
+ typename port_traits_of<T, Tag>::type
+ >::type >
     : public mpl::true_ {};
 
 /// Convenience base class for Port types.
 template<typename PortTraits>
 struct port
 {
+ /// PortTraits for the Port.
     typedef PortTraits port_traits;
 };
 
-// trait determining whether a type is a port proxy.
-template<typename Mechanism, typename PortCategory, typename T, typename Enable=void>
-struct is_proxy_port
- : public mpl::false_ {};
-
-namespace extension
-{
- template<typename Traits>
- struct get_port_impl;
-}
-
-// T might be a reference to a Port type
-template<typename Mechanism, typename PortCategory, typename T, typename Enable=void>
-struct get_port_result_type
-{
- typedef typename add_reference<T>::type type;
-};
-
-template<typename Mechanism, typename PortCategory, typename T>
-typename disable_if<
- is_proxy_port<Mechanism, PortCategory, T>,
- typename get_port_result_type<Mechanism, PortCategory, T>::type
->::type
-get_port(T &p)
-{
- return p;
-}
-
 } } // namespace boost::dataflow
 
-/// Macro simplifying non-intrusive specification of a type's PortTraits.
-#define DATAFLOW_PORT_TRAITS(Type,PortTraits) \
-namespace boost { namespace dataflow { \
-template<> \
-struct register_port_traits< \
- PortTraits::mechanism, \
- PortTraits::category, \
- Type> \
-{ \
- typedef PortTraits type; \
- BOOST_MPL_ASSERT(( is_port_traits<type> )); \
-}; \
-}}
-
-/// Macro simplifying non-intrusive specification of multiple types'
-/// PortTraits, using a boost::enable_if condition.
-#define DATAFLOW_PORT_TRAITS_ENABLE_IF(Type,Cond,PortTraits) \
-namespace boost { namespace dataflow { \
-template<typename Type> \
-struct register_port_traits< \
- typename PortTraits::mechanism, \
- typename PortTraits::category, \
- Type, \
- typename boost::enable_if< Cond >::type> \
-{ \
- typedef PortTraits type; \
- BOOST_MPL_ASSERT(( is_port_traits<type> )); \
-}; \
-}}
-
-#endif // BOOST_DATAFLOW_SUPPORT_PORT_HPP
+#endif // BOOST_DATAFLOW_SUPPORT_PORT_PORT_HPP

Added: sandbox/SOC/2007/signals/boost/dataflow/support/port/port_adapter.hpp
==============================================================================
--- (empty file)
+++ sandbox/SOC/2007/signals/boost/dataflow/support/port/port_adapter.hpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -0,0 +1,44 @@
+// Copyright Stjepan Rajko 2007. Use, modification and
+// distribution is subject to 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)
+
+#ifndef DATAFLOW_SUPPORT_PORT_ADAPTER_HPP
+#define DATAFLOW_SUPPORT_PORT_ADAPTER_HPP
+
+#include <boost/dataflow/support/tags.hpp>
+#include <boost/dataflow/support/keyed_port.hpp>
+
+namespace boost { namespace dataflow {
+
+template<typename T, typename PortTraits, typename Tag=default_tag>
+struct port_adapter_traits : public PortTraits
+{};
+
+template<typename T, typename PortTraits, typename Tag=default_tag>
+struct port_adapter : public port<port_adapter_traits<T, PortTraits, Tag> >
+{
+ port_adapter(T & object) : object(object) {}
+ T & object;
+};
+
+namespace extension
+{
+ template<typename T, typename PortTraits, typename Tag, typename KeyPortTraits>
+ struct get_keyed_port_impl<port_adapter_traits<T, PortTraits, Tag>, KeyPortTraits >
+ {
+ typedef typename boost::result_of<
+ get_keyed_port_impl<PortTraits, KeyPortTraits>(T &)
+ >::type result_type;
+
+ template<typename PortAdapter>
+ result_type operator()(PortAdapter &adapter)
+ {
+ return get_keyed_port_impl<PortTraits, KeyPortTraits>()(adapter.object);
+ };
+ };
+}
+
+}} // namespace boost::dataflow
+
+#endif // DATAFLOW_SUPPORT_PORT_ADAPTER_HPP
\ No newline at end of file

Copied: sandbox/SOC/2007/signals/boost/dataflow/support/port/traits.hpp (from r41445, /sandbox/SOC/2007/signals/boost/dataflow/support/port.hpp)
==============================================================================
--- /sandbox/SOC/2007/signals/boost/dataflow/support/port.hpp (original)
+++ sandbox/SOC/2007/signals/boost/dataflow/support/port/traits.hpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -3,201 +3,163 @@
 // accompanying file LICENSE_1_0.txt or copy at
 // http://www.boost.org/LICENSE_1_0.txt)
 
-#ifndef BOOST_DATAFLOW_SUPPORT_PORT_HPP
-#define BOOST_DATAFLOW_SUPPORT_PORT_HPP
+#ifndef BOOST_DATAFLOW_SUPPORT_PORT_TRAITS_HPP
+#define BOOST_DATAFLOW_SUPPORT_PORT_TRAITS_HPP
 
 #include <boost/dataflow/detail/enable_if_defined.hpp>
+#include <boost/dataflow/support/port/category.hpp>
 #include <boost/dataflow/support/tags.hpp>
-#include <boost/dataflow/utility/underlying_type.hpp>
 
-#include <boost/mpl/and.hpp>
-#include <boost/mpl/at.hpp>
 #include <boost/mpl/assert.hpp>
 #include <boost/mpl/bool.hpp>
 #include <boost/mpl/is_sequence.hpp>
+#include <boost/type_traits/is_base_of.hpp>
 #include <boost/type_traits/is_same.hpp>
-#include <boost/type_traits/add_reference.hpp>
 #include <boost/type_traits/remove_cv.hpp>
 
-
 namespace boost { namespace dataflow {
 
-/// Boolean metafunction determining whether a type is a PortCategory.
-template<typename T, typename Enable=void>
-struct is_port_category : public mpl::false_
-{};
-
-template<typename PortCategory>
-struct is_port_category<
- PortCategory,
- typename detail::enable_if_defined<
- typename PortCategory::complement
- >::type>
- : public mpl::true_
-{};
-
 /// Convenience class for PortTraits types.
-template<typename Mechanism, typename PortCategory, typename PortConcept>
+template<typename PortCategory, typename PortConcept=concepts::port,
+ typename Tag=default_tag>
 struct port_traits
 {
- typedef Mechanism mechanism;
- typedef PortCategory category;
+ /// The PortCategory of the port.
+ typedef PortCategory category;
+ /// The PortConcept of the port.
     typedef PortConcept concept;
+ /// The Tag of the port.
+ typedef Tag tag;
+ /// INTERNAL ONLY
+ BOOST_MPL_ASSERT(( is_port_category<PortCategory> ));
+ /// INTERNAL ONLY
+ BOOST_MPL_ASSERT(( is_base_of<concepts::port, PortConcept> ));
 };
 
 namespace detail {
     struct enable_guard;
 }
 
-/// Boolean metafunction determining whether a type is a PortTraits.
+/// Boolean Metafunction determining whether a type is a PortTraits.
 template<typename PortTraits, typename Enable=detail::enable_guard>
 struct is_port_traits : public mpl::false_
-{};
+{
+ /// INTERNAL ONLY
+ BOOST_MPL_ASSERT(( is_same<Enable, detail::enable_guard> ));
+};
 
+/// INTERNAL ONLY
 template<typename PortTraits>
 struct is_port_traits<PortTraits,
     typename detail::enable_if_defined<
         detail::all_of<
- typename PortTraits::mechanism,
             typename PortTraits::category,
- typename PortTraits::concept
+ typename PortTraits::concept,
+ typename PortTraits::tag
>,
         detail::enable_guard
>::type>
  : public mpl::true_
 {
+ /// INTERNAL ONLY
     BOOST_MPL_ASSERT(( is_port_category<typename PortTraits::category> ));
+ /// INTERNAL ONLY
+ BOOST_MPL_ASSERT((is_base_of<concepts::port, typename PortTraits::concept>));
 };
 
 /// Metafunction returning the PortTraits of a type.
-template<typename Mechanism, typename PortCategory, typename T, typename Enable=void>
+template<typename T, typename Tag=default_tag, typename Enable=void>
 struct port_traits_of
-{};
+{
+#ifdef DOXYGEN_DOCS_BUILD
+ typedef detail::unspecified type; ///< PortTraits type.
+#endif
+};
 
-/// Specialization allowing intrusive specification of the PortTraits.
-template<typename Mechanism, typename PortCategory, typename T>
-struct port_traits_of<Mechanism, PortCategory, T,
+/// INTERNAL ONLY
+/** Specialization allowing intrusive specification of the PortTraits.
+*/
+template<typename T>
+struct port_traits_of<
+ T,
+ typename T::port_traits::tag,
     typename enable_if<
- mpl::and_<
- mpl::not_<mpl::is_sequence<typename T::port_traits> >,
- is_same<Mechanism, typename T::port_traits::mechanism>,
- is_same<PortCategory, typename T::port_traits::category>
- >
+ mpl::not_<mpl::is_sequence<typename T::port_traits> >
>::type
>
 {
+ /// INTERNAL ONLY
     typedef typename T::port_traits type;
+ /// INTERNAL ONLY
     BOOST_MPL_ASSERT(( is_port_traits<type> ));
 };
 
 } }
 
-/// Specialization allowing intrusive specification of a sequence of PortTraits.
+// Specialization allowing intrusive specification of a sequence of PortTraits.
 #include <boost/dataflow/support/port/detail/port_traits_sequence.hpp>
 
 namespace boost { namespace dataflow {
 
-template<typename Mechanism, typename PortCategory, typename T, typename Enable=void>
+/// Allows registration of PortTraits for all cv-qualified versions of a type.
+template<typename T, typename Tag=default_tag, typename Enable=void>
 struct register_port_traits
 {};
 
-/// Specialization allowing non-intrusive specification of the PortTraits.
-template<typename Mechanism, typename PortCategory, typename T>
-struct port_traits_of<Mechanism, PortCategory, T,
+
+// Specialization allowing non-intrusive specification of the PortTraits.
+
+/// INTERNAL ONLY
+template<typename T, typename Tag>
+struct port_traits_of<
+ T,
+ Tag,
     typename detail::enable_if_defined<
         typename register_port_traits<
- Mechanism,
- PortCategory,
- typename remove_cv<T>::type
+ typename remove_cv<T>::type,
+ Tag
>::type
>::type
>
 {
- typedef typename register_port_traits<
- Mechanism,
- PortCategory,
- typename remove_cv<T>::type
+ /// INTERNAL ONLY
+ typedef
+ typename register_port_traits<
+ typename remove_cv<T>::type,
+ Tag
>::type type;
+ /// INTERNAL ONLY
     BOOST_MPL_ASSERT(( is_port_traits<type> ));
 };
 
-/// Boolean metafunction determining whether a type is a Port.
-template<typename Mechanism, typename PortCategory, typename T, typename Enable=void>
-struct is_port
- : public mpl::false_ {};
-
-template<typename Mechanism, typename PortCategory, typename T>
-struct is_port<Mechanism, PortCategory, T,
- typename detail::enable_if_defined<
- typename port_traits_of<Mechanism,PortCategory,T>::type
- >::type >
- : public mpl::true_ {};
-
-/// Convenience base class for Port types.
-template<typename PortTraits>
-struct port
-{
- typedef PortTraits port_traits;
-};
-
-// trait determining whether a type is a port proxy.
-template<typename Mechanism, typename PortCategory, typename T, typename Enable=void>
-struct is_proxy_port
- : public mpl::false_ {};
-
-namespace extension
-{
- template<typename Traits>
- struct get_port_impl;
-}
-
-// T might be a reference to a Port type
-template<typename Mechanism, typename PortCategory, typename T, typename Enable=void>
-struct get_port_result_type
-{
- typedef typename add_reference<T>::type type;
-};
-
-template<typename Mechanism, typename PortCategory, typename T>
-typename disable_if<
- is_proxy_port<Mechanism, PortCategory, T>,
- typename get_port_result_type<Mechanism, PortCategory, T>::type
->::type
-get_port(T &p)
-{
- return p;
-}
-
 } } // namespace boost::dataflow
 
 /// Macro simplifying non-intrusive specification of a type's PortTraits.
-#define DATAFLOW_PORT_TRAITS(Type,PortTraits) \
-namespace boost { namespace dataflow { \
-template<> \
-struct register_port_traits< \
- PortTraits::mechanism, \
- PortTraits::category, \
- Type> \
-{ \
- typedef PortTraits type; \
+#define DATAFLOW_PORT_TRAITS(Type,PortTraits) \
+namespace boost { namespace dataflow { \
+template<> \
+struct register_port_traits< \
+ Type, \
+ PortTraits::tag> \
+{ \
+ typedef PortTraits type; \
     BOOST_MPL_ASSERT(( is_port_traits<type> )); \
-}; \
+}; \
 }}
 
 /// Macro simplifying non-intrusive specification of multiple types'
 /// PortTraits, using a boost::enable_if condition.
-#define DATAFLOW_PORT_TRAITS_ENABLE_IF(Type,Cond,PortTraits) \
-namespace boost { namespace dataflow { \
-template<typename Type> \
-struct register_port_traits< \
- typename PortTraits::mechanism, \
- typename PortTraits::category, \
- Type, \
- typename boost::enable_if< Cond >::type> \
-{ \
- typedef PortTraits type; \
- BOOST_MPL_ASSERT(( is_port_traits<type> )); \
-}; \
+#define DATAFLOW_PORT_TRAITS_ENABLE_IF(Type,Cond,PortTraits) \
+namespace boost { namespace dataflow { \
+template<typename Type> \
+struct register_port_traits< \
+ Type, \
+ PortTraits::tag, \
+ typename boost::enable_if< Cond >::type> \
+{ \
+ typedef PortTraits type; \
+ BOOST_MPL_ASSERT(( is_port_traits<type> )); \
+}; \
 }}
 
-#endif // BOOST_DATAFLOW_SUPPORT_PORT_HPP
+#endif // BOOST_DATAFLOW_SUPPORT_PORT_TRAITS_HPP

Modified: sandbox/SOC/2007/signals/boost/dataflow/support/reflective_component.hpp
==============================================================================
--- sandbox/SOC/2007/signals/boost/dataflow/support/reflective_component.hpp (original)
+++ sandbox/SOC/2007/signals/boost/dataflow/support/reflective_component.hpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -22,7 +22,7 @@
 namespace extension {
 
     template<typename ComponentTraits, typename Enable=void>
- struct get_component_port_impl
+ struct get_port_impl
     {
         typedef void result_type;
         
@@ -34,7 +34,7 @@
         template<typename Component, typename T>
         void operator()(Component &, T)
         {
- // Error: get_component_port_impl has not been
+ // Error: get_port_impl has not been
             // implemented for ComponentTraits.
             BOOST_STATIC_ASSERT(sizeof(Component)==0);
         }
@@ -43,20 +43,20 @@
 } // namespace extension
 
 template<typename Mechanism, typename T, typename Component>
-struct get_component_port_result_type
+struct get_port_result_type
 {
     typedef typename result_of<
- extension::get_component_port_impl<
+ extension::get_port_impl<
         typename component_traits_of<Mechanism, Component>::type
>(Component &, T)>::type type;
 };
 
 template<typename Mechanism, typename T, typename Component>
-typename get_component_port_result_type<Mechanism, T, Component>::type
-get_component_port(Component &component)
+typename get_port_result_type<Mechanism, T, Component>::type
+get_port(Component &component)
 {
     return
- extension::get_component_port_impl<
+ extension::get_port_impl<
             typename component_traits_of<Mechanism, Component>::type
>()(component, T());
 }

Modified: sandbox/SOC/2007/signals/boost/dataflow/support/tags.hpp
==============================================================================
--- sandbox/SOC/2007/signals/boost/dataflow/support/tags.hpp (original)
+++ sandbox/SOC/2007/signals/boost/dataflow/support/tags.hpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -9,36 +9,63 @@
 
 namespace boost { namespace dataflow {
 
+/// The default Tag argument for Dataflow templates.
+struct default_tag {};
+/// The default Mechanism argument for Dataflow templates.
+struct default_mechanism {};
+
 /// PortCategory types.
 namespace ports
 {
     struct producer;
     struct consumer;
 
+ /// producer PortCategory.
     struct producer
     {
- typedef consumer complement;
+ typedef consumer complement; ///< complement PortCategory type.
     };
 
+ /// consumer PortCategory.
     struct consumer
     {
- typedef producer complement;
+ typedef producer complement; ///< complement PortCategory type.
     };
 }
 
 namespace concepts
 {
- /// Tag
+ /// PortConcept type specifying the Port concept.
     struct port {};
- struct keyed_port {};
- struct complemented_port {};
+ /// PortConcept tag specifying the KeyedPort concept.
+ struct keyed_port : public port {};
+ /// PortConcept tag specifying the ComplementedPort concept.
+ struct complemented_port : public port {};
+ /// ComponentConcept tag specifying the Component concept.
+ struct component {};
+ /// ComponentConcept tag specifying the FusionComponent concept.
+ struct fusion_component : public component {};
 }
 
 namespace operations {
- struct connect;
- struct connect_only;
- struct disconnect;
- struct extract;
+ /// Tag specifying the connect binary operation.
+ struct connect {};
+ /// Tag specifying the connect_only binary operation.
+ struct connect_only {};
+ /// Tag specifying the disconnect binary operation.
+ struct disconnect {};
+ /// Tag specifying the extract binary operation.
+ struct extract {};
+
+ /// Tag specifying the disconnect_all unary port operation.
+ struct disconnect_all {};
+}
+
+namespace directions {
+ /// Tag specifying the outgoing direction in binary operations.
+ struct outgoing {};
+ /// Tag specifying the incoming direction in binary operations.
+ struct incoming {};
 }
 
 } } // namespace boost::dataflow

Modified: sandbox/SOC/2007/signals/boost/dataflow/support/unary_operation.hpp
==============================================================================
--- sandbox/SOC/2007/signals/boost/dataflow/support/unary_operation.hpp (original)
+++ sandbox/SOC/2007/signals/boost/dataflow/support/unary_operation.hpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -10,64 +10,27 @@
 
 #include <boost/static_assert.hpp>
 
+// ***************************************
+// * unary_operation
+// ***************************************
+#define DATAFLOW_SPECIALIZABLE_OPERATION_NAME unary_operation
+#define DATAFLOW_SPECIALIZABLE_OPERATION_CHECK is_unary_operable
+#define DATAFLOW_SPECIALIZABLE_OPERATION_TYPENAME_TEMPLATES typename Operation
+#define DATAFLOW_SPECIALIZABLE_OPERATION_TEMPLATES Operation
+#define DATAFLOW_SPECIALIZABLE_OPERATION_ARITY 1
+#define DATAFLOW_SPECIALIZABLE_OPERATION_TRAITS_OF port_traits_of
+#define DATAFLOW_SPECIALIZABLE_OPERATION_HAS_TRAITS is_port
+#include <boost/dataflow/support/detail/make_specializable_operation.hpp>
 
-namespace boost { namespace dataflow {
-
-namespace detail {
- struct not_implemented;
-}
 
-namespace operations
-{
- struct disconnect_all;
-}
+namespace boost { namespace dataflow {
 
-namespace extension
+template<typename Port>
+inline void disconnect_all(Port &port)
 {
- template<typename Operation, typename PortTraits, typename Enable=void>
- struct unary_operation_impl
- {
- struct detail
- {
- typedef void not_specialized;
- };
- template<typename Producer>
- void operator()(Producer &)
- {
- // Error: unary_operation_impl Operation has not been
- // implemented for PortTraits.
- BOOST_STATIC_ASSERT(sizeof(Producer)==0);
- }
- };
+ unary_operation<operations::disconnect_all, default_tag>(port);
 }
 
-template<typename Operation, typename Mechanism, typename PortCategory, typename T, typename Enable=void>
-struct implements_unary_operation
- : public mpl::true_ {};
-
-template<typename Operation, typename Mechanism, typename PortCategory, typename T>
-struct implements_unary_operation<
- Operation,
- Mechanism,
- PortCategory,
- T,
- typename detail::enable_if_defined<
- typename extension::unary_operation_impl<
- Operation,
- typename port_traits_of<Mechanism, PortCategory, T>::type
- >::detail::not_specialized
- >::type
->
- : public mpl::false_ {};
-
-template<typename Operation, typename Mechanism, typename PortCategory, typename Port>
-void unary_operation(Port &producer)
-{
- extension::unary_operation_impl<
- Operation,
- typename port_traits_of<Mechanism, PortCategory, Port>::type
- >()(producer);
-}
 
 } } // namespace boost::dataflow
 

Modified: sandbox/SOC/2007/signals/boost/dataflow/templates/binary_operation.hpp
==============================================================================
--- sandbox/SOC/2007/signals/boost/dataflow/templates/binary_operation.hpp (original)
+++ sandbox/SOC/2007/signals/boost/dataflow/templates/binary_operation.hpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -4,6 +4,9 @@
 // http://www.boost.org/LICENSE_1_0.txt)
 
 
+#ifndef DATAFLOW_TEMPLATE_TAG
+#error DATAFLOW_TEMPLATE_TAG undefined.
+#endif
 #ifndef DATAFLOW_TEMPLATE_MECHANISM
 #error DATAFLOW_TEMPLATE_MECHANISM undefined.
 #endif
@@ -14,23 +17,23 @@
 template<typename Producer, typename Consumer>
 inline void DATAFLOW_TEMPLATE_BINARY_OPERATION(Producer &producer, Consumer &consumer)
 {
- boost::dataflow::binary_operation< boost::dataflow::operations::DATAFLOW_TEMPLATE_BINARY_OPERATION, DATAFLOW_TEMPLATE_MECHANISM >(producer, consumer);
+ boost::dataflow::binary_operation< boost::dataflow::operations::DATAFLOW_TEMPLATE_BINARY_OPERATION, DATAFLOW_TEMPLATE_MECHANISM, DATAFLOW_TEMPLATE_TAG >(producer, consumer);
 }
 
 template<typename Producer, typename Consumer>
 inline void DATAFLOW_TEMPLATE_BINARY_OPERATION(Producer &producer, const Consumer &consumer)
 {
- boost::dataflow::binary_operation< boost::dataflow::operations::DATAFLOW_TEMPLATE_BINARY_OPERATION, DATAFLOW_TEMPLATE_MECHANISM >(producer, consumer);
+ boost::dataflow::binary_operation< boost::dataflow::operations::DATAFLOW_TEMPLATE_BINARY_OPERATION, DATAFLOW_TEMPLATE_MECHANISM, DATAFLOW_TEMPLATE_TAG >(producer, consumer);
 }
 
 template<typename Producer, typename Consumer>
 inline void DATAFLOW_TEMPLATE_BINARY_OPERATION(const Producer &producer, Consumer &consumer)
 {
- boost::dataflow::binary_operation< boost::dataflow::operations::DATAFLOW_TEMPLATE_BINARY_OPERATION, DATAFLOW_TEMPLATE_MECHANISM >(producer, consumer);
+ boost::dataflow::binary_operation< boost::dataflow::operations::DATAFLOW_TEMPLATE_BINARY_OPERATION, DATAFLOW_TEMPLATE_MECHANISM, DATAFLOW_TEMPLATE_TAG >(producer, consumer);
 }
 
 template<typename Producer, typename Consumer>
 inline void DATAFLOW_TEMPLATE_BINARY_OPERATION(const Producer &producer, const Consumer &consumer)
 {
- boost::dataflow::binary_operation< boost::dataflow::operations::DATAFLOW_TEMPLATE_BINARY_OPERATION, DATAFLOW_TEMPLATE_MECHANISM >(producer, consumer);
+ boost::dataflow::binary_operation< boost::dataflow::operations::DATAFLOW_TEMPLATE_BINARY_OPERATION, DATAFLOW_TEMPLATE_MECHANISM, DATAFLOW_TEMPLATE_TAG >(producer, consumer);
 }

Modified: sandbox/SOC/2007/signals/boost/dataflow/templates/operator.hpp
==============================================================================
--- sandbox/SOC/2007/signals/boost/dataflow/templates/operator.hpp (original)
+++ sandbox/SOC/2007/signals/boost/dataflow/templates/operator.hpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -4,6 +4,9 @@
 // http://www.boost.org/LICENSE_1_0.txt)
 
 
+#ifndef DATAFLOW_TEMPLATE_TAG
+#error DATAFLOW_TEMPLATE_TAG undefined.
+#endif
 #ifndef DATAFLOW_TEMPLATE_MECHANISM
 #error DATAFLOW_TEMPLATE_MECHANISM undefined.
 #endif
@@ -13,47 +16,23 @@
 #ifndef DATAFLOW_TEMPLATE_BINARY_OPERATION
 #error DATAFLOW_TEMPLATE_OPERATOR undefined.
 #endif
-
-template<typename Producer, typename Consumer>
-typename boost::enable_if<
- boost::mpl::and_<
- boost::dataflow::is_port<DATAFLOW_TEMPLATE_MECHANISM, boost::dataflow::ports::producer, Producer>,
- boost::dataflow::is_port<DATAFLOW_TEMPLATE_MECHANISM, boost::dataflow::ports::consumer, Consumer>
- >,
- Producer &
->::type
-operator DATAFLOW_TEMPLATE_OPERATOR (Producer &producer, Consumer &consumer)
-{ DATAFLOW_TEMPLATE_BINARY_OPERATION(producer, consumer); return producer;}
-
-template<typename Producer, typename Consumer>
-typename boost::enable_if<
- boost::mpl::and_<
- boost::dataflow::is_port<DATAFLOW_TEMPLATE_MECHANISM, boost::dataflow::ports::producer, Producer>,
- boost::dataflow::is_port<DATAFLOW_TEMPLATE_MECHANISM, boost::dataflow::ports::consumer, Consumer>
- >,
- Producer &
->::type
-operator DATAFLOW_TEMPLATE_OPERATOR (Producer &producer, const Consumer &consumer)
-{ DATAFLOW_TEMPLATE_BINARY_OPERATION(producer, consumer); return producer;}
-
-template<typename Producer, typename Consumer>
-typename boost::enable_if<
- boost::mpl::and_<
- boost::dataflow::is_port<DATAFLOW_TEMPLATE_MECHANISM, boost::dataflow::ports::producer, Producer>,
- boost::dataflow::is_port<DATAFLOW_TEMPLATE_MECHANISM, boost::dataflow::ports::consumer, Consumer>
- >,
- const Producer &
+
+template<typename OutgoingPort, typename IncomingPort>
+inline typename enable_if<
+ mpl::and_<
+ boost::dataflow::has_default_port<OutgoingPort, boost::dataflow::directions::outgoing, DATAFLOW_TEMPLATE_MECHANISM, DATAFLOW_TEMPLATE_TAG>,
+ boost::dataflow::has_default_port<IncomingPort, boost::dataflow::directions::incoming, DATAFLOW_TEMPLATE_MECHANISM, DATAFLOW_TEMPLATE_TAG>
+ >, OutgoingPort &
>::type
-operator DATAFLOW_TEMPLATE_OPERATOR (const Producer &producer, Consumer &consumer)
-{ DATAFLOW_TEMPLATE_BINARY_OPERATION(producer, consumer); return producer;}
+operator DATAFLOW_TEMPLATE_OPERATOR (OutgoingPort &outgoing, IncomingPort &incoming)
+{ DATAFLOW_TEMPLATE_BINARY_OPERATION(outgoing, incoming); return outgoing;}
 
-template<typename Producer, typename Consumer>
-typename boost::enable_if<
- boost::mpl::and_<
- boost::dataflow::is_port<DATAFLOW_TEMPLATE_MECHANISM, boost::dataflow::ports::producer, Producer>,
- boost::dataflow::is_port<DATAFLOW_TEMPLATE_MECHANISM, boost::dataflow::ports::consumer, Consumer>
- >,
- const Producer &
+template<typename OutgoingPort, typename IncomingPort>
+inline typename enable_if<
+ mpl::and_<
+ boost::dataflow::has_default_port<OutgoingPort, boost::dataflow::directions::outgoing, DATAFLOW_TEMPLATE_MECHANISM, DATAFLOW_TEMPLATE_TAG>,
+ boost::dataflow::has_default_port<IncomingPort, boost::dataflow::directions::incoming, DATAFLOW_TEMPLATE_MECHANISM, DATAFLOW_TEMPLATE_TAG>
+ >, OutgoingPort &
>::type
-operator DATAFLOW_TEMPLATE_OPERATOR (const Producer &producer, const Consumer &consumer)
-{ DATAFLOW_TEMPLATE_BINARY_OPERATION(producer, consumer); return producer;}
+operator DATAFLOW_TEMPLATE_OPERATOR (OutgoingPort &outgoing, const IncomingPort &incoming)
+{ DATAFLOW_TEMPLATE_BINARY_OPERATION(outgoing, incoming); return outgoing;}

Modified: sandbox/SOC/2007/signals/libs/dataflow/build/xcodeide/signal_network.xcodeproj/project.pbxproj
==============================================================================
--- sandbox/SOC/2007/signals/libs/dataflow/build/xcodeide/signal_network.xcodeproj/project.pbxproj (original)
+++ sandbox/SOC/2007/signals/libs/dataflow/build/xcodeide/signal_network.xcodeproj/project.pbxproj 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -81,11 +81,6 @@
                 0800AC3A0C8CAAC300994538 /* Jamfile.v2 */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; name = Jamfile.v2; path = ../../../../Jamfile.v2; sourceTree = SOURCE_ROOT; };
                 0800AC3B0C8CAAC300994538 /* project-root.jam */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.jam; name = "project-root.jam"; path = "../../../../project-root.jam"; sourceTree = SOURCE_ROOT; };
                 0801B4370CE9488B00A7A8D1 /* operator.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = operator.hpp; sourceTree = "<group>"; };
- 0801C6980CF8F8E600820AC8 /* component.qbk */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; path = component.qbk; sourceTree = "<group>"; };
- 0801C6990CF8F8E600820AC8 /* port.qbk */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; path = port.qbk; sourceTree = "<group>"; };
- 0801C6A10CF8FA8700820AC8 /* concepts.qbk */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; path = concepts.qbk; sourceTree = "<group>"; };
- 0801C6A50CF8FAE500820AC8 /* binary_operable.qbk */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; path = binary_operable.qbk; sourceTree = "<group>"; };
- 0801C6AA0CF8FB7700820AC8 /* unary_operable.qbk */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; path = unary_operable.qbk; sourceTree = "<group>"; };
                 080612F30CF20A4A00F9DDF9 /* complemented_port.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = complemented_port.hpp; sourceTree = "<group>"; };
                 08061C2D0CBEE985002DC710 /* binary_operation.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = binary_operation.hpp; sourceTree = "<group>"; };
                 08061C980CBEF0C6002DC710 /* keyed_port.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = keyed_port.hpp; sourceTree = "<group>"; };
@@ -111,6 +106,7 @@
                 08C3EEA20C625AE30074AB9E /* simple_example.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = simple_example.cpp; sourceTree = "<group>"; };
                 08C675970C13A03E00D85379 /* Jamfile.v2 */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; path = Jamfile.v2; sourceTree = "<group>"; };
                 08DC14FC0C951C4800B96B2E /* Cone.cxx */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = Cone.cxx; sourceTree = "<group>"; };
+ 08EBA7590CFF8B6D0080E225 /* example.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = example.cpp; sourceTree = "<group>"; };
                 08EF045E0CEBF1AD002ABBBC /* port_t.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = port_t.hpp; sourceTree = "<group>"; };
                 08EF9B220C5D506A00D4D206 /* applicator.hpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.h; path = applicator.hpp; sourceTree = "<group>"; };
                 08EF9B230C5D506A00D4D206 /* chain.hpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.h; path = chain.hpp; sourceTree = "<group>"; };
@@ -151,8 +147,10 @@
                 08F077830C63F736003D448D /* components.qbk */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = components.qbk; sourceTree = "<group>"; };
                 08F082570C1DD53400687E1B /* components.qbk */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = components.qbk; sourceTree = "<group>"; };
                 08F0825A0C1DD58500687E1B /* connections.qbk */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = connections.qbk; sourceTree = "<group>"; };
+ 08F09E820D00ACCD00DE0BFC /* fusion_component.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = fusion_component.hpp; sourceTree = "<group>"; };
+ 08F09F2E0D00B5C300DE0BFC /* my_producer_consumer_operations.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = my_producer_consumer_operations.hpp; sourceTree = "<group>"; };
+ 08F179B80D00832F005FDC23 /* make_specializable_operation.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = make_specializable_operation.hpp; sourceTree = "<group>"; };
                 08F1CD280CC55A5100EB5B4A /* port_traits_sequence.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = port_traits_sequence.hpp; sourceTree = "<group>"; };
- 08F20FB60C95AD97005D01D4 /* filter.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = filter.hpp; sourceTree = "<group>"; };
                 08F216430CC95C3800DD25D3 /* test_result_of_defined.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = test_result_of_defined.cpp; sourceTree = "<group>"; };
                 08F217BB0CC570CD00F9A91B /* proxy_port_traits_sequence.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = proxy_port_traits_sequence.hpp; sourceTree = "<group>"; };
                 08F21F770CC6A2EB00DE649A /* test_unary_op.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = test_unary_op.cpp; sourceTree = "<group>"; };
@@ -186,7 +184,6 @@
                 08F36DFB0C41375B00E2F9A1 /* dataflow_table.xml */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xml; path = dataflow_table.xml; sourceTree = "<group>"; };
                 08F37EDF0C57A4A700AC7FB8 /* static_function_call.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = static_function_call.hpp; sourceTree = "<group>"; };
                 08F3944C0CCEC35E00ED7978 /* binary_operation.hpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.h; path = binary_operation.hpp; sourceTree = "<group>"; };
- 08F3FE0C0CA0975100F0E144 /* common.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = common.hpp; sourceTree = "<group>"; };
                 08F40B2B0CEFF9BD00D20F30 /* introduction.qbk */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; path = introduction.qbk; sourceTree = "<group>"; };
                 08F417350CFA466000C10A54 /* runtime_support.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = runtime_support.hpp; sourceTree = "<group>"; };
                 08F4173A0CFA468D00C10A54 /* runtime.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = runtime.hpp; sourceTree = "<group>"; };
@@ -196,6 +193,17 @@
                 08F448760CD5368000E128A8 /* simple_example_components.hpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.h; path = simple_example_components.hpp; sourceTree = "<group>"; };
                 08F4FBB80C56AFDF00EB271A /* producer_wrapper.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = producer_wrapper.hpp; sourceTree = "<group>"; };
                 08F4FC170C56C96300EB271A /* producer_container.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = producer_container.hpp; sourceTree = "<group>"; };
+ 08F59F200D01B5E6007CD201 /* category.hpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.h; path = category.hpp; sourceTree = "<group>"; };
+ 08F59F280D01B6D9007CD201 /* traits.hpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.h; path = traits.hpp; sourceTree = "<group>"; };
+ 08F59F460D01B9D4007CD201 /* default_port_provider.hpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.h; path = default_port_provider.hpp; sourceTree = "<group>"; };
+ 08F59F4E0D01BC56007CD201 /* default_port_provider.hpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.h; path = default_port_provider.hpp; sourceTree = "<group>"; };
+ 08F59F520D01BD19007CD201 /* port.hpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.h; path = port.hpp; sourceTree = "<group>"; };
+ 08F59F7A0D01C0D2007CD201 /* binary_operable.qbk */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; path = binary_operable.qbk; sourceTree = "<group>"; };
+ 08F59F7B0D01C0D2007CD201 /* component.qbk */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; path = component.qbk; sourceTree = "<group>"; };
+ 08F59F7C0D01C0D2007CD201 /* concepts.qbk */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; path = concepts.qbk; sourceTree = "<group>"; };
+ 08F59F7D0D01C0D2007CD201 /* port.qbk */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; path = port.qbk; sourceTree = "<group>"; };
+ 08F59F7E0D01C0D2007CD201 /* unary_operable.qbk */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; path = unary_operable.qbk; sourceTree = "<group>"; };
+ 08F59F820D01C122007CD201 /* support.qbk */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = support.qbk; sourceTree = "<group>"; };
                 08F71D3E0CA3547C0010099E /* Jamfile.v2 */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; path = Jamfile.v2; sourceTree = "<group>"; };
                 08F71D3F0CA3547C0010099E /* test_bind_object.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = test_bind_object.cpp; sourceTree = "<group>"; };
                 08F71D400CA3547C0010099E /* test_branching.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = test_branching.cpp; sourceTree = "<group>"; };
@@ -217,6 +225,7 @@
                 08F71D500CA3547C0010099E /* test_storage.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = test_storage.cpp; sourceTree = "<group>"; };
                 08F9459A0C46A86E00E224E4 /* components.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = components.hpp; sourceTree = "<group>"; };
                 08F9462E0C46C2F000E224E4 /* fibonacci.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = fibonacci.cpp; sourceTree = "<group>"; };
+ 08F972FB0D0471FA00ABF6C1 /* port_adapter.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = port_adapter.hpp; sourceTree = "<group>"; };
                 08F98B400CD0190A009D642B /* Jamfile.v2 */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; path = Jamfile.v2; sourceTree = "<group>"; };
                 08F98B470CD01963009D642B /* intro_example.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = intro_example.cpp; sourceTree = "<group>"; };
                 08F995660CCFC68F001184CE /* condition.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = condition.hpp; sourceTree = "<group>"; };
@@ -254,18 +263,6 @@
                         path = VTK;
                         sourceTree = "<group>";
                 };
- 0801C6970CF8F8E600820AC8 /* concepts */ = {
- isa = PBXGroup;
- children = (
- 0801C6AA0CF8FB7700820AC8 /* unary_operable.qbk */,
- 0801C6A50CF8FAE500820AC8 /* binary_operable.qbk */,
- 0801C6A10CF8FA8700820AC8 /* concepts.qbk */,
- 0801C6980CF8F8E600820AC8 /* component.qbk */,
- 0801C6990CF8F8E600820AC8 /* port.qbk */,
- );
- path = concepts;
- sourceTree = "<group>";
- };
                 080DD7560C13908400EEB53D = {
                         isa = PBXGroup;
                         children = (
@@ -290,6 +287,7 @@
                 08668C4D0C19A16300ACB19A /* example */ = {
                         isa = PBXGroup;
                         children = (
+ 08EBA7590CFF8B6D0080E225 /* example.cpp */,
                                 08FFDD6E0CEB709A009318A8 /* blueprint */,
                                 08F98B3F0CD018E7009D642B /* signals */,
                                 0800AC2F0C8CA99700994538 /* VTK */,
@@ -305,16 +303,17 @@
                 08C675960C13A03E00D85379 /* test */ = {
                         isa = PBXGroup;
                         children = (
+ 08C675970C13A03E00D85379 /* Jamfile.v2 */,
                                 084467150CE790B300B3CFDF /* test_reflective_component.cpp */,
                                 08B9D4190CC3D0790050F10B /* test_binary_op.cpp */,
                                 08F71D3D0CA3547C0010099E /* signals */,
- 08C675970C13A03E00D85379 /* Jamfile.v2 */,
                                 08F26C8B0CBF1CBA00EDC3F6 /* test_port.cpp */,
                                 08F26D630CBF2D4100EDC3F6 /* test_proxy_port.cpp */,
                                 08B9D41E0CC3D0A80050F10B /* my_producer_consumer.hpp */,
                                 08F24D6E0CC4419F00FC4A0C /* test_keyed_port.cpp */,
                                 08F21F770CC6A2EB00DE649A /* test_unary_op.cpp */,
                                 08F21FC20CC6B3E600DE649A /* test_component.cpp */,
+ 08F09F2E0D00B5C300DE0BFC /* my_producer_consumer_operations.hpp */,
                         );
                         name = test;
                         path = ../../test;
@@ -338,12 +337,12 @@
                 08EF9B210C5D506A00D4D206 /* component */ = {
                         isa = PBXGroup;
                         children = (
+ 08EF9B270C5D506A00D4D206 /* detail */,
                                 08EF9B220C5D506A00D4D206 /* applicator.hpp */,
                                 08EF9B230C5D506A00D4D206 /* chain.hpp */,
                                 08EF9B240C5D506A00D4D206 /* conditional.hpp */,
                                 08EF9B250C5D506A00D4D206 /* conditional_modifier.hpp */,
                                 08EF9B260C5D506A00D4D206 /* counter.hpp */,
- 08EF9B270C5D506A00D4D206 /* detail */,
                                 08EF9B2C0C5D506A00D4D206 /* filter.hpp */,
                                 08EF9B2D0C5D506A00D4D206 /* filter_base.hpp */,
                                 08EF9B2E0C5D506A00D4D206 /* function.hpp */,
@@ -413,12 +412,11 @@
                 08F01F950C470E1500C0ED27 /* support */ = {
                         isa = PBXGroup;
                         children = (
- 08FCB38D0CC5DCD2003906C1 /* unary_operation.hpp */,
+ 08F59F460D01B9D4007CD201 /* default_port_provider.hpp */,
+ 08F418080CBD69FE007E7F7A /* port.hpp */,
                                 08F1CD260CC55A2A00EB5B4A /* port */,
+ 08FCB38D0CC5DCD2003906C1 /* unary_operation.hpp */,
                                 082761BE0C6037A90030E557 /* invocable.hpp */,
- 08F20FB60C95AD97005D01D4 /* filter.hpp */,
- 08F3FE0C0CA0975100F0E144 /* common.hpp */,
- 08F418080CBD69FE007E7F7A /* port.hpp */,
                                 08F418AB0CBD7668007E7F7A /* proxy_port.hpp */,
                                 08061C2D0CBEE985002DC710 /* binary_operation.hpp */,
                                 08061C980CBEF0C6002DC710 /* keyed_port.hpp */,
@@ -428,6 +426,8 @@
                                 080612F30CF20A4A00F9DDF9 /* complemented_port.hpp */,
                                 08F4173A0CFA468D00C10A54 /* runtime.hpp */,
                                 08F417460CFA486200C10A54 /* tags.hpp */,
+ 08F09E820D00ACCD00DE0BFC /* fusion_component.hpp */,
+ 08F179B70D008313005FDC23 /* detail */,
                         );
                         path = support;
                         sourceTree = "<group>";
@@ -461,10 +461,23 @@
                         path = templates;
                         sourceTree = "<group>";
                 };
+ 08F179B70D008313005FDC23 /* detail */ = {
+ isa = PBXGroup;
+ children = (
+ 08F179B80D00832F005FDC23 /* make_specializable_operation.hpp */,
+ );
+ path = detail;
+ sourceTree = "<group>";
+ };
                 08F1CD260CC55A2A00EB5B4A /* port */ = {
                         isa = PBXGroup;
                         children = (
+ 08F59F520D01BD19007CD201 /* port.hpp */,
+ 08F59F4E0D01BC56007CD201 /* default_port_provider.hpp */,
+ 08F59F280D01B6D9007CD201 /* traits.hpp */,
+ 08F59F200D01B5E6007CD201 /* category.hpp */,
                                 08F1CD270CC55A2A00EB5B4A /* detail */,
+ 08F972FB0D0471FA00ABF6C1 /* port_adapter.hpp */,
                         );
                         path = port;
                         sourceTree = "<group>";
@@ -545,19 +558,40 @@
                         path = detail;
                         sourceTree = "<group>";
                 };
+ 08F59F780D01C019007CD201 /* support */ = {
+ isa = PBXGroup;
+ children = (
+ 08F59F790D01C0D2007CD201 /* concepts */,
+ 08F59F820D01C122007CD201 /* support.qbk */,
+ );
+ path = support;
+ sourceTree = "<group>";
+ };
+ 08F59F790D01C0D2007CD201 /* concepts */ = {
+ isa = PBXGroup;
+ children = (
+ 08F59F7A0D01C0D2007CD201 /* binary_operable.qbk */,
+ 08F59F7B0D01C0D2007CD201 /* component.qbk */,
+ 08F59F7C0D01C0D2007CD201 /* concepts.qbk */,
+ 08F59F7D0D01C0D2007CD201 /* port.qbk */,
+ 08F59F7E0D01C0D2007CD201 /* unary_operable.qbk */,
+ );
+ path = concepts;
+ sourceTree = "<group>";
+ };
                 08F71D3D0CA3547C0010099E /* signals */ = {
                         isa = PBXGroup;
                         children = (
- 08F216430CC95C3800DD25D3 /* test_result_of_defined.cpp */,
                                 08F71D3E0CA3547C0010099E /* Jamfile.v2 */,
+ 08F216430CC95C3800DD25D3 /* test_result_of_defined.cpp */,
                                 08F71D3F0CA3547C0010099E /* test_bind_object.cpp */,
+ 08F71D420CA3547C0010099E /* test_connect.cpp */,
+ 08F71D460CA3547C0010099E /* test_filter.cpp */,
+ 08F71D440CA3547C0010099E /* test_counter.cpp */,
                                 08F71D400CA3547C0010099E /* test_branching.cpp */,
                                 08F71D410CA3547C0010099E /* test_chain.cpp */,
- 08F71D420CA3547C0010099E /* test_connect.cpp */,
                                 08F71D430CA3547C0010099E /* test_connections.cpp */,
- 08F71D440CA3547C0010099E /* test_counter.cpp */,
                                 08F71D450CA3547C0010099E /* test_disconnect.cpp */,
- 08F71D460CA3547C0010099E /* test_filter.cpp */,
                                 08F71D470CA3547C0010099E /* test_function.cpp */,
                                 08F71D480CA3547C0010099E /* test_junction.cpp */,
                                 08F71D490CA3547C0010099E /* test_multi_args.cpp */,
@@ -646,12 +680,12 @@
                 08FD5DE40C1BA60700F00877 /* doc */ = {
                         isa = PBXGroup;
                         children = (
- 0801C6970CF8F8E600820AC8 /* concepts */,
+ 08FD5E4D0C1BA60800F00877 /* Jamfile.v2 */,
+ 08F59F780D01C019007CD201 /* support */,
                                 08F3592C0CED1E9F00E2BBFB /* blueprint */,
                                 08F264770CEA9DE800DA01C9 /* introduction */,
                                 083FD3C00C62A75100EF3F6B /* phoenix */,
                                 08FB7BEE0C6157AE00BD4EC2 /* signals */,
- 08FD5E4D0C1BA60800F00877 /* Jamfile.v2 */,
                                 08FD5E4E0C1BA60800F00877 /* dataflow.qbk */,
                                 08F36DFB0C41375B00E2F9A1 /* dataflow_table.xml */,
                                 08FA6A050C41E11800434913 /* rationale.qbk */,

Modified: sandbox/SOC/2007/signals/libs/dataflow/doc/Jamfile.v2
==============================================================================
--- sandbox/SOC/2007/signals/libs/dataflow/doc/Jamfile.v2 (original)
+++ sandbox/SOC/2007/signals/libs/dataflow/doc/Jamfile.v2 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -16,7 +16,7 @@
 
 doxygen dataflow_blueprint_doxygen
    :
- [ glob ../../../boost/dataflow/blueprint/*.hpp ]
+ [ glob ../../../boost/dataflow/blueprint/port.hpp ]
    :
         <doxygen:param>TAB_SIZE=4
         <doxygen:param>EXAMPLE_PATH=../test
@@ -31,38 +31,43 @@
         <doxygen:param>MACRO_EXPANSION=YES
         <doxygen:param>SEARCH_INCLUDES=YES
         <doxygen:param>INCLUDE_PATH=../../..
- <doxygen:param>PREDEFINED=DOXYGEN_DOCS_ONLY
+ <doxygen:param>INCLUDE_PATH=$(BOOST_ROOT)
+ <doxygen:param>PREDEFINED=DOXYGEN_DOCS_BUILD
+ ;
+
+doxygen dataflow_support_doxygen
+ :
+ [ glob ../../../boost/dataflow/support/port/category.hpp ]
+ [ glob ../../../boost/dataflow/support/port/traits.hpp ]
+ [ glob ../../../boost/dataflow/support/port/port.hpp ]
+ [ glob ../../../boost/dataflow/support/complemented_port.hpp ]
+ [ glob ../../../boost/dataflow/support/default_port_provider.hpp ]
+ [ glob ../../../boost/dataflow/support/tags.hpp ]
+ [ glob ../../../boost/dataflow/support/component.hpp ]
+ [ glob ../../../boost/dataflow/support/fusion_component.hpp ]
+ :
+ <doxygen:param>TAB_SIZE=4
+ <doxygen:param>EXAMPLE_PATH=../test
+ <doxygen:param>EXAMPLE_PATH=../example
+ <doxygen:param>STRIP_FROM_PATH=$(root)
+ <doxygen:param>STRIP_FROM_INC_PATH=$(root)
+ <doxygen:param>EXTRACT_ALL=NO
+ <doxygen:param>HIDE_UNDOC_MEMBERS=NO
+ <doxygen:param>INHERIT_DOCS=YES
+ <doxygen:param>EXTRACT_PRIVATE=NO
+ <doxygen:param>ENABLE_PREPROCESSING=YES
+ <doxygen:param>MACRO_EXPANSION=YES
+ <doxygen:param>SEARCH_INCLUDES=YES
+ <doxygen:param>INCLUDE_PATH=../../..
+# <doxygen:param>INCLUDE_PATH=$(BOOST_ROOT)
+ <doxygen:param>PREDEFINED=DOXYGEN_DOCS_BUILD
    ;
-
-#doxygen dataflow_doxygen
-# :
-# [ glob ../../../boost/dataflow/support.hpp ]
-# [ glob ../../../boost/dataflow/support/*.hpp ]
-# [ glob ../../../boost/dataflow/signals/*.hpp ]
-# [ glob ../../../boost/dataflow/signals/connection/*.hpp ]
-# [ glob ../../../boost/dataflow/signals/component/*.hpp ]
-# :
-# <doxygen:param>TAB_SIZE=4
-# <doxygen:param>EXAMPLE_PATH=../test
-# <doxygen:param>EXAMPLE_PATH=../example
-# <doxygen:param>STRIP_FROM_PATH=$(root)
-# <doxygen:param>STRIP_FROM_INC_PATH=$(root)
-# <doxygen:param>EXTRACT_ALL=NO
-# <doxygen:param>HIDE_UNDOC_MEMBERS=YES
-# <doxygen:param>INHERIT_DOCS=YES
-# <doxygen:param>EXTRACT_PRIVATE=NO
-# <doxygen:param>ENABLE_PREPROCESSING=YES
-# <doxygen:param>MACRO_EXPANSION=YES
-# <doxygen:param>SEARCH_INCLUDES=YES
-# <doxygen:param>INCLUDE_PATH=../../..
-# <doxygen:param>PREDEFINED=DOXYGEN_DOCS_ONLY
-# ;
 
 boostbook standalone
    :
       dataflow_xml
       dataflow_blueprint_doxygen
-# dataflow_doxygen
+ dataflow_support_doxygen
     :
         # pull in the online .css and images
         <xsl:param>project.root=http://beta.boost.org/development

Modified: sandbox/SOC/2007/signals/libs/dataflow/doc/components.qbk
==============================================================================
--- sandbox/SOC/2007/signals/libs/dataflow/doc/components.qbk (original)
+++ sandbox/SOC/2007/signals/libs/dataflow/doc/components.qbk 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -3,7 +3,7 @@
 [section producer_group]
 
 [heading Model of]
-* [ProducerPortConcept]
+* [ProducerPort]
 
 [heading Description]
 
@@ -24,7 +24,7 @@
 [section consumer_group]
 
 [heading Model of]
-* [ProducerPortConcept]
+* [ProducerPort]
 
 [heading Description]
 
@@ -45,8 +45,8 @@
 [section consumer_map]
 
 A [consumer_map] groups together multiple consumers, keyed by type they consume.
-When a [ProducerPortConcept] is connected to a [consumer_map], the consumer
-whose key matches the [ProducerPortConcept]'s produced type will be chosen for
+When a [ProducerPort] is connected to a [consumer_map], the consumer
+whose key matches the [ProducerPort]'s produced type will be chosen for
 the connection.
 [consumer_map] is a wrapper for [BoostFusion] maps which allows them to be
 used in this fashion.
@@ -55,7 +55,7 @@
 A [consumer_map] is used as the return type of [^[storage].send_slot()],
 which and includes the [slot_selector] for both the fused and unfused
 versions of the `send()` function. The appropriate slot is selected when
-a connection is made, based on the [ProducerPortConcept]'s outgoing signal
+a connection is made, based on the [ProducerPort]'s outgoing signal
 signature.
 
 [endsect][/consumer_map]

Modified: sandbox/SOC/2007/signals/libs/dataflow/doc/dataflow.qbk
==============================================================================
--- sandbox/SOC/2007/signals/libs/dataflow/doc/dataflow.qbk (original)
+++ sandbox/SOC/2007/signals/libs/dataflow/doc/dataflow.qbk 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -1,6 +1,6 @@
 [article Dataflow
     [quickbook 1.4]
- [version 0.8.1]
+ [version 0.8.2]
     [authors [Rajko, Stjepan]]
     [copyright 2007 Stjepan Rajko]
     [purpose Generic dataflow lirary providing support for data producers,
@@ -12,41 +12,42 @@
     ]
 ]
 
-[template concepts[] [link dataflow.concepts concepts]]
-[template MechanismConcept[] [link dataflow.concepts.port_related.mechanism [^Mechanism]]]
-[template PortCategoryConcept[] [link dataflow.concepts.port_related.portcategory [^PortCategory]]]
-[template PortTraitsConcept[] [link dataflow.concepts.port_related.port [^PortTraits]]]
-[template PortConcept[] [link dataflow.concepts.port_related.port [^Port]]]
-[template ProducerPortConcept[] [link dataflow.concepts.port_related.port [^ProducerPort]]]
-[template ConsumerPortConcept[] [link dataflow.concepts.port_related.port [^ConsumerPort]]]
-[template ComplementedPortConcept[] [link dataflow.concepts.port_related.complementedport [^ComplementedPort]]]
-[template ComplementedPortTraitsConcept[] [link dataflow.concepts.port_related.complementedport [^ComplementedPortTraits]]]
-[template KeyedPortConcept[] [link dataflow.concepts.port_related.keyedport [^KeyedPort]]]
-
-[template ProxyPortTraitsConcept[] [link dataflow.concepts.port_related.proxyporttraits [^ProxyPortTraits]]]
-[template ProxyPortConcept[] [link dataflow.concepts.port_related.proxyport [^ProxyPort]]]
-
-[template BinaryOperableConcept[] [link dataflow.concepts.port_related.binaryoperable [^BinaryOperable]]]
-[template ConnectableConcept[] [link dataflow.concepts.port_related.binaryoperable [^Connectable]]]
-[template OnlyConnectableConcept[] [link dataflow.concepts.port_related.binaryoperable [^OnlyConnectable]]]
-[template DisconnectableConcept[] [link dataflow.concepts.port_related.binaryoperable [^Disconnectable]]]
-[template ExtractableConcept[] [link dataflow.concepts.port_related.binaryoperable [^Extractable]]]
-
-[template UnaryOperableConcept[] [link dataflow.concepts.port_related.unaryoperable [^UnaryOperable]]]
-[template AllDisconnectableConcept[] [link dataflow.concepts.port_related.unaryoperable [^AllDisconnectable]]]
-
-[template ComponentTraitsConcept[] [link dataflow.concepts.component_related.componenttraits [^ComponentTraits]]]
-[template ComponentConcept[] [link dataflow.concepts.component_related.component [^Component]]]
-
-[template ComponentOperableConcept[] [link dataflow.concepts.component_related.componentoperable [^ComponentOperable]]]
-[template InvocableConcept[] [link dataflow.concepts.component_related.componentoperable [^Invocable]]]
-
-[template SignalPortTraitsConcept[] [link dataflow.signals.concepts.signalporttraits [^SignalPortTraits]]]
-[template SignalProducerConcept[] [link dataflow.signals.concepts.signalproducer [^SignalProducer]]]
-[template SignalConsumerConcept[] [link dataflow.signals.concepts.signalconsumer [^SignalConsumer]]]
+[template concepts[] [link dataflow.support.concepts concepts]]
+[template Tag[] [link dataflow.support.concepts.port_related.tag [^Tag]]]
+[template Mechanism[] [link dataflow.support.concepts.port_related.mechanism [^Mechanism]]]
+[template PortCategory[] [link dataflow.support.concepts.port_related.portcategory [^PortCategory]]]
+[template PortTraits[] [link dataflow.support.concepts.port_related.port [^PortTraits]]]
+[template Port[] [link dataflow.support.concepts.port_related.port [^Port]]]
+[template ProducerPort[] [link dataflow.support.concepts.port_related.port [^ProducerPort]]]
+[template ConsumerPort[] [link dataflow.support.concepts.port_related.port [^ConsumerPort]]]
+[template ComplementedPort[] [link dataflow.support.concepts.port_related.complementedport [^ComplementedPort]]]
+[template ComplementedPortTraits[] [link dataflow.support.concepts.port_related.complementedport [^ComplementedPortTraits]]]
+[template KeyedPort[] [link dataflow.support.concepts.port_related.keyedport [^KeyedPort]]]
+
+[template ProxyPortTraits[] [link dataflow.support.concepts.port_related.proxyporttraits [^ProxyPortTraits]]]
+[template ProxyPort[] [link dataflow.support.concepts.port_related.proxyport [^ProxyPort]]]
+
+[template BinaryOperable[] [link dataflow.support.concepts.port_related.binaryoperable [^BinaryOperable]]]
+[template Connectable[] [link dataflow.support.concepts.port_related.binaryoperable [^Connectable]]]
+[template OnlyConnectable[] [link dataflow.support.concepts.port_related.binaryoperable [^OnlyConnectable]]]
+[template Disconnectable[] [link dataflow.support.concepts.port_related.binaryoperable [^Disconnectable]]]
+[template Extractable[] [link dataflow.support.concepts.port_related.binaryoperable [^Extractable]]]
+
+[template UnaryOperable[] [link dataflow.support.concepts.port_related.unaryoperable [^UnaryOperable]]]
+[template AllDisconnectable[] [link dataflow.support.concepts.port_related.unaryoperable [^AllDisconnectable]]]
+
+[template ComponentTraits[] [link dataflow.support.concepts.component_related.componenttraits [^ComponentTraits]]]
+[template Component[] [link dataflow.support.concepts.component_related.component [^Component]]]
+
+[template ComponentOperable[] [link dataflow.support.concepts.component_related.componentoperable [^ComponentOperable]]]
+[template Invocable[] [link dataflow.support.concepts.component_related.componentoperable [^Invocable]]]
+
+[template SignalPortTraits[] [link dataflow.signals.concepts.signalporttraits [^SignalPortTraits]]]
+[template SignalProducer[] [link dataflow.signals.concepts.signalproducer [^SignalProducer]]]
+[template SignalConsumer[] [link dataflow.signals.concepts.signalconsumer [^SignalConsumer]]]
 
-[template PhoenixProducerConcept[] [link dataflow.concepts.phoenix.phoenixproducer [^PhoenixProducer]]]
-[template PhoenixConsumerConcept[] [link dataflow.concepts.phoenix.phoenixproducer [^PhoenixConsumer]]]
+[template PhoenixProducer[] [link dataflow.support.concepts.phoenix.phoenixproducer [^PhoenixProducer]]]
+[template PhoenixConsumer[] [link dataflow.support.concepts.phoenix.phoenixproducer [^PhoenixConsumer]]]
 
 [template vtk_example[text] [link dataflow.introduction.examples.new_layer [text]]]
 [template how_to_use[text] [link dataflow.introduction.how_to_use [text]]]
@@ -106,6 +107,18 @@
 
 [template blueprint[] [link dataflow.future.blueprint blueprint]]
 
+[template is_port_category[] [classref boost::dataflow::is_port_category is_port_category]]
+[template port_traits[] [classref boost::dataflow::port_traits [^port_traits]]]
+[template port_traits_of[] [classref boost::dataflow::port_traits_of port_traits_of]]
+[template register_port_traits[] [classref boost::dataflow::register_port_traits register_port_traits]]
+[template is_port[] [classref boost::dataflow::is_port [^is_port]]]
+[template port[] [classref boost::dataflow::port [^port]]]
+[template complemented_port_traits[] [classref boost::dataflow::complemented_port_traits [^complemented_port_traits]]]
+[template is_complemented_port[] [classref boost::dataflow::is_complemented_port [^is_complemented_port]]]
+
+[template DATAFLOW_PORT_TRAITS[] [macroref DATAFLOW_PORT_TRAITS DATAFLOW_PORT_TRAITS]]
+[template DATAFLOW_PORT_TRAITS_ENABLE_IF[] [macroref DATAFLOW_PORT_TRAITS_ENABLE_IF DATAFLOW_PORT_TRAITS_ENABLE_IF]]
+[template default_tag[] [classref boost::dataflow::default_tag [^concepts::default_tag]]]
 
 [import ../test/test_port.cpp]
 
@@ -142,7 +155,7 @@
 
 [include introduction/introduction.qbk]
 
-[include concepts/concepts.qbk]
+[include support/support.qbk]
 
 [/[include components.qbk]]
 

Modified: sandbox/SOC/2007/signals/libs/dataflow/doc/future.qbk
==============================================================================
--- sandbox/SOC/2007/signals/libs/dataflow/doc/future.qbk (original)
+++ sandbox/SOC/2007/signals/libs/dataflow/doc/future.qbk 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -4,7 +4,7 @@
 
 The [DataflowBlueprint] layer now offers some limited dataflow network modeling
 via a BGL graph, and some basic runtime reflections for classes that model
-the [ComponentConcept] concept.
+the [Component] concept.
 
 The following features are planned for the future:
 
@@ -100,7 +100,7 @@
 Here, a connection from a data-producing component to a data-consuming
 component would lead to them both being connected to the same data-transport
 object, which would be managed by the library. The components
-could be invoked through the [InvocableConcept] by the library when needed.
+could be invoked through the [Invocable] by the library when needed.
 
 There are, of course, a lot of other issues to solve, and a lot of ways in
 which the Dataflow generic support layer might need to grow to accomodate

Modified: sandbox/SOC/2007/signals/libs/dataflow/doc/introduction/distributed_example.qbk
==============================================================================
--- sandbox/SOC/2007/signals/libs/dataflow/doc/introduction/distributed_example.qbk (original)
+++ sandbox/SOC/2007/signals/libs/dataflow/doc/introduction/distributed_example.qbk 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -9,18 +9,18 @@
 which can be used to create a producer-consumer connection between two
 computers: [socket_sender] and [socket_receiver]. As long as we have
 a network socket set up between two computers, we can do the following to
-set up a connection between a [SignalProducerConcept] on one computer with a
-[SignalConsumerConcept] on another:
+set up a connection between a [SignalProducer] on one computer with a
+[SignalConsumer] on another:
 
-* On the [SignalProducerConcept]'s computer, construct a [socket_sender] of
+* On the [SignalProducer]'s computer, construct a [socket_sender] of
 the appropriate `Signature` with the given socket.
-[connect] the [SignalProducerConcept] to the [socket_sender].
-* On the [SignalConsumerConcept]'s computer, construct a [socket_receiver] of
+[connect] the [SignalProducer] to the [socket_sender].
+* On the [SignalConsumer]'s computer, construct a [socket_receiver] of
 the appropriate `Signature` with the given socket.
-[connect] the [socket_receiver] to the [SignalConsumerConcept].
+[connect] the [socket_receiver] to the [SignalConsumer].
 
-That's it. Now, every signal sent out of the [SignalProducerConcept] should
-be received by the [SignalConsumerConcept].
+That's it. Now, every signal sent out of the [SignalProducer] should
+be received by the [SignalConsumer].
 
 The following is a modification of the example from the
 [link dataflow.introduction.dataflow motivation section] to a dataflow

Modified: sandbox/SOC/2007/signals/libs/dataflow/doc/introduction/gil_example.qbk
==============================================================================
--- sandbox/SOC/2007/signals/libs/dataflow/doc/introduction/gil_example.qbk (original)
+++ sandbox/SOC/2007/signals/libs/dataflow/doc/introduction/gil_example.qbk 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -1,4 +1,4 @@
-[section:gil An image processing network using Dataflow.Signals and [BoostGIL]]
+[section:gil An image processing network using Dataflow.Signals and Boost.GIL]
 
 The [link dataflow.introduction.motivation motivation] section introduced a
 hypothetical video processing example. Here, we will present an actual

Modified: sandbox/SOC/2007/signals/libs/dataflow/doc/introduction/introduction.qbk
==============================================================================
--- sandbox/SOC/2007/signals/libs/dataflow/doc/introduction/introduction.qbk (original)
+++ sandbox/SOC/2007/signals/libs/dataflow/doc/introduction/introduction.qbk 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -377,17 +377,22 @@
 The Dataflow library uses the trunk version of Boost - it might not work
 perfectly with release versions of boost.
 
+Version 0.8.2 (under construction)
+* Moved functionality from port related concepts to the component concepts.
+* Adapted the Dataflow.Signals layer and tests, most of the rest still broken.
+* Started adding Doxygen-generated support layer reference.
+
 Version 0.8.1
  \[[@http://www.boost-consulting.com/vault/index.php?direction=&order=&directory=Dataflow& available in the Boost vault]\]
 
 * Started the [DataflowBlueprint] layer (runtime reflection and network modeling).
-* Expanding the [ComponentConcept] concept (compile-time reflection of ports).
+* Expanding the [Component] concept (compile-time reflection of ports).
 * VTK example Jamfile now works work with Windows (not just Darwin+X11 VTK).
 * Provided an example using [BoostGIL].
-* The [MechanismConcept] concept is now limited to port-related operations.
+* The [Mechanism] concept is now limited to port-related operations.
   In the future, an additional tag template parameter might be added to all
   dataflow templates to allow specifying completely independent dataflow support
- layers over the same types (the original intent of the [MechanismConcept]
+ layers over the same types (the original intent of the [Mechanism]
   parameter).
 
 Version 0.8.0 -
@@ -424,7 +429,7 @@
 running bjam.
 
 [warning The Jamfile for the VTK examples currently only works for Darwin
-and for VTK built for X]
+with VTK built for X11, and for MSVC]
 
 The library itself is header only, and requires no linking. However, parts
 of it depend on boost libraries which do need to be built and linked (see

Modified: sandbox/SOC/2007/signals/libs/dataflow/doc/introduction/vtk_example.qbk
==============================================================================
--- sandbox/SOC/2007/signals/libs/dataflow/doc/introduction/vtk_example.qbk (original)
+++ sandbox/SOC/2007/signals/libs/dataflow/doc/introduction/vtk_example.qbk 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -60,9 +60,9 @@
 
 [section:mechanism Setting up the Mechanism]
 
-The first thing we'll do is create a tag for the VTK [MechanismConcept], in
+The first thing we'll do is create a tag for the VTK [Mechanism], in
 namespace `boost::dataflow::vtk`. Since there are currently no requirements
-for a [MechanismConcept], this is as simple as declaring a new type to be used
+for a [Mechanism], this is as simple as declaring a new type to be used
 as the mechanism tag:
 
 [vtk_mechanism]
@@ -82,17 +82,17 @@
 are accessible via `GetOuptutPort` member functions, which return a proxy
 object ([vtkAlgorithmOutput] `*`) for an actual output port.
 
-In Dataflow concepts, [vtkAlgorithmOutput] can be made a [ProducerPortConcept]
+In Dataflow concepts, [vtkAlgorithmOutput] can be made a [ProducerPort]
 - it corresponds to a single data output point. We support it as such by
-defining a [PortTraitsConcept] type, and associating it with
+defining a [PortTraits] type, and associating it with
 [vtkAlgorithmOutput]:
 
 [vtk_algorithm_output_producer]
 
-[note More details about registering [PortTraitsConcept] for a [PortConcept]
-can be found on the [PortConcept] documentation page.]
+[note More details about registering [PortTraits] for a [Port]
+can be found on the [Port] documentation page.]
 
-Now that we have a [ProducerPortConcept], we need a [ConsumerPortConcept].
+Now that we have a [ProducerPort], we need a [ConsumerPort].
 [vtkAlgorithm] can accept incoming connections using the `AddInputConnection`
 and `SetInputConnection` member functions. The code below provides support
 for [vtkAlgorithm] accepting connections on its default input port:
@@ -108,10 +108,10 @@
 
 [section:connectable Making things Connectable]
 
-With the pair of [ProducerPortConcept] and [ConsumerPortConcept] registered, we
-can make them [ConnectableConcept] and/or [OnlyConnectableConcept].
+With the pair of [ProducerPort] and [ConsumerPort] registered, we
+can make them [Connectable] and/or [OnlyConnectable].
 All we need to do is specialize the implementation for the appropriate
-[PortTraitsConcept]:
+[PortTraits]:
 
 [vtk_connect_impl_algorithm]
 
@@ -152,12 +152,12 @@
 for this purpose.
 
 Including `<boost/dataflow/templates/binary_operation.hpp>` with `#define`d
-DATAFLOW_TEMPLATE_MECHANISM and DATAFLOW_TEMPLATE_BINARY_OPERATION will
+DATAFLOW_TEMPLATE_TAG and DATAFLOW_TEMPLATE_BINARY_OPERATION will
 define a forwarding function DATAFLOW_TEMPLATE_BINARY_OPERATION in the
 current namespace.
 
 Including `<boost/dataflow/templates/operator.hpp>` with `#define`d
-DATAFLOW_TEMPLATE_MECHANISM, DATAFLOW_TEMPLATE_BINARY_OPERATION, and
+DATAFLOW_TEMPLATE_TAG, DATAFLOW_TEMPLATE_BINARY_OPERATION, and
 DATAFLOW_TEMPLATE_OPERATOR will define a forwarding operator in the current
 namespace.
 
@@ -188,23 +188,23 @@
 
 In the VTK example above, both `vtkConeSource` and `vtkPolyDataMapper`
 inherit [vtkAlgorithm].
-With the [vtkAlgorithmOutput] [ProducerPortConcept] and
-[vtkAlgorithm] [ConsumerPortConcept] we've set up,
+With the [vtkAlgorithmOutput] [ProducerPort] and
+[vtkAlgorithm] [ConsumerPort] we've set up,
 we can do things like `connect(cone->GetOutputPort(), *coneMapper);`.
 However, we would like to do `connect(*cone, *coneMapper)`.
 
 To do that,
-we need to make [vtkAlgorithm] a [ProducerPortConcept]. Since [vtkAlgorithm]
+we need to make [vtkAlgorithm] a [ProducerPort]. Since [vtkAlgorithm]
 forms its output connections using [vtkAlgorithmOutput] objects
 returned through the `GetOutputPort` member functions, and we've already
-configured [vtkAlgorithmOutput] as a [ProducerPortConcept], we can make use
-of the [ProxyPortConcept] concept provided by the dataflow library.
-In effect, we will make [vtkAlgorithm] delegate it's [ProducerPortConcept]
+configured [vtkAlgorithmOutput] as a [ProducerPort], we can make use
+of the [ProxyPort] concept provided by the dataflow library.
+In effect, we will make [vtkAlgorithm] delegate it's [ProducerPort]
 functionality to [vtkAlgorithmOutput]:
 
 [vtk_algorithm_proxy_producer]
 
-Now, [vtkAlgorithm] is a [ProducerPortConcept].
+Now, [vtkAlgorithm] is a [ProducerPort].
 
 [heading What we can do with what we have so far]
 
@@ -222,7 +222,7 @@
 
 In a VTK pipeline, a [vtkActor] consumes data from a [vtkMapper], and produces
 data for a [vtkRenderer]. In this case, we can provide Dataflow support
-for a [vtkActor] as both a [ProducerPortConcept] and a [ConsumerPortConcept]:
+for a [vtkActor] as both a [ProducerPort] and a [ConsumerPort]:
 
 [vtk_actor_filter]
 
@@ -241,9 +241,9 @@
 the same as connecting a [vtkMapper] to another [vtkAlgorithm].
 
 To accomodate such situations, the Dataflow library provides
-[KeyedPortConcept]s, which are similar to [ProxyPortConcept]s but
-the [PortConcept] they delegate to is keyed on the
-[PortConcept] they are being connected to.
+[KeyedPort]s, which are similar to [ProxyPort]s but
+the [Port] they delegate to is keyed on the
+[Port] they are being connected to.
 
 [vtk_mapper_producer]
 
@@ -270,7 +270,7 @@
 use pointers to class types rather than class types themselves. So, with what
 we have done so far, we can do `connect(*cone, *coneMapper)` but not
 `connect(cone, coneMapper)`. To provide support for pointers, we
-simply make them adhere to the [ProxyPortConcept] concept, and delegate the
+simply make them adhere to the [ProxyPort] concept, and delegate the
 functionality to the object they point to.
 
 [vtk_support_pointer]

Modified: sandbox/SOC/2007/signals/libs/dataflow/doc/phoenix/concepts.qbk
==============================================================================
--- sandbox/SOC/2007/signals/libs/dataflow/doc/phoenix/concepts.qbk (original)
+++ sandbox/SOC/2007/signals/libs/dataflow/doc/phoenix/concepts.qbk 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -2,20 +2,20 @@
 
 [section PhoenixProducer]
 
-A [ProducerPortConcept] type `P` is a ['[PhoenixProducerConcept]] if it uses
+A [ProducerPort] type `P` is a ['[PhoenixProducer]] if it uses
 the underlying pointer based data transport mechanism. It is
-[ConnectableConcept] with a compatible [PhoenixConsumerConcept].
+[Connectable] with a compatible [PhoenixConsumer].
 
 [heading Refinement of]
-* [ProducerPortConcept]
-* [InvocableConcept]
+* [ProducerPort]
+* [Invocable]
 
 [heading Notation]
 The following expressions are used in this document:
 
 [variablelist
- [[P] [A [PhoenixProducerConcept] type.]]
- [[C] [A [PhoenixConsumerConcept] type [ConnectableConcept] to `P`.]]
+ [[P] [A [PhoenixProducer] type.]]
+ [[C] [A [PhoenixConsumer] type [Connectable] to `P`.]]
     [[PCategory] [The producer category of `P`.]]
     [[p] [An object of type `P`.]]
     [[c] [An object of type `C`.]]
@@ -60,20 +60,20 @@
 
 [section PhoenixConsumer]
 
-A type `T` is a ['[PhoenixConsumerConcept]] if it uses the underlying pointer-based
-data transport mechanism. I.e., it is [ConnectableConcept] to a
-[PhoenixProducerConcept] of compatible produced type.
+A type `T` is a ['[PhoenixConsumer]] if it uses the underlying pointer-based
+data transport mechanism. I.e., it is [Connectable] to a
+[PhoenixProducer] of compatible produced type.
 
 [heading Refinement of]
-* [ConsumerPortConcept]
-* [ConnectableConcept] with [PhoenixProducerConcept] of compatible produced type.
+* [ConsumerPort]
+* [Connectable] with [PhoenixProducer] of compatible produced type.
 
 [heading Notation]
 The following expressions are used in this document:
 
 [variablelist
- [[C] [A [PhoenixConsumerConcept] type.]]
- [[P] [A [PhoenixProducerConcept] type of compatible produced type.]]
+ [[C] [A [PhoenixConsumer] type.]]
+ [[P] [A [PhoenixProducer] type of compatible produced type.]]
     [[CCategory] [The consumer category of `C`.]]
     [[c] [An object of type `C`.]]
     [[p] [An object of type `P`.]]

Modified: sandbox/SOC/2007/signals/libs/dataflow/doc/rationale.qbk
==============================================================================
--- sandbox/SOC/2007/signals/libs/dataflow/doc/rationale.qbk (original)
+++ sandbox/SOC/2007/signals/libs/dataflow/doc/rationale.qbk 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -28,11 +28,11 @@
   but might be problematic where the result type is not fixed (and in the
   future all of the operations will probably be modified to return a value
   where appropriate.
-* Port operations (as parts of [BinaryOperableConcept] and
- [UnaryOperableConcept] concepts) have been rolled into a single class
+* Port operations (as parts of [BinaryOperable] and
+ [UnaryOperable] concepts) have been rolled into a single class
   template with the operation selected by type because all of these operations
- share [ProxyPortConcept] and (for [BinaryOperableConcept]) [KeyedPortConcept]
- resolution. [ComponentOperableConcept] operations have been implemented
+ share [ProxyPort] and (for [BinaryOperable]) [KeyedPort]
+ resolution. [ComponentOperable] operations have been implemented
   the same way for consistency.
   
 [endsect]

Modified: sandbox/SOC/2007/signals/libs/dataflow/doc/signals/components.qbk
==============================================================================
--- sandbox/SOC/2007/signals/libs/dataflow/doc/signals/components.qbk (original)
+++ sandbox/SOC/2007/signals/libs/dataflow/doc/signals/components.qbk 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -26,8 +26,8 @@
 
 [heading Model of]
 
-* [SignalConsumerConcept]
-* [SignalProducerConcept]
+* [SignalConsumer]
+* [SignalProducer]
 
 [heading Description]
 
@@ -60,9 +60,9 @@
 [*See also]: [classref boost::signals::applicator applicator class reference.]
 
 [heading Model of]
-* [SignalConsumerConcept]
-* [SignalProducerConcept]
-* [ConnectableConcept] to any [SignalProducerConcept] type `P` where
+* [SignalConsumer]
+* [SignalProducer]
+* [Connectable] to any [SignalProducer] type `P` where
   `Signature` matches `P`'s produced type.
   
 [heading Description]
@@ -94,9 +94,9 @@
 [*See also]: [classref boost::signals::instantiator instantiator class reference.]
 
 [heading Model of]
-* [SignalConsumerConcept]
-* [SignalProducerConcept]
-* [ConnectableConcept] to any [SignalProducerConcept] type `P` where
+* [SignalConsumer]
+* [SignalProducer]
+* [Connectable] to any [SignalProducer] type `P` where
   `Signature` matches `P`'s produced type.
   
 [heading Description]
@@ -115,9 +115,9 @@
 [*See also]: [classref boost::signals::modifier modifier class reference.]
 
 [heading Model of]
-* [SignalConsumerConcept]
-* [SignalProducerConcept]
-* [ConnectableConcept] to any [SignalProducerConcept] type `P` where
+* [SignalConsumer]
+* [SignalProducer]
+* [Connectable] to any [SignalProducer] type `P` where
   `Signature` matches `P`'s produced type.
   
 [heading Description]
@@ -139,9 +139,9 @@
 [*See also]: [classref boost::signals::storage storage class reference.]
 
 [heading Model of]
-* [SignalConsumerConcept]
-* [SignalProducerConcept]
-* [ConnectableConcept] to any [SignalProducerConcept] type `P` where
+* [SignalConsumer]
+* [SignalProducer]
+* [Connectable] to any [SignalProducer] type `P` where
   `Signature` matches `P`'s produced type.
   
 [heading Description]
@@ -170,9 +170,9 @@
 [*See also]: [classref boost::signals::junction junction class reference.]
 
 [heading Model of]
-* [SignalConsumerConcept]
-* [SignalProducerConcept]
-* [ConnectableConcept] to any [SignalProducerConcept] type `P` where
+* [SignalConsumer]
+* [SignalProducer]
+* [Connectable] to any [SignalProducer] type `P` where
   `Signature` matches `P`'s produced type.
   
 [heading Description]
@@ -188,9 +188,9 @@
 [*See also]: [classref boost::signals::multiplexer multiplexer class reference.]
 
 [heading Model of]
-* [SignalConsumerConcept]
-* [SignalProducerConcept]
-* [ConnectableConcept] to any [SignalProducerConcept] type `P` where
+* [SignalConsumer]
+* [SignalProducer]
+* [Connectable] to any [SignalProducer] type `P` where
   `Signature` matches `P`'s produced type.
   
 [heading Description]
@@ -210,9 +210,9 @@
 [*See also]: [classref boost::signals::mutex mutex class reference.]
 
 [heading Model of]
-* [SignalConsumerConcept]
-* [SignalProducerConcept]
-* [ConnectableConcept] to any [SignalProducerConcept] type `P` where
+* [SignalConsumer]
+* [SignalProducer]
+* [Connectable] to any [SignalProducer] type `P` where
   `Signature` matches `P`'s produced type.
   
 [heading Description]
@@ -228,9 +228,9 @@
 [*See also]: [classref boost::signals::mutex mutex class reference.]
 
 [heading Model of]
-* [SignalConsumerConcept]
-* [SignalProducerConcept]
-* [ConnectableConcept] to any [SignalProducerConcept] type `P` where
+* [SignalConsumer]
+* [SignalProducer]
+* [Connectable] to any [SignalProducer] type `P` where
   `Signature` matches `P`'s produced type.
   
 [heading Description]
@@ -248,9 +248,9 @@
 [*See also]: [classref boost::signals::function function class reference.]
 
 [heading Model of]
-* [SignalConsumerConcept]
-* [SignalProducerConcept]
-* [ConnectableConcept] to any [SignalProducerConcept] type `P` where
+* [SignalConsumer]
+* [SignalProducer]
+* [Connectable] to any [SignalProducer] type `P` where
   `Signature` matches `P`'s produced type.
   
 [heading Description]
@@ -269,9 +269,9 @@
 [section:chain chain]
 
 [heading Model of]
-* [SignalConsumerConcept]
-* [SignalProducerConcept]
-* [ConnectableConcept] to any [SignalProducerConcept] type `P` where
+* [SignalConsumer]
+* [SignalProducer]
+* [Connectable] to any [SignalProducer] type `P` where
   `Signature` matches `P`'s produced type.
   
 [heading Description]
@@ -297,8 +297,8 @@
 [*See also]: [classref boost::signals::socket_sender socket_sender class reference.]
 
 [heading Model of]
-* [SignalConsumerConcept]
-* [ConnectableConcept] to any [SignalProducerConcept] type `P` where
+* [SignalConsumer]
+* [Connectable] to any [SignalProducer] type `P` where
   `Signature` matches `P`'s produced type.
   
 [heading Description]
@@ -318,7 +318,7 @@
 [*See also]: [classref boost::signals::socket_receiver socket_receiver class reference.]
 
 [heading Model of]
-* [SignalProducerConcept]
+* [SignalProducer]
   
 [heading Description]
 

Modified: sandbox/SOC/2007/signals/libs/dataflow/doc/signals/concepts.qbk
==============================================================================
--- sandbox/SOC/2007/signals/libs/dataflow/doc/signals/concepts.qbk (original)
+++ sandbox/SOC/2007/signals/libs/dataflow/doc/signals/concepts.qbk 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -1,19 +1,19 @@
 [section Concepts]
 
 [section:signalporttraits SignalPortTraits]
-A [PortTraitsConcept] type `T` is a [`[SignalPortTraitsConcept]] if
+A [PortTraits] type `T` is a [`[SignalPortTraits]] if
 its mechanism is `signals::mechanism`, and it specifies the signature
 of the underlying signal.
 
 [heading Refinement of]
-* [PortTraitsConcept]
+* [PortTraits]
 
 [heading Notation]
 The following expressions are used in this document:
 
 [variablelist
- [[PT] [A [SignalPortTraitsConcept] type.]]
- [[C] [A [ConnectableConcept] [SignalConsumerConcept].]]
+ [[PT] [A [SignalPortTraits] type.]]
+ [[C] [A [Connectable] [SignalConsumer].]]
     [[p] [An object of type `p`.]]
     [[c] [An object of type `c`.]]
 ]
@@ -25,7 +25,7 @@
         [Mechanism]
         [`PT::mechanism`]
         [`dataflow::signals::mechanism`]
- [[MechanismConcept] type tag.]
+ [[Mechanism] type tag.]
     ]
     [
         [Signature]
@@ -39,21 +39,21 @@
 
 [section SignalProducer]
 
-A [ProducerPortConcept] type `P` is a ['[SignalProducerConcept]] if its
-[PortTraitsConcept] is a [SignalPortTraitsConcept], and the `get_port` function
+A [ProducerPort] type `P` is a ['[SignalProducer]] if its
+[PortTraits] is a [SignalPortTraits], and the `get_port` function
 returns the underlying `boost::signal`.
 
 [heading Refinement of]
-* [ProducerPortConcept]
-* [ConnectableConcept] with [SignalConsumerConcept] of same signature.
+* [ProducerPort]
+* [Connectable] with [SignalConsumer] of same signature.
 
 [heading Notation]
 The following expressions are used in this document:
 
 [variablelist
- [[`P`] [A [SignalProducerConcept] type.]]
- [[`PT`] [[PortTraitsConcept] of `P`]]
- [[`C`] [A [ConnectableConcept] [SignalConsumerConcept].]]
+ [[`P`] [A [SignalProducer] type.]]
+ [[`PT`] [[PortTraits] of `P`]]
+ [[`C`] [A [Connectable] [SignalConsumer].]]
     [[`S`] [Signature of underlying signal]]
     [[`p`] [An object of type `p`.]]
     [[`c`] [An object of type `c`.]]
@@ -85,21 +85,21 @@
 
 [section SignalConsumer]
 
-A [ConsumerPortConcept] type `P` is a ['[SignalConsumerConcept]] if its
-[PortTraitsConcept] is a [SignalPortTraitsConcept], and the `get_port` function
+A [ConsumerPort] type `P` is a ['[SignalConsumer]] if its
+[PortTraits] is a [SignalPortTraits], and the `get_port` function
 returns the underlying `boost::function`.
 
 [heading Refinement of]
-* [ConsumerPortConcept]
-* [ConnectableConcept] with [SignalProducerConcept] of same signature.
+* [ConsumerPort]
+* [Connectable] with [SignalProducer] of same signature.
 
 [heading Notation]
 The following expressions are used in this document:
 
 [variablelist
- [[`C`] [A [SignalConsumerConcept] type.]]
- [[`PT`] [[PortTraitsConcept] of `C`]]
- [[`P`] [A [ConnectableConcept] [SignalProducerConcept].]]
+ [[`C`] [A [SignalConsumer] type.]]
+ [[`PT`] [[PortTraits] of `C`]]
+ [[`P`] [A [Connectable] [SignalProducer].]]
     [[`S`] [Signature of underlying signal]]
     [[`c`] [An object of type `c`.]]
     [[`p`] [An object of type `p`.]]

Modified: sandbox/SOC/2007/signals/libs/dataflow/doc/signals/connections.qbk
==============================================================================
--- sandbox/SOC/2007/signals/libs/dataflow/doc/signals/connections.qbk (original)
+++ sandbox/SOC/2007/signals/libs/dataflow/doc/signals/connections.qbk 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -5,10 +5,10 @@
 [*See also]: [funcref boost::signals::connect connect function reference.]
 
 [DataflowSignals] provides a [connect] function in the `boost::signals`
-namespace, which connects a [SignalProducerConcept] and [SignalConsumerConcept]
-which are [ConnectableConcept].
+namespace, which connects a [SignalProducer] and [SignalConsumer]
+which are [Connectable].
 
-Given a [SignalProducerConcept] `p` and [SignalConsumerConcept] `c`,
+Given a [SignalProducer] `p` and [SignalConsumer] `c`,
 
     connect(p,c);
     
@@ -55,8 +55,8 @@
 [section invoke function]
 
 [DataflowSignals] provides an [invoke] function in the `boost::signals`
-namespace, which invokes a [InvocableConcept] [DataflowSignals]
-[ComponentConcept].
+namespace, which invokes a [Invocable] [DataflowSignals]
+[Component].
 
 [endsect]
 
@@ -73,7 +73,7 @@
 [heading Models]
 
 * [SignalConsumer]
-* [ProxyPortConcept]
+* [ProxyPort]
 
 [endsect][/slot_selector]
 

Copied: sandbox/SOC/2007/signals/libs/dataflow/doc/support/concepts/binary_operable.qbk (from r41673, /sandbox/SOC/2007/signals/libs/dataflow/doc/concepts/binary_operable.qbk)
==============================================================================
--- /sandbox/SOC/2007/signals/libs/dataflow/doc/concepts/binary_operable.qbk (original)
+++ sandbox/SOC/2007/signals/libs/dataflow/doc/support/concepts/binary_operable.qbk 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -1,25 +1,25 @@
 [section:binaryoperable BinaryOperable (Connectable, OnlyConnectable, Disconnectable, Extractable) ]
 
-A [ProducerPortConcept] `P` and [ConsumerPortConcept] `C` are /BinaryOperable/
+A [ProducerPort] `P` and [ConsumerPort] `C` are /BinaryOperable/
 for a binary operation `O`, and mechanism `M`, if the implementation of
 the binary operation `O` has been specialized for `M`, `P`, and `C`.
 
 In this case,
 
-* If `O` is operations::connect, `P` and `C` are [ConnectableConcept]
-* If `O` is operations::connect_only, `P` and `C` are [OnlyConnectableConcept]
-* If `O` is operations::disconnect, `P` and `C` are [DisconnectableConcept]
-* If `O` is operations::extract, `P` and `C` are [ExtractableConcept]
+* If `O` is operations::connect, `P` and `C` are [Connectable]
+* If `O` is operations::connect_only, `P` and `C` are [OnlyConnectable]
+* If `O` is operations::disconnect, `P` and `C` are [Disconnectable]
+* If `O` is operations::extract, `P` and `C` are [Extractable]
 
 [heading Notation]
 The following expressions are used in this document:
 
 [variablelist
- [[P] [A [ProducerPortConcept] type.]]
- [[C_C] [A [ConsumerPortConcept] [ConnectableConcept] with `P`]]
- [[C_O] [A [ConsumerPortConcept] [OnlyConnectableConcept] with `P`]]
- [[C_D] [A [ConsumerPortConcept] [DisconnectableConcept] with `P`]]
- [[C_E] [A [ConsumerPortConcept] [ExtractableConcept] with `P`]]
+ [[P] [A [ProducerPort] type.]]
+ [[C_C] [A [ConsumerPort] [Connectable] with `P`]]
+ [[C_O] [A [ConsumerPort] [OnlyConnectable] with `P`]]
+ [[C_D] [A [ConsumerPort] [Disconnectable] with `P`]]
+ [[C_E] [A [ConsumerPort] [Extractable] with `P`]]
     [[p] [An object of type P.]]
     [[c_c] [An object of type C_C.]]
     [[c_o] [An object of type C_O.]]

Copied: sandbox/SOC/2007/signals/libs/dataflow/doc/support/concepts/component.qbk (from r41673, /sandbox/SOC/2007/signals/libs/dataflow/doc/concepts/component.qbk)
==============================================================================
--- /sandbox/SOC/2007/signals/libs/dataflow/doc/concepts/component.qbk (original)
+++ sandbox/SOC/2007/signals/libs/dataflow/doc/support/concepts/component.qbk 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -1,17 +1,17 @@
 
 [section:component Component, ComponentTraits]
 
-A ['[ComponentConcept]] is the fundamental data processing element. It can
-have a number of [PortConcept]s, and can also be [InvocableConcept].
+A ['[Component]] is the fundamental data processing element. It can
+have a number of [Port]s, and can also be [Invocable].
 
-The traits of a component are held in a ['[ComponentTraitsConcept]] type.
-There are multiple ways of registering the [ComponentTraitsConcept]
-for a [ComponentConcept] (see examples below).
+The traits of a component are held in a ['[ComponentTraits]] type.
+There are multiple ways of registering the [ComponentTraits]
+for a [Component] (see examples below).
 
 [heading Notation]
 [variablelist
- [[C] [A [ComponentConcept] type.]]
- [[CT] [The [ComponentTraitsConcept] type of `C`.]]
+ [[C] [A [Component] type.]]
+ [[CT] [The [ComponentTraits] type of `C`.]]
     [[I] [An MPL Integral Constant in the range \[0, number of ports exposed by C).]]
     [[c] [An object of type C.]]
 ]
@@ -24,7 +24,7 @@
         [`component_traits_of<M, C>::type`]
         [`CT`]
         [
- The [ComponentTraitsConcept] of the component.
+ The [ComponentTraits] of the component.
         ]
     ]
     [
@@ -38,10 +38,10 @@
     ]
     [
         [ GetComponentPort ]
- [`get_component_port<M, I>(c)`]
+ [`get_port<M, I>(c)`]
         []
         [
- Returns the I'th [PortConcept] exposed by `C`
+ Returns the I'th [Port] exposed by `C`
         ]
     ]
 ]
@@ -52,10 +52,10 @@
     [
         [Port Traits]
         [`CT::ports`]
- [MPL Sequence of [PortTraitsConcept] types]
+ [MPL Sequence of [PortTraits] types]
         [
- An enumeration of the [PortTraitsConcept] of the exposed
- [PortConcept]s.
+ An enumeration of the [PortTraits] of the exposed
+ [Port]s.
         ]
     ]
 ]
@@ -78,19 +78,19 @@
 
 [section:componentoperable ComponentOperable (Invocable) ]
 
-A [ComponentConcept] `P` is /ComponentOperable/
+A [Component] `P` is /ComponentOperable/
 for a component operation `O`, and mechanism `M`, if the implementation of
 the component operation `O` has been specialized for `M` and `P`
 
 In this case,
 
-* If `O` is operations::invoke, `P` is [InvocableConcept]
+* If `O` is operations::invoke, `P` is [Invocable]
 
 [heading Notation]
 The following expressions are used in this document:
 
 [variablelist
- [[C] [A [ComponentConcept] type.]]
+ [[C] [A [Component] type.]]
     [[c] [An object of type P.]]
 ]
 

Copied: sandbox/SOC/2007/signals/libs/dataflow/doc/support/concepts/concepts.qbk (from r41673, /sandbox/SOC/2007/signals/libs/dataflow/doc/concepts/concepts.qbk)
==============================================================================
--- /sandbox/SOC/2007/signals/libs/dataflow/doc/concepts/concepts.qbk (original)
+++ sandbox/SOC/2007/signals/libs/dataflow/doc/support/concepts/concepts.qbk 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -38,7 +38,7 @@
 implementation.
 
 In the Dataflow library, most port related class templates are keyed through
-a [MechanismConcept] type tag. For example, the [DataflowSignals] layer
+a [Mechanism] type tag. For example, the [DataflowSignals] layer
 uses two mechanisms for its ports and related operations - one mechanism
 is used for lasting connections between a `signal` and a `function`, while
 another is used for one-time extractions of data.
@@ -55,7 +55,7 @@
 a function that returns a value. Similarly, a consumer port could be anything
 that consumes data - a function that takes an argument, a functor, etc.
 
-Ports are captured more formally by the [PortConcept] concept.
+Ports are captured more formally by the [Port] concept.
 
 [heading Components]
 
@@ -64,20 +64,20 @@
 might have one consumer port (consuming video to be processed) and one
 producer port (producing filtered video).
 
-Typically, a component is embedded in a class, and the different [PortConcept]s
+Typically, a component is embedded in a class, and the different [Port]s
 are accessible either through the class directly, or through its member
 functions and variables.
 
-The Dataflow library also offers a [ComponentConcept] concept, which is
+The Dataflow library also offers a [Component] concept, which is
 intented to provide compile-time introspection and other operations.
 
 [heading Proxies]
 
-It is often the case that a port delegates its [PortConcept]
+It is often the case that a port delegates its [Port]
 functionality to some other element. For example, a
 class that is a [DataflowSignals] component might delegate its
-[ProducerPortConcept] functionality to a member boost::signal. It can
-do so by declaring itself a [ProxyProducerPortConcept] for the boost::signal.
+[ProducerPort] functionality to a member boost::signal. It can
+do so by declaring itself a [ProxyProducerPort] for the boost::signal.
 
 [heading Port Operations]
 
@@ -89,8 +89,8 @@
 which it collects data from.
 
 Operations between two ports such as /connect/, /connect_only/, /disconnect/,
-and /extract/ are captured by the [BinaryOperableConcept] concept. Operations
-on a single port such as /disconnect_all/ are covered by the [UnaryOperableConcept]
+and /extract/ are captured by the [BinaryOperable] concept. Operations
+on a single port such as /disconnect_all/ are covered by the [UnaryOperable]
 concept.
 
 [/
@@ -132,7 +132,7 @@
 causing it to consume data from connected producers, and producing data
 for connected consumers.
 
-Invocation is captured more formally by the [InvocableConcept] concept.
+Invocation is captured more formally by the [Invocable] concept.
 
 [section Port related]
 

Copied: sandbox/SOC/2007/signals/libs/dataflow/doc/support/concepts/port.qbk (from r41673, /sandbox/SOC/2007/signals/libs/dataflow/doc/concepts/port.qbk)
==============================================================================
--- /sandbox/SOC/2007/signals/libs/dataflow/doc/concepts/port.qbk (original)
+++ sandbox/SOC/2007/signals/libs/dataflow/doc/support/concepts/port.qbk 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -1,7 +1,7 @@
 [section PortCategory]
 
-A [PortCategoryConcept] designates a category of port in the Dataflow library.
-The library currently defines two [PortCategoryConcept]s:
+A [PortCategory] designates a category of port in the Dataflow library.
+The library currently defines two [PortCategory]s:
 
 * `boost::dataflow::ports::producer`, and
 * `boost::dataflow::ports::consumer`.
@@ -12,7 +12,7 @@
 The following expressions are used in this document:
 
 [variablelist
- [[PC] [A [PortCategoryConcept] type.]]
+ [[PC] [A [PortCategory] type.]]
 ]
 
 [heading Requirements]
@@ -20,14 +20,22 @@
 [table
     [[Name] [Expression] [Result Type] [Description]]
     [
- [Opposite PortCategory]
+ [Complementing PortCategory]
         [`PC::complement`]
- [[PortCategoryConcept] type]
+ [[PortCategory] type]
         [
- The complementing [PortCategoryConcept] of `PC`, meaning that it
- is possible to make connections between [PortConcept]s of
- [PortCategoryConcept] `PC` and [PortConcept]s of
- [PortCategoryConcept] `PC::complement`.
+ The complementing [PortCategory] of `PC`, meaning that it
+ is possible to make connections between [Port]s of
+ [PortCategory] `PC` and [Port]s of
+ [PortCategory] `PC::complement`.
+ ]
+ ]
+ [
+ [Is PortCategory Trait]
+ [[^[is_port_category]<T>::type]]
+ [Boolean MPL Metafunction that evaulates to true]
+ [
+ Trait encapsulating adherence to the [PortCategory] concept.
         ]
     ]
 ]
@@ -46,34 +54,29 @@
 
 [section:port Port, PortTraits]
 
-A ['[PortConcept]] is the fundamental point of data production or consumption.
-In order for a type `P` to satisfy the [PortConcept] concept requirements,
-a [PortTraitsConcept] type (specifying the traits of the port)
+A ['[Port]] is the fundamental point of data production or consumption.
+In order for a type `P` to satisfy the [Port] concept requirements,
+a [PortTraits] type (specifying the traits of the port)
 must be registered for the port. Registration can be
 performed in multiple ways (see the examples below).
 
-[PortConcept] concept
-requirements are always relative to a particular a [MechanismConcept] `M` and
-[PortCategoryConcept] `PC`.
-
-* If `PC` is `ports::producer`, then `P` is a [ProducerPortConcept]
-* If `PC` If `ports::consumer`, then `P` is a [ConsumerPortConcept]
-
-A type can be a [PortConcept] for multiple mechanisms and/or port categories.
+[Port] concept
+requirements are always relative to a particular [Tag], so a type
+can be a [Port] for multiple [Tag]s.
 
 [heading Port Refinements]
 
-* [KeyedPortConcept]
-* [ComplementedPortConcept]
+* [KeyedPort]
+* [ComplementedPort]
 
 [heading Notation]
 The following expressions are used in this document:
 
 [variablelist
- [[`M`] [A [MechanismConcept] type.]]
- [[`PC`] [A [PortCategoryConcept] type.]]
- [[`P`] [A Port type, for [MechanismConcept] `M` and [PortCategoryConcept] `PC`.]]
- [[`PT`] [[PortTraitsConcept] of `P` for `M` and `PC`.]]
+ [[`T`] [A [Tag] type. If omitted, `T` defaults to [default_tag].]]
+ [[`PC`] [A [PortCategory] type.]]
+ [[`P`] [A Port type, for [Tag] `T`.]]
+ [[`PT`] [[PortTraits] of `P` for `T`.]]
     [[`p`] [An object of type `P`]]
 ]
 
@@ -82,15 +85,15 @@
     [[Name] [Expression] [Result Type] [Semantics]]
     [
         [Port Traits]
- [`port_traits_of<M, PC, P>::type`]
+ [[^[port_traits_of]<P, T>::type]]
         [`PT`]
         [
- The [PortTraitsConcept] of the port.
+ The [PortTraits] of the port.
         ]
     ]
     [
         [IsPort Trait]
- [`is_port<M, PC, P>::type`]
+ [[^[is_port]<P, T>::type]]
         [Boolean metafunction that evaluates to true]
         [
             A trait encapsulating adherence to the Port
@@ -98,13 +101,11 @@
         ]
     ]
     [
- [Get Port]
- [`get_port<M,PC>(p)`]
- [`get_port_result_type<M,PC,P>::type`]
+ [Get Default Port]
+ [`get_default_port<D,M,T>(p)`]
+ [p]
         [
- Returns the underlying port object. With regular ports,
- this is typically a reference to `p`. With [ProxyPortConcept]
- objects, it is typically the proxied port object.
+ Returns the port object.
         ]
     ]
 ]
@@ -113,24 +114,23 @@
 [table
     [[Name] [Expression] [Result Type] [Semantics]]
     [
- [Mechanism]
- [`PT::mechanism`]
- [any type]
- [[MechanismConcept] type tag.]
- ]
- [
         [Port Category]
- [`PT::port_category`]
- [[PortCategoryConcept] type]
+ [`PT::category`]
+ [[PortCategory] type]
         [The category of the port]
     ]
     [
- [Port Concept]
- [`PT::port_concept`]
+ [Port ]
+ [`PT::concept`]
         [`concepts::port`, `concepts::keyed_port`, `concepts::complemented_port`]
         [The most refined producer concept that `P` satisfies.]
     ]
-
+ [
+ [Mechanism]
+ [`PT::tag`]
+ [any type]
+ [[Mechanism] type tag.]
+ ]
 ]
 
 [heading Header]
@@ -142,54 +142,63 @@
     #include <boost/dataflow/support.hpp>
 ```
 
+[heading Models]
+* [port]
+* [port_traits]
+
 [heading Notes]
 
 There is an intrusive as well as a non-intrusive way to register the
-[PortTraitsConcept] of a type `P`, thereby making it a [PortConcept].
+[PortTraits] of a type `P`, thereby making it a [Port].
 
-Non-intrusive registration is done by providing a specialization of
-the `register_port_traits` template (either directly, or through the provided
-macros DATAFLOW_PORT_TRAITS and DATAFLOW_PORT_TRAITS_ENABLE_IF).
+Non-intrusive registration is typically done by providing a specialization of
+the [register_port_traits] template (either directly, or through the provided
+macros [DATAFLOW_PORT_TRAITS] and [DATAFLOW_PORT_TRAITS_ENABLE_IF]). This will
+specialize [port_traits_of] for all cv-qualified versions of type `P`.
+If cv-qualified versions of type `P` should have different [PortTraits]s,
+[port_traits_of] should be specialized directly.
 
 Intrusive registration can be done by providing
-a `P::port_traits` member type, which can be either a [PortTraitsConcept]
-type, or an MPL sequence of [PortTraitsConcept] types. Alternatively,
+a `P::port_traits` member type, which can be either a [PortTraits]
+type, or an MPL sequence of [PortTraits] types. Alternatively,
 the Dataflow library provides a convenience class
-`port` which you can inherit instead of declaring the member type.
+`port` which you can inherit instead of declaring the member type. This
+provides the additional benefit of using the free functions in the
+`boost::dataflow` namespace using ADL.
 
 The below examples illustrate the avaliable registration methods.
 
 [heading Examples]
 
-All of the below examples use the following [MechanismConcept] and
-[PortTraitsConcept] types:
+All of the below examples use the following [Mechanism] and
+[PortTraits] types:
 
 [port_registration_example_prep]
 
 [heading Intrusive registration]
 
 Intrusive registration is the easiest, but assumes you can modify the
-[PortConcept]:
+[Port]:
 
 [port_registration_example_intrusive]
 
 [heading Non-intrusive registration]
 
 Non-intrusive registration is done by specializing the `register_port_traits`
-template. Since the `register_port_traits` template is keyed by [MechanismConcept]
-and [PortCategoryConcept], this is rather verbose:
+template. Since the `register_port_traits` template is keyed by [Mechanism]
+and [PortCategory], this is rather verbose:
 
 [port_registration_example_non_intrusive]
 
 To make things simpler, the Dataflow library provides a macro for non-intrusive
 registration (the macro also performs a static check on the
-[PortTraitsConcept]).
+[PortTraits]).
 
 [port_registration_example_non_intrusive_macro]
 
 [heading Non-intrusive mass registration]
 
-The `register_port_traits` template has an Enable template parameter for use with
+The [register_port_traits] template has an Enable template parameter for use with
 `boost::enable_if`. Hence, we can register a number of types at the same time:
 
 [port_registration_example_non_intrusive_enable_if]
@@ -209,37 +218,37 @@
 
 [section:complementedport ComplementedPort, ComplementedPortTraits]
 
-A ComplementedPort `P` is a [PortConcept] s.t. whenever it is
-[BinaryOperableConcept] with another [PortConcept] `P2`, `P2` is
+A ComplementedPort `P` is a [Port] s.t. whenever it is
+[BinaryOperable] with another [Port] `P2`, `P2` is
 a particular type - `P`'s complement type.
 
-[ComplementedPortConcept]s are useful in situations where [PortConcept] types
-are [BinaryOperableConcept] in a one-to-one fashion (a pair of [PortConcept] types
+[ComplementedPort]s are useful in situations where [Port] types
+are [BinaryOperable] in a one-to-one fashion (a pair of [Port] types
 are each other's port complements), or in a one-to-many fashion (a number
-of [PortConcept] types have the same complement port). An example of the
+of [Port] types have the same complement port). An example of the
 latter is [DataflowSignals], where any `signal` of signature `T` has
 a complement port of type `function<T>`, and can therefore model
-[ComplementedPortConcept], but `function<T>` is cannot because there are many `signal`
+[ComplementedPort], but `function<T>` is cannot because there are many `signal`
 types to which it can be connected.
 
-The traits of a [ComplementedPortConcept] are captured by the
-[ComplementedPortTraitsConcept], which refines the [PortTraitsConcept] with
+The traits of a [ComplementedPort] are captured by the
+[ComplementedPortTraits], which refines the [PortTraits] with
 an additional member type specifying the complement port type.
 
 [heading ComplementedPort Refines]
-* [PortConcept]
+* [Port]
 
 [heading ComplementedPortTraits Refines]
-* [PortTraitsConcept]
+* [PortTraits]
 
 [heading Notation]
 The following expressions are used in this document:
 
 [variablelist
- [[`M`] [A [MechanismConcept] type.]]
- [[`PC`] [A [PortCategoryConcept] type.]]
- [[`P`] [A [ComplementedPortConcept] type, for [MechanismConcept] `M` and [PortCategoryConcept] `PC`.]]
- [[`PT`] [[ComplementedPortTraitsConcept] of `P` for `M` and `PC`.]]
+ [[`T`] [A [Tag] type. If omitted, `T` defaults to [default_tag].]]
+ [[`PC`] [A [PortCategory] type.]]
+ [[`P`] [A [ComplementedPort] type, for [Tag] `T`.]]
+ [[`PT`] [[ComplementedPortTraits] of `P` for `T`.]]
 ]
 
 [heading ComplementedPort Requirements]
@@ -250,7 +259,7 @@
         [`port_traits_of<M, PC, P>::type`]
         [`PT`]
         [
- The [ComplementedPortTraitsConcept] of the port.
+ The [ComplementedPortTraits] of the port.
         ]
     ]
 ]
@@ -261,17 +270,19 @@
     [
         [Complement Port Type]
         [`PT::complement_port_type`]
- [Any [PortConcept] type]
+ [Any [Port] type]
         [
- The complement port type of the port type `P`. If `P` is
- [BinaryOperableConcept] with another port type `P2`, then
- `get_port<PT::mechanism, PT::category::complement>(p2)` must
- return an object of type `PT::complement_port_type` or reference
- to such.
+ The complement port type of `P`. If `P` is
+ [BinaryOperable] with another port type `P2`, then `P2` must
+ be `PT::complement_port_type`.
         ]
     ]
 ]
 
+[heading Models]
+
+* [complemented_port_traits]
+
 [endsect]
 
 [section KeyedPort]
@@ -279,11 +290,11 @@
 
 [section ProxyPort, ProxyPortTraits]
 
-A type `PP` is a ['[ProxyPortConcept]] for a mechanism `M` and port category `PC`
-if it specifies a [ProxyPortTraitsConcept] for that mechanism and port category.
+A type `PP` is a ['[ProxyPort]] for a mechanism `M` and port category `PC`
+if it specifies a [ProxyPortTraits] for that mechanism and port category.
 
 If the proxied port type is a valid
-[PortConcept], then 'PP' satisfies the [PortConcept] requirements
+[Port], then 'PP' satisfies the [Port] requirements
 in the same way.
 
 [heading Notation]
@@ -300,7 +311,7 @@
     [
         [Proxy Port Traits]
         [`proxy_port_traits_of<PP>::type`]
- [[ProxyPortTraitsConcept] type.]
+ [[ProxyPortTraits] type.]
         [
             The traits of the proxy port.
         ]

Copied: sandbox/SOC/2007/signals/libs/dataflow/doc/support/concepts/unary_operable.qbk (from r41673, /sandbox/SOC/2007/signals/libs/dataflow/doc/concepts/unary_operable.qbk)
==============================================================================
--- /sandbox/SOC/2007/signals/libs/dataflow/doc/concepts/unary_operable.qbk (original)
+++ sandbox/SOC/2007/signals/libs/dataflow/doc/support/concepts/unary_operable.qbk 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -1,7 +1,7 @@
 
 [section:unaryoperable UnnaryOperable (AllDisconnectable) ]
 
-A [PortConcept] `P` is /UnnaryOperable/
+A [Port] `P` is /UnnaryOperable/
 for a unary operation `O`, and mechanism `M`, if the implementation of
 the unnary operation `O` has been specialized for `M` and `P`
 
@@ -13,7 +13,7 @@
 The following expressions are used in this document:
 
 [variablelist
- [[P] [A [PortConcept] type.]]
+ [[P] [A [Port] type.]]
     [[p] [An object of type P.]]
 ]
 

Added: sandbox/SOC/2007/signals/libs/dataflow/doc/support/support.qbk
==============================================================================
--- (empty file)
+++ sandbox/SOC/2007/signals/libs/dataflow/doc/support/support.qbk 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -0,0 +1,7 @@
+[section:support Generic Support Layer]
+
+[include concepts/concepts.qbk]
+
+[xinclude ../dataflow_support_doxygen.xml]
+
+[endsect]

Modified: sandbox/SOC/2007/signals/libs/dataflow/example/Jamfile.v2
==============================================================================
--- sandbox/SOC/2007/signals/libs/dataflow/example/Jamfile.v2 (original)
+++ sandbox/SOC/2007/signals/libs/dataflow/example/Jamfile.v2 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -3,18 +3,18 @@
 # accompanying file LICENSE_1_0.txt or copy at
 # http://www.boost.org/LICENSE_1_0.txt)
 
-build-project VTK ;
-build-project signals ;
-build-project blueprint ;
+#build-project VTK ;
+#build-project signals ;
+#build-project blueprint ;
 
 project dataflow/example
     : requirements
       <include>../../..
- <include>$(BOOST_ROOT)/boost
+ <include>$(BOOST_ROOT)
       <define>BOOST_ALL_NO_LIB=1
     ;
 
 # exe timing_example : timing_example.cpp ;
 #exe edit_distance : edit_distance.cpp ;
 #exe fibonacci : fibonacci.cpp ;
-
+exe example : example.cpp ;

Modified: sandbox/SOC/2007/signals/libs/dataflow/example/VTK/vtk_dataflow_support.hpp
==============================================================================
--- sandbox/SOC/2007/signals/libs/dataflow/example/VTK/vtk_dataflow_support.hpp (original)
+++ sandbox/SOC/2007/signals/libs/dataflow/example/VTK/vtk_dataflow_support.hpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -376,9 +376,9 @@
 //]
 
 //[ vtk_specialize_connect
-// the include templates expect DATAFLOW_TEMPLATE_MECHANISM to have
+// the include templates expect DATAFLOW_TEMPLATE_TAG to have
 // the mechanism type
-#define DATAFLOW_TEMPLATE_MECHANISM boost::dataflow::vtk::mechanism
+#define DATAFLOW_TEMPLATE_TAG boost::dataflow::vtk::mechanism
 
 // the binary_operation.hpp template expects DATAFLOW_TEMPLATE_BINARY_OPERATION
 # define DATAFLOW_TEMPLATE_BINARY_OPERATION connect
@@ -400,7 +400,7 @@
 
 # undef DATAFLOW_TEMPLATE_BINARY_OPERATION
 
-#undef DATAFLOW_TEMPLATE_MECHANISM
+#undef DATAFLOW_TEMPLATE_TAG
 
 // We now have connect and connect_only functions that each take a
 // vtk ProducerPort and vtk ConsumerPort as arguments, and try to connect them.

Modified: sandbox/SOC/2007/signals/libs/dataflow/example/example.cpp
==============================================================================
--- sandbox/SOC/2007/signals/libs/dataflow/example/example.cpp (original)
+++ sandbox/SOC/2007/signals/libs/dataflow/example/example.cpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -3,11 +3,15 @@
 // accompanying file LICENSE_1_0.txt or copy at
 // http://www.boost.org/LICENSE_1_0.txt)
 
-#include <boost/dataflow/support.hpp>
+#include <boost/mpl/is_sequence.hpp>
+#include <boost/mpl/at.hpp>
+#include <boost/fusion/container/vector.hpp>
+#include <boost/fusion/include/mpl.hpp>
 
 using namespace boost;
 
-
 int main()
 {
+ BOOST_MPL_ASSERT(( mpl::at<fusion::vector<mpl::true_>, mpl::int_<0> >::type ));
+ BOOST_MPL_ASSERT(( mpl::is_sequence<fusion::vector<int> > ));
 }

Modified: sandbox/SOC/2007/signals/libs/dataflow/test/Jamfile.v2
==============================================================================
--- sandbox/SOC/2007/signals/libs/dataflow/test/Jamfile.v2 (original)
+++ sandbox/SOC/2007/signals/libs/dataflow/test/Jamfile.v2 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -13,11 +13,11 @@
     ;
 
 run test_port.cpp ;
-run test_proxy_port.cpp ;
+#run test_proxy_port.cpp ;
 run test_unary_op.cpp ;
 run test_binary_op.cpp ;
 run test_keyed_port.cpp ;
 run test_component.cpp ;
-run test_reflective_component.cpp ;
+#run test_reflective_component.cpp ;
 
 build-project signals ;

Modified: sandbox/SOC/2007/signals/libs/dataflow/test/my_producer_consumer.hpp
==============================================================================
--- sandbox/SOC/2007/signals/libs/dataflow/test/my_producer_consumer.hpp (original)
+++ sandbox/SOC/2007/signals/libs/dataflow/test/my_producer_consumer.hpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -18,14 +18,12 @@
 
 struct my_producer_traits
     : public df::port_traits<
- my_mechanism,
         df::ports::producer,
         df::concepts::port>
 {};
 
 struct my_consumer_traits
     : public df::port_traits<
- my_mechanism,
         df::ports::consumer,
         df::concepts::port>
 {};

Added: sandbox/SOC/2007/signals/libs/dataflow/test/my_producer_consumer_operations.hpp
==============================================================================
--- (empty file)
+++ sandbox/SOC/2007/signals/libs/dataflow/test/my_producer_consumer_operations.hpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -0,0 +1,57 @@
+// Copyright Stjepan Rajko 2007. Use, modification and
+// distribution is subject to 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)
+
+#ifndef DATAFLOW_TEST_MY_PRODUCER_CONSUMER_OPERATIONS_HPP
+#define DATAFLOW_TEST_MY_PRODUCER_CONSUMER_OPERATIONS_HPP
+
+#include <boost/dataflow/support/binary_operation.hpp>
+
+
+bool connected = false;
+bool only_connected = false;
+bool disconnected = false;
+
+namespace boost { namespace dataflow { namespace extension {
+
+template<>
+struct binary_operation_impl<my_producer_traits, my_consumer_traits, operations::connect>
+{
+ typedef void result_type;
+
+ template<typename Producer, typename Consumer>
+ void operator()(Producer &, Consumer &)
+ {
+ connected = true;
+ }
+};
+
+template<>
+struct binary_operation_impl<my_producer_traits, my_consumer_traits, operations::connect_only>
+{
+ typedef void result_type;
+
+ template<typename Producer, typename Consumer>
+ void operator()(Producer &, Consumer &)
+ {
+ only_connected = true;
+ }
+};
+
+template<>
+struct binary_operation_impl<my_producer_traits, my_consumer_traits, operations::disconnect>
+{
+ typedef void result_type;
+
+ template<typename Producer, typename Consumer>
+ void operator()(Producer &, Consumer &)
+ {
+ disconnected = true;
+ }
+};
+
+}}}
+
+
+#endif
\ No newline at end of file

Modified: sandbox/SOC/2007/signals/libs/dataflow/test/signals/Jamfile.v2
==============================================================================
--- sandbox/SOC/2007/signals/libs/dataflow/test/signals/Jamfile.v2 (original)
+++ sandbox/SOC/2007/signals/libs/dataflow/test/signals/Jamfile.v2 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -13,7 +13,7 @@
       <define>BOOST_ALL_NO_LIB=1
     ;
 
-run test_result_of_defined.cpp ;
+#run test_result_of_defined.cpp ;
 run test_bind_object.cpp ;
 run test_connect.cpp ;
 

Modified: sandbox/SOC/2007/signals/libs/dataflow/test/signals/test_branching.cpp
==============================================================================
--- sandbox/SOC/2007/signals/libs/dataflow/test/signals/test_branching.cpp (original)
+++ sandbox/SOC/2007/signals/libs/dataflow/test/signals/test_branching.cpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -36,7 +36,8 @@
  
         banger
             | counter
- | (floater.send_slot() >>= collector);
+ | floater.send_slot();
+ floater >>= collector;
         
         banger();
         BOOST_CHECK_EQUAL(counter.count(), 1);
@@ -51,10 +52,10 @@
         signals::storage<void (float), signals::fused> collector(0.0f);
         
         banger
- // floater connects to collector, banger to floater.send_slot()
- | (floater.send_slot() >>= collector)
- | counter; // and banger to counter
-
+ | counter
+ | floater.send_slot();
+ floater >>= collector;
+
         banger();
         BOOST_CHECK_EQUAL(counter.count(), 1);
         BOOST_CHECK_EQUAL(collector.at<0>(), 2.5f);

Modified: sandbox/SOC/2007/signals/libs/dataflow/test/signals/test_chain.cpp
==============================================================================
--- sandbox/SOC/2007/signals/libs/dataflow/test/signals/test_chain.cpp (original)
+++ sandbox/SOC/2007/signals/libs/dataflow/test/signals/test_chain.cpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -16,14 +16,14 @@
 using namespace boost;
 
 //[ test_chain_classes
-class UnfusedDoublerClass : public signals::filter<void (float)>
+class UnfusedDoublerClass : public signals::filter<UnfusedDoublerClass, void (float)>
 {
 public:
     typedef void result_type;
         void operator()(float x) {out(2*x);}
 };
 
-class FusedDoublerClass : public signals::filter<void (float), signals::fused>
+class FusedDoublerClass : public signals::filter<FusedDoublerClass, void (float), signals::fused>
 {
 public:
     typedef void result_type;

Modified: sandbox/SOC/2007/signals/libs/dataflow/test/signals/test_connect.cpp
==============================================================================
--- sandbox/SOC/2007/signals/libs/dataflow/test/signals/test_connect.cpp (original)
+++ sandbox/SOC/2007/signals/libs/dataflow/test/signals/test_connect.cpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -22,16 +22,25 @@
     int stored;
 };
 
-int test_main(int, char* [])
+int stored = 0;
+
+void f_receiver(int x)
 {
+ stored = x;
+};
 
+int test_main(int, char* [])
+{
+ namespace df = boost::dataflow;
+
     boost::signal<void(int)> p;
     receiver r;
-
+
+ connect(p, boost::function<void(int)>(f_receiver));
     connect(p, r);
-
+
     p(3);
-
+ BOOST_CHECK_EQUAL(stored, 3);
     BOOST_CHECK_EQUAL(r.stored, 3);
 
     return 0;

Modified: sandbox/SOC/2007/signals/libs/dataflow/test/signals/test_disconnect.cpp
==============================================================================
--- sandbox/SOC/2007/signals/libs/dataflow/test/signals/test_disconnect.cpp (original)
+++ sandbox/SOC/2007/signals/libs/dataflow/test/signals/test_disconnect.cpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -15,43 +15,7 @@
 {
     {
         //[ test_disconnect_unfused
- signals::storage<void ()> banger;
- {
- signals::counter<void ()> counter;
- signals::storage<void (float)> floater;
- floater(2.5f);
- signals::storage<void (float)> collector(0.0f);
-
- banger
- | counter
- | (floater.send_slot() >>= collector);
-
- banger();
- BOOST_CHECK_EQUAL(counter.count(), 1);
- BOOST_CHECK_EQUAL(collector.at<0>(), 2.5f);
-
- #ifndef SIGNAL_NETWORK_THREAD_SAFE
- BOOST_CHECK((
- boost::is_base_of<
- boost::signals::trackable,
- signals::counter<void ()>
- >::type::value));
- BOOST_CHECK((
- boost::is_base_of<
- boost::signals::trackable,
- signals::storage<void (float)>
- >::type::value));
- #endif
-
- } // counter, floater, and collector are now destroyed and disconnected with Boost.Signals
-#ifdef SIGNAL_NETWORK_THREAD_SAFE
- // if [DataflowSignals] has detected thread safe signals, we need to
- // touch the signal to disconnect things that are destroyed:
- // unfortunatelly, this call hangs on MSVC!
- // banger();
-#endif
- BOOST_CHECK_EQUAL(banger.get_proxied_producer().num_slots(), 0u);
-
+ signals::storage<void ()> banger;
         signals::counter<void ()> counter;
         
         banger >>= counter;

Modified: sandbox/SOC/2007/signals/libs/dataflow/test/signals/test_filter.cpp
==============================================================================
--- sandbox/SOC/2007/signals/libs/dataflow/test/signals/test_filter.cpp (original)
+++ sandbox/SOC/2007/signals/libs/dataflow/test/signals/test_filter.cpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -4,8 +4,7 @@
 // http://www.boost.org/LICENSE_1_0.txt)
 
 #include <boost/dataflow/signals/component/filter.hpp>
-#include <boost/dataflow/signals/component/storage.hpp>
-#include <boost/dataflow/signals/connection.hpp>
+#include <boost/dataflow/signals/connection/operators.hpp>
 
 #include <boost/fusion/sequence/intrinsic/at.hpp>
 
@@ -15,19 +14,36 @@
 
 //[ test_filter_classes
 
-class DoublerClass : public signals::filter<void (float)>
+class DoublerClass : public signals::filter<DoublerClass, void (int)>
 {
 public:
- void operator()(float x) {out(2*x);}
+ void operator()(int x) {out(2*x);}
 };
 
-class FusedDoublerClass : public signals::filter<void (float), signals::fused>
+struct receiver
+ : public boost::dataflow::port<boost::dataflow::signals::call_consumer>
+{
+ receiver() : stored(0) {}
+
+ void operator()(int x)
+ {
+ stored = x;
+ }
+ void operator()(const fusion::vector<int> &x)
+ {
+ stored = fusion::at_c<0>(x);
+ }
+
+ int stored;
+};
+
+class FusedDoublerClass : public signals::filter<FusedDoublerClass, void (int), signals::fused>
 {
 public:
- void operator()(const fusion::vector<float> &x)
+ void operator()(const fusion::vector<int> &x)
     {
         // this could be more general but I'm having problems with the general approach...
- fusion::vector<float> y;
+ fusion::vector<int> y;
         fusion::at_c<0>(y) = 2 * fusion::at_c<0>(x);
         fused_out(y);
     }
@@ -37,17 +53,17 @@
 
 int test_main(int, char* [])
 {
+ namespace df=boost::dataflow;
     {
         //[ test_filter_unfused
 
         DoublerClass doubler1, doubler2;
- signals::storage<void (float)> floater(1.0f);
- signals::storage<void (float)> collector(0.0f);
-
- floater >>= doubler1 >>= doubler2 >>= collector;
- floater.send();
+ receiver collector;
+
+ doubler1 >>= doubler2 >>= collector;
+ doubler1(1);
         
- BOOST_CHECK_EQUAL(collector.at<0>(), 4.0f);
+ BOOST_CHECK_EQUAL(collector.stored, 4);
         
         //]
     }
@@ -55,13 +71,12 @@
         //[ test_filter_fused
         
         FusedDoublerClass doubler1, doubler2;
- signals::storage<void (float), signals::fused> floater(1.0f);
- signals::storage<void (float), signals::fused> collector(0.0f);
+ receiver collector;
         
- floater >>= doubler1 >>= doubler2 >>= collector;
- floater.send();
+ doubler1 >>= doubler2 >>= collector;
+ doubler1(1);
         
- BOOST_CHECK_EQUAL(collector.at<0>(), 4.0f);
+ BOOST_CHECK_EQUAL(collector.stored, 4.0f);
         
         //]
     }

Modified: sandbox/SOC/2007/signals/libs/dataflow/test/signals/test_junction.cpp
==============================================================================
--- sandbox/SOC/2007/signals/libs/dataflow/test/signals/test_junction.cpp (original)
+++ sandbox/SOC/2007/signals/libs/dataflow/test/signals/test_junction.cpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -29,14 +29,14 @@
         BOOST_CHECK_EQUAL(counter1.count(), 2);
         BOOST_CHECK_EQUAL(counter2.count(), 2);
 
- junction.disable();
+ junction.close();
         banger1.send();
         banger2.send();
 
         BOOST_CHECK_EQUAL(counter1.count(), 2);
         BOOST_CHECK_EQUAL(counter2.count(), 2);
 
- junction.enable();
+ junction.open();
         banger1.send();
         banger2.send();
 
@@ -59,14 +59,14 @@
         BOOST_CHECK_EQUAL(counter1.count(), 2);
         BOOST_CHECK_EQUAL(counter2.count(), 2);
         
- junction.disable();
+ junction.close();
         banger1();
         banger2();
         
         BOOST_CHECK_EQUAL(counter1.count(), 2);
         BOOST_CHECK_EQUAL(counter2.count(), 2);
         
- junction.enable();
+ junction.open();
         banger1();
         banger2();
         

Modified: sandbox/SOC/2007/signals/libs/dataflow/test/signals/test_multi_args.cpp
==============================================================================
--- sandbox/SOC/2007/signals/libs/dataflow/test/signals/test_multi_args.cpp (original)
+++ sandbox/SOC/2007/signals/libs/dataflow/test/signals/test_multi_args.cpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -14,7 +14,7 @@
 
 //[ test_multi_args_class1
 
-class SignalFloatDuplicator : public signals::filter<void (float, float)>
+class SignalFloatDuplicator : public signals::filter<SignalFloatDuplicator, void (float, float)>
 {
 public:
     typedef void result_type;

Modified: sandbox/SOC/2007/signals/libs/dataflow/test/signals/test_multi_out.cpp
==============================================================================
--- sandbox/SOC/2007/signals/libs/dataflow/test/signals/test_multi_out.cpp (original)
+++ sandbox/SOC/2007/signals/libs/dataflow/test/signals/test_multi_out.cpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -12,7 +12,7 @@
 
 //[ test_multi_out_classes
 
-class SignalOutIntFloat : public signals::filter<void (float)>
+class SignalOutIntFloat : public signals::filter<SignalOutIntFloat, void (float)>
 {
 public:
     SignalOutIntFloat(float x) : x(x) {}

Modified: sandbox/SOC/2007/signals/libs/dataflow/test/signals/test_pull.cpp
==============================================================================
--- sandbox/SOC/2007/signals/libs/dataflow/test/signals/test_pull.cpp (original)
+++ sandbox/SOC/2007/signals/libs/dataflow/test/signals/test_pull.cpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -11,7 +11,7 @@
 using namespace boost;
 
 //[ test_pull_classes
-class PullDoubler : public signals::filter<float ()>
+class PullDoubler : public signals::filter<PullDoubler, float ()>
 {
 public:
     float operator()()

Modified: sandbox/SOC/2007/signals/libs/dataflow/test/signals/test_storage.cpp
==============================================================================
--- sandbox/SOC/2007/signals/libs/dataflow/test/signals/test_storage.cpp (original)
+++ sandbox/SOC/2007/signals/libs/dataflow/test/signals/test_storage.cpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -31,7 +31,9 @@
         // `-------------' `-----------'
         //
         // -------------------------------------------------------------
- banger >>= floater.send_slot() >>= collector;
+
+ banger >>= floater.send_slot();
+ floater >>= collector;
 
         // signal from banger is will invoke floater.send(), which causes
         // floater to output 2.5
@@ -39,6 +41,7 @@
         BOOST_CHECK_EQUAL(floater.at<0>(), 2.5f);
         BOOST_CHECK_EQUAL(collector.at<0>(), 2.5f);
 
+ floater.close();
         floater(1.5f); // change the value in floater
         invoke(floater); // we can also signal floater directly
         BOOST_CHECK_EQUAL(collector.at<0>(), 1.5f);
@@ -53,13 +56,15 @@
         signals::storage<void (float), signals::fused> collector(0.0f);
 
         // create the network (banger to floater.send, floater to collector)
- banger >>= floater.send_slot() >>= collector;
+ banger >>= floater.send_slot();
+ floater >>= collector;
         
         // signal from banger causes floater to output 2.5
         banger();
         BOOST_CHECK_EQUAL(collector.at<0>(), 2.5f);
         
         // change the value in floater
+ floater.close();
         floater(1.5f);
         invoke(floater); // we can also signal floater directly
         BOOST_CHECK_EQUAL(collector.at<0>(), 1.5f);

Modified: sandbox/SOC/2007/signals/libs/dataflow/test/test_binary_op.cpp
==============================================================================
--- sandbox/SOC/2007/signals/libs/dataflow/test/test_binary_op.cpp (original)
+++ sandbox/SOC/2007/signals/libs/dataflow/test/test_binary_op.cpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -4,63 +4,31 @@
 // http://www.boost.org/LICENSE_1_0.txt)
 
 #include "my_producer_consumer.hpp"
-#include <boost/dataflow/support/binary_operation.hpp>
-
-bool connected = false;
-bool only_connected = false;
-bool disconnected = false;
-
-namespace boost { namespace dataflow { namespace extension {
-
-template<>
-struct binary_operation_impl<operations::connect, my_producer_traits, my_consumer_traits>
-{
- template<typename Producer, typename Consumer>
- void operator()(Producer &, Consumer &)
- {
- connected = true;
- }
-};
-
-template<>
-struct binary_operation_impl<operations::connect_only, my_producer_traits, my_consumer_traits>
-{
- template<typename Producer, typename Consumer>
- void operator()(Producer &, Consumer &)
- {
- only_connected = true;
- }
-};
-
-template<>
-struct binary_operation_impl<operations::disconnect, my_producer_traits, my_consumer_traits>
-{
- template<typename Producer, typename Consumer>
- void operator()(Producer &, Consumer &)
- {
- disconnected = true;
- }
-};
-
-}}}
+#include "my_producer_consumer_operations.hpp"
 
 #include <boost/test/included/test_exec_monitor.hpp>
 
 namespace df = boost::dataflow;
 
+struct whatever;
+
 int test_main(int, char* [])
 {
     my_producer p;
     my_consumer c;
     
- df::binary_operation<df::operations::connect, my_mechanism>(p, c);
+ df::binary_operation<df::operations::connect, df::default_tag>(p, c);
     BOOST_CHECK(connected);
     
- df::binary_operation<df::operations::connect_only, my_mechanism>(p, c);
+ df::binary_operation<df::operations::connect_only, df::default_tag>(p, c);
     BOOST_CHECK(only_connected);
 
- df::binary_operation<df::operations::disconnect, my_mechanism>(p, c);
- BOOST_CHECK(disconnected);
+ df::binary_operation<df::operations::disconnect, df::default_tag>(p, c);
+ BOOST_CHECK(disconnected);
+
+ connected = false;
+ df::binary_operation<df::operations::connect, whatever, df::default_tag>(p, c);
+ BOOST_CHECK(connected);
     
     return 0;
 } // int test_main(int, char* [])

Modified: sandbox/SOC/2007/signals/libs/dataflow/test/test_component.cpp
==============================================================================
--- sandbox/SOC/2007/signals/libs/dataflow/test/test_component.cpp (original)
+++ sandbox/SOC/2007/signals/libs/dataflow/test/test_component.cpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -3,19 +3,45 @@
 // 1.0. (See accompanying file LICENSE_1_0.txt or copy at
 // http://www.boost.org/LICENSE_1_0.txt)
 
+#include "my_producer_consumer.hpp"
+#include "my_producer_consumer_operations.hpp"
+
 #include <boost/dataflow/support/component_operation.hpp>
-#include <boost/mpl/vector.hpp>
+#include <boost/dataflow/support/fusion_component.hpp>
+#include <boost/mpl/map.hpp>
 
-bool invoked = false;
+using namespace boost;
+
+namespace df=boost::dataflow;
 
-struct my_mechanism;
+bool invoked = false;
 
-struct my_component_traits : public boost::dataflow::component_traits<boost::mpl::vector< > >
+struct my_component_traits : public boost::dataflow::fusion_component_traits<
+ boost::fusion::vector<
+ my_producer &,
+ my_consumer &
+ >,
+ mpl::map<
+ mpl::pair<
+ df::default_port_selector<df::directions::outgoing>,
+ mpl::int_<0> >,
+ mpl::pair<
+ df::default_port_selector<dataflow::directions::incoming>,
+ mpl::int_<1> >
+ >
+>
 {};
 
-struct my_component
+struct my_component : public boost::dataflow::component<my_component_traits>
 {
- typedef my_component_traits component_traits;
+ my_producer p;
+ my_consumer c;
+
+ template<typename Component>
+ my_component_traits::port_result_types get_ports(Component &)
+ {
+ return my_component_traits::port_result_types(p, c);
+ }
 };
 
 namespace boost { namespace dataflow { namespace extension {
@@ -41,7 +67,17 @@
     my_component c;
     
     df::component_operation<df::operations::invoke>(c);
- BOOST_CHECK(invoked);
+ BOOST_CHECK(invoked);
+
+ BOOST_CHECK_EQUAL((&df::get_port<boost::mpl::int_<0> >(c)), &c.p);
+ BOOST_CHECK_EQUAL((&df::get_port<boost::mpl::int_<1> >(c)), &c.c);
+ BOOST_CHECK_EQUAL((&df::get_port_c<0>(c)), &c.p);
+ BOOST_CHECK_EQUAL((&df::get_port_c<1>(c)), &c.c);
+
+ my_component c2;
+
+ df::binary_operation<df::operations::connect, df::default_mechanism, df::default_tag>(c, c2);
+ BOOST_CHECK(connected);
     
     return 0;
 } // int test_main(int, char* [])

Modified: sandbox/SOC/2007/signals/libs/dataflow/test/test_keyed_port.cpp
==============================================================================
--- sandbox/SOC/2007/signals/libs/dataflow/test/test_keyed_port.cpp (original)
+++ sandbox/SOC/2007/signals/libs/dataflow/test/test_keyed_port.cpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -17,14 +17,12 @@
 
 struct my_other_producer_traits
     : public df::port_traits<
- my_mechanism,
         df::ports::producer,
         df::concepts::port>
 {};
 
 struct my_other_consumer_traits
     : public df::port_traits<
- my_mechanism,
         df::ports::consumer,
         df::concepts::port>
 {};
@@ -38,8 +36,10 @@
 namespace boost { namespace dataflow { namespace extension {
 
 template<>
-struct binary_operation_impl<operations::connect, my_producer_traits, my_consumer_traits>
+struct binary_operation_impl<my_producer_traits, my_consumer_traits, operations::connect>
 {
+ typedef void result_type;
+
     template<typename Producer, typename Consumer>
     void operator()(Producer &, Consumer &)
     {
@@ -48,8 +48,10 @@
 };
 
 template<>
-struct binary_operation_impl<operations::connect, my_other_producer_traits, my_other_consumer_traits>
+struct binary_operation_impl<my_other_producer_traits, my_other_consumer_traits, operations::connect>
 {
+ typedef void result_type;
+
     template<typename Producer, typename Consumer>
     void operator()(Producer &, Consumer &)
     {
@@ -73,13 +75,12 @@
> map_type;
         
     df::port_map<
- my_mechanism,
         df::ports::producer,
         map_type
> producer_map(map_type(producer, other_producer));
     
- df::binary_operation<df::operations::connect, my_mechanism>(producer_map, consumer);
- df::binary_operation<df::operations::connect, my_mechanism>(producer_map, other_consumer);
+ connect(producer_map, consumer);
+ connect(producer_map, other_consumer);
     
     BOOST_CHECK_EQUAL(connected, 1);
     BOOST_CHECK(connected_other);
@@ -90,20 +91,19 @@
             boost::fusion::pair<my_other_consumer_traits, my_other_consumer &>
> proxy_map_type;
     
- typedef
+/* typedef
     df::port_map<
- my_mechanism,
         df::ports::producer,
         proxy_map_type
> proxy_type;
     proxy_type proxy_map(proxy_map_type(consumer, other_consumer));
     
- BOOST_CHECK(( df::is_proxy_port<my_mechanism, df::ports::consumer, proxy_type>::value ));
+// BOOST_CHECK(( df::is_proxy_port<my_mechanism, df::ports::consumer, proxy_type>::value ));
     BOOST_CHECK(( df::is_port<my_mechanism, df::ports::consumer, proxy_type>::value ));
     
- df::binary_operation<df::operations::connect, my_mechanism>(producer, proxy_map);
+ df::binary_operation<df::operations::connect>(producer, proxy_map);
 
- BOOST_CHECK_EQUAL(connected, 2);
+ BOOST_CHECK_EQUAL(connected, 2);*/
 
     return 0;
 } // int test_main(int, char* [])

Modified: sandbox/SOC/2007/signals/libs/dataflow/test/test_port.cpp
==============================================================================
--- sandbox/SOC/2007/signals/libs/dataflow/test/test_port.cpp (original)
+++ sandbox/SOC/2007/signals/libs/dataflow/test/test_port.cpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -13,10 +13,13 @@
 // for different port registrations
 
 //[ port_registration_example_prep
-struct some_mechanism;
+typedef df::port_traits<df::ports::producer, df::concepts::port> producer_traits;
+typedef df::port_traits<df::ports::consumer, df::concepts::port> consumer_traits;
 
-typedef df::port_traits<some_mechanism, df::ports::producer, df::concepts::port> producer_traits;
-typedef df::port_traits<some_mechanism, df::ports::consumer, df::concepts::port> consumer_traits;
+struct some_tag;
+struct whatever;
+
+typedef df::port_traits<df::ports::consumer, df::concepts::port, some_tag> other_consumer_traits;
 
 //]
 
@@ -29,11 +32,12 @@
     typedef producer_traits port_traits;
 };
 
-// Intrusive registration of multiple ports
+// Intrusive registration of a multiple ports
 struct intrusive_producer_consumer_port
 {
- // intrusive_filter_port is a ProducerPort and a ConsumerPort
- typedef boost::mpl::vector<producer_traits, consumer_traits> port_traits;
+ // intrusive_producer_port is a ProducerPort for the default_tag,
+ // and a ConsumerPort for some_tag
+ typedef boost::mpl::vector<producer_traits, other_consumer_traits> port_traits;
 };
 //]
 
@@ -46,10 +50,9 @@
 
 namespace boost { namespace dataflow {
 
-// register_port_traits holds the PortTraits type of a Port, keyed by Mechanism
-// and PortCategory
+// register_port_traits holds the PortTraits type of a Port
 template<>
-struct register_port_traits<some_mechanism, df::ports::producer, non_intrusive_port>
+struct register_port_traits<non_intrusive_port>
 {
     typedef producer_traits type;
 };
@@ -79,13 +82,11 @@
 
 namespace boost { namespace dataflow {
 
-// register_port_traits holds the PortTraits type of a Port, keyed by Mechanism
-// and PortCategory
+// register_port_traits holds the PortTraits type of a Port
 template<typename T>
 struct register_port_traits<
- some_mechanism,
- df::ports::producer,
     T,
+ default_tag,
     typename boost::enable_if<
         boost::is_base_of<non_intrusive_port_base, T>
>::type>
@@ -131,36 +132,29 @@
     BOOST_CHECK(!df::is_port_traits<incomplete>::value);
     BOOST_CHECK(!df::is_port_traits<empty>::value);
     
- BOOST_CHECK(( df::is_port<my_mechanism, df::ports::producer, my_producer>::value ));
- BOOST_CHECK(( df::is_port<my_mechanism, df::ports::consumer, my_consumer>::value ));
+ BOOST_CHECK(( df::is_port<my_producer>::value ));
+ BOOST_CHECK(( df::is_port<my_consumer>::value ));
     
- BOOST_CHECK(( !df::is_port<my_mechanism, df::ports::producer, incomplete>::value ));
- BOOST_CHECK(( !df::is_port<my_mechanism, df::ports::producer, empty>::value ));
+ BOOST_CHECK(( !df::is_port<empty>::value ));
     
     my_producer p;
-
- BOOST_CHECK_EQUAL(&p, (&df::get_port<my_mechanism, df::ports::producer>(p) ));
- BOOST_CHECK(( boost::is_same<df::get_port_result_type<my_mechanism, df::ports::producer, my_producer>::type, my_producer &>::value ));
-
- const volatile my_producer cp(p);
-
- BOOST_CHECK_EQUAL(&cp, (&df::get_port<my_mechanism, df::ports::producer>(cp)));
- BOOST_CHECK(( boost::is_same<df::get_port_result_type<my_mechanism, df::ports::producer, const volatile my_producer>::type, const volatile my_producer &>::value ));
-
+
     // check registrations
     //[ port_registration_check_example
- BOOST_CHECK(( df::is_port<some_mechanism, df::ports::producer, intrusive_producer_port>::value ));
-
- BOOST_CHECK(( df::is_port<some_mechanism, df::ports::producer, intrusive_producer_consumer_port>::value ));
- BOOST_CHECK(( df::is_port<some_mechanism, df::ports::consumer, intrusive_producer_consumer_port>::value ));
+ BOOST_CHECK(( df::is_port<intrusive_producer_port>::value ));
     
- BOOST_CHECK(( df::is_port<some_mechanism, df::ports::producer, non_intrusive_port>::value ));
+ BOOST_CHECK(( df::is_port<intrusive_producer_consumer_port, some_tag>::value ));
+
+ BOOST_CHECK(( df::is_port<non_intrusive_port>::value ));
 
- BOOST_CHECK(( df::is_port<some_mechanism, df::ports::producer, non_intrusive_port2>::value ));
+ BOOST_CHECK(( df::is_port<non_intrusive_port2>::value ));
     
- BOOST_CHECK(( df::is_port<some_mechanism, df::ports::producer, non_intrusive_port_descendant>::value ));
+ BOOST_CHECK(( df::is_port<non_intrusive_port_descendant>::value ));
 
- BOOST_CHECK(( df::is_port<some_mechanism, df::ports::producer, non_intrusive_port_descendant2>::value ));
+ BOOST_CHECK(( df::is_port<non_intrusive_port_descendant2>::value ));
+
+ BOOST_CHECK(( df::has_default_port<my_producer, whatever, whatever>::value ));
+ BOOST_CHECK_EQUAL(( &df::get_default_port<whatever, whatever, df::default_tag>(p)), &p );
     //]
     return 0;
 } // int test_main(int, char* [])

Modified: sandbox/SOC/2007/signals/libs/dataflow/test/test_reflective_component.cpp
==============================================================================
--- sandbox/SOC/2007/signals/libs/dataflow/test/test_reflective_component.cpp (original)
+++ sandbox/SOC/2007/signals/libs/dataflow/test/test_reflective_component.cpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -31,7 +31,7 @@
 namespace boost { namespace dataflow { namespace extension {
 
 template<>
-struct get_component_port_impl<my_component_traits>
+struct get_port_impl<my_component_traits>
 {
     template<typename FArgs> struct result;
 
@@ -72,8 +72,8 @@
 {
     my_component c;
     
- my_consumer &cc = df::get_component_port<boost::mpl::int_<0> >(c);
- my_producer &cp = df::get_component_port<boost::mpl::int_<1> >(c);
+ my_consumer &cc = df::get_port<boost::mpl::int_<0> >(c);
+ my_producer &cp = df::get_port<boost::mpl::int_<1> >(c);
     
     BOOST_CHECK_EQUAL(&cc, &c.consumer);
     BOOST_CHECK_EQUAL(&cp, &c.producer);

Modified: sandbox/SOC/2007/signals/libs/dataflow/test/test_unary_op.cpp
==============================================================================
--- sandbox/SOC/2007/signals/libs/dataflow/test/test_unary_op.cpp (original)
+++ sandbox/SOC/2007/signals/libs/dataflow/test/test_unary_op.cpp 2007-12-04 01:17:07 EST (Tue, 04 Dec 2007)
@@ -11,10 +11,12 @@
 namespace boost { namespace dataflow { namespace extension {
 
 template<>
-struct unary_operation_impl<operations::disconnect_all, my_producer_traits>
+struct unary_operation_impl<my_producer_traits, operations::disconnect_all>
 {
- template<typename Producer>
- void operator()(Producer &)
+ typedef void result_type;
+
+ template<typename Port>
+ void operator()(Port &)
     {
         disconnected = true;
     }
@@ -29,10 +31,15 @@
 int test_main(int, char* [])
 {
     my_producer p;
+ my_consumer c;
+
+ BOOST_CHECK((df::is_unary_operable<my_producer, df::operations::disconnect_all>::value));
     
- df::unary_operation<df::operations::disconnect_all, my_mechanism, df::ports::producer>(p);
+ df::unary_operation<df::operations::disconnect_all, df::default_tag>(p);
     BOOST_CHECK(disconnected);
     
+ BOOST_CHECK((!df::is_unary_operable<my_consumer, df::operations::disconnect_all>::value));
+
     return 0;
 } // int test_main(int, char* [])
 


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