Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r49676 - in sandbox/dataflow-rewrite: . boost/dataflow/blueprint boost/dataflow/generic boost/dataflow/generic/static_vector boost/dataflow/utility boost/dataflow/vivid boost/functional libs/dataflow/build/xcodeide/dataflow.xcodeproj libs/dataflow/doc libs/dataflow/example libs/dataflow/example/generic libs/dataflow/example/vivid libs/dataflow/test libs/dataflow/test/blueprint libs/dataflow/test/generic libs/dataflow/test/vivid
From: stipe_at_[hidden]
Date: 2008-11-10 13:28:50


Author: srajko
Date: 2008-11-10 13:28:46 EST (Mon, 10 Nov 2008)
New Revision: 49676
URL: http://svn.boost.org/trac/boost/changeset/49676

Log:
addded Dataflow.Vivid, static_vector, graph examples
Added:
   sandbox/dataflow-rewrite/boost/dataflow/blueprint/factory.hpp (contents, props changed)
      - copied, changed from r48363, /sandbox/SOC/2007/signals/boost/dataflow/blueprint/component_bank.hpp
   sandbox/dataflow-rewrite/boost/dataflow/blueprint/framework_object_fwd.hpp (contents, props changed)
   sandbox/dataflow-rewrite/boost/dataflow/generic/fusion_static_vector.hpp (contents, props changed)
      - copied, changed from r48363, /sandbox/SOC/2007/signals/boost/dataflow/support/fusion_port_vector.hpp
   sandbox/dataflow-rewrite/boost/dataflow/generic/port.hpp (contents, props changed)
   sandbox/dataflow-rewrite/boost/dataflow/generic/static_vector/
   sandbox/dataflow-rewrite/boost/dataflow/generic/static_vector.hpp (contents, props changed)
      - copied, changed from r48363, /sandbox/SOC/2007/signals/boost/dataflow/support/port_vector.hpp
   sandbox/dataflow-rewrite/boost/dataflow/generic/static_vector/get_port.hpp (contents, props changed)
   sandbox/dataflow-rewrite/boost/dataflow/generic/static_vector/static_vector.hpp (contents, props changed)
   sandbox/dataflow-rewrite/boost/dataflow/generic/static_vector/traits.hpp (contents, props changed)
   sandbox/dataflow-rewrite/boost/dataflow/utility/forced_sequence.hpp (contents, props changed)
      - copied, changed from r48363, /sandbox/SOC/2007/signals/boost/dataflow/utility/forced_sequence.hpp
   sandbox/dataflow-rewrite/boost/dataflow/vivid/
   sandbox/dataflow-rewrite/boost/dataflow/vivid/blueprint_component.hpp (props changed)
      - copied unchanged from r48363, /sandbox/SOC/2007/signals/libs/dataflow/example/glv_gui/blueprint_component.hpp
   sandbox/dataflow-rewrite/boost/dataflow/vivid/entity_widget.hpp (contents, props changed)
   sandbox/dataflow-rewrite/boost/dataflow/vivid/factory_window.hpp (contents, props changed)
      - copied, changed from r48363, /sandbox/SOC/2007/signals/libs/dataflow/example/glv_gui/blueprint_bank.hpp
   sandbox/dataflow-rewrite/boost/dataflow/vivid/network_window.hpp (contents, props changed)
      - copied, changed from r48363, /sandbox/SOC/2007/signals/libs/dataflow/example/glv_gui/blueprint_window.hpp
   sandbox/dataflow-rewrite/boost/functional/ (props changed)
      - copied from r48363, /sandbox/SOC/2007/signals/boost/functional/
   sandbox/dataflow-rewrite/libs/dataflow/example/Jamfile (contents, props changed)
   sandbox/dataflow-rewrite/libs/dataflow/example/generic/
   sandbox/dataflow-rewrite/libs/dataflow/example/generic/Jamfile (contents, props changed)
   sandbox/dataflow-rewrite/libs/dataflow/example/generic/graph_example.cpp (contents, props changed)
   sandbox/dataflow-rewrite/libs/dataflow/example/generic/graph_framework.hpp (contents, props changed)
   sandbox/dataflow-rewrite/libs/dataflow/example/vivid/
   sandbox/dataflow-rewrite/libs/dataflow/example/vivid/Jamfile (contents, props changed)
   sandbox/dataflow-rewrite/libs/dataflow/example/vivid/vivid_graph_example.cpp (contents, props changed)
   sandbox/dataflow-rewrite/libs/dataflow/test/blueprint/test_factory.cpp (contents, props changed)
   sandbox/dataflow-rewrite/libs/dataflow/test/generic/my_framework_with_object.hpp (contents, props changed)
   sandbox/dataflow-rewrite/libs/dataflow/test/generic/my_static_vector.hpp (contents, props changed)
   sandbox/dataflow-rewrite/libs/dataflow/test/generic/test_get_port.cpp (contents, props changed)
   sandbox/dataflow-rewrite/libs/dataflow/test/generic/test_static_vector.cpp (contents, props changed)
   sandbox/dataflow-rewrite/libs/dataflow/test/vivid/
   sandbox/dataflow-rewrite/libs/dataflow/test/vivid/Jamfile (contents, props changed)
   sandbox/dataflow-rewrite/libs/dataflow/test/vivid/test_factory_window.cpp (contents, props changed)
Text files modified:
   sandbox/dataflow-rewrite/Jamroot | 25 +++++
   sandbox/dataflow-rewrite/boost/dataflow/blueprint/castable_polymorphic_object.hpp | 23 ++++-
   sandbox/dataflow-rewrite/boost/dataflow/blueprint/factory.hpp | 52 ++++++-----
   sandbox/dataflow-rewrite/boost/dataflow/blueprint/framework.hpp | 9 +
   sandbox/dataflow-rewrite/boost/dataflow/blueprint/framework_entity.hpp | 15 +-
   sandbox/dataflow-rewrite/boost/dataflow/blueprint/framework_entity_adapter.hpp | 49 +++++++++-
   sandbox/dataflow-rewrite/boost/dataflow/blueprint/framework_object.hpp | 65 ++++++++++++++
   sandbox/dataflow-rewrite/boost/dataflow/blueprint/operation.hpp | 17 ---
   sandbox/dataflow-rewrite/boost/dataflow/blueprint/operation_adapter.hpp | 2
   sandbox/dataflow-rewrite/boost/dataflow/blueprint/port.hpp | 5
   sandbox/dataflow-rewrite/boost/dataflow/blueprint/port_adapter.hpp | 12 +-
   sandbox/dataflow-rewrite/boost/dataflow/blueprint/port_binary_operation.hpp | 15 ++-
   sandbox/dataflow-rewrite/boost/dataflow/blueprint/port_binary_operation_implementation.hpp | 4
   sandbox/dataflow-rewrite/boost/dataflow/blueprint/port_binary_operation_implementation_adapter.hpp | 46 ++++++++++
   sandbox/dataflow-rewrite/boost/dataflow/generic/framework.hpp | 29 +++++-
   sandbox/dataflow-rewrite/boost/dataflow/generic/fusion_static_vector.hpp | 18 ++-
   sandbox/dataflow-rewrite/boost/dataflow/generic/static_vector.hpp | 122 ++--------------------------
   sandbox/dataflow-rewrite/boost/dataflow/utility/forced_sequence.hpp | 20 +++-
   sandbox/dataflow-rewrite/boost/dataflow/vivid/factory_window.hpp | 92 +++++++++++++--------
   sandbox/dataflow-rewrite/boost/dataflow/vivid/network_window.hpp | 170 +++++++++++++++++++++++++++++++--------
   sandbox/dataflow-rewrite/libs/dataflow/build/xcodeide/dataflow.xcodeproj/project.pbxproj | 111 ++++++++++++++++++++++++++
   sandbox/dataflow-rewrite/libs/dataflow/doc/dataflow.qbk | 2
   sandbox/dataflow-rewrite/libs/dataflow/test/Jamfile | 5 +
   sandbox/dataflow-rewrite/libs/dataflow/test/blueprint/Jamfile | 1
   sandbox/dataflow-rewrite/libs/dataflow/test/blueprint/my_blueprint_framework.hpp | 2
   sandbox/dataflow-rewrite/libs/dataflow/test/blueprint/test_framework_entity.cpp | 6
   sandbox/dataflow-rewrite/libs/dataflow/test/blueprint/test_framework_object.cpp | 28 ++++++
   sandbox/dataflow-rewrite/libs/dataflow/test/blueprint/test_operation.cpp | 3
   sandbox/dataflow-rewrite/libs/dataflow/test/blueprint/test_port.cpp | 7
   sandbox/dataflow-rewrite/libs/dataflow/test/blueprint/test_port_binary_operation.cpp | 10 +
   sandbox/dataflow-rewrite/libs/dataflow/test/blueprint/test_port_binary_operation_implementation.cpp | 38 ++++++++
   sandbox/dataflow-rewrite/libs/dataflow/test/generic/Jamfile | 3
   sandbox/dataflow-rewrite/libs/dataflow/test/generic/test_framework.cpp | 9 ++
   33 files changed, 715 insertions(+), 300 deletions(-)

Modified: sandbox/dataflow-rewrite/Jamroot
==============================================================================
--- sandbox/dataflow-rewrite/Jamroot (original)
+++ sandbox/dataflow-rewrite/Jamroot 2008-11-10 13:28:46 EST (Mon, 10 Nov 2008)
@@ -31,4 +31,27 @@
     : requirements
         <include>.
         <include>$(BOOST_ROOT)
- ;
\ No newline at end of file
+ ;
+
+local build-if ;
+
+if ! [ os.environ GUIGL_ROOT ]
+{
+ ECHO "note: -------------------------------------------------------" ;
+ ECHO "note: Dataflow.Vivid tests and examples will be skipped." ;
+ ECHO "note: to build them examples, set the environment variable" ;
+ ECHO "note: GUIGL_ROOT to the location of the guigl library root." ;
+ ECHO "note: -------------------------------------------------------" ;
+ constant guigl_present : false ;
+}
+else
+{
+ path-constant GUIGL_ROOT : [ os.environ GUIGL_ROOT ] ;
+
+ use-project /boost_guigl
+ : $(GUIGL_ROOT)/libs/guigl/build
+ ;
+
+ constant guigl_present : true ;
+}
+

Modified: sandbox/dataflow-rewrite/boost/dataflow/blueprint/castable_polymorphic_object.hpp
==============================================================================
--- sandbox/dataflow-rewrite/boost/dataflow/blueprint/castable_polymorphic_object.hpp (original)
+++ sandbox/dataflow-rewrite/boost/dataflow/blueprint/castable_polymorphic_object.hpp 2008-11-10 13:28:46 EST (Mon, 10 Nov 2008)
@@ -11,6 +11,9 @@
 
 
 #include <typeinfo>
+#include <boost/utility/enable_if.hpp>
+#include <boost/type_traits/is_const.hpp>
+#include <boost/type_traits/remove_const.hpp>
 
 
 namespace boost { namespace dataflow { namespace blueprint {
@@ -18,19 +21,27 @@
 class castable_polymorphic_object
 {
 public:
- template<typename T>
- castable_polymorphic_object(const T &t)
- : m_type_info(typeid(t))
+ castable_polymorphic_object(const std::type_info &ti)
+ : m_type_info(ti)
     {}
     virtual ~castable_polymorphic_object()
     {}
+
+ template<typename T>
+ typename disable_if<is_const<T>, T &>::type get_as()
+ { return *reinterpret_cast<T *>(get_ptr()); }
+
     template<typename T>
- const T &get_as() const
- { return *reinterpret_cast<const T *>(get_ptr()); }
+ typename enable_if<is_const<T>, const T &>::type get_as() const
+ {
+ return *reinterpret_cast<typename remove_const<T>::type *>(
+ const_cast<castable_polymorphic_object *>(this)->get_ptr());
+ }
+
     const std::type_info &type_info() const
     { return m_type_info; }
 private:
- virtual const void * get_ptr() const = 0;
+ virtual void * get_ptr() = 0;
     const std::type_info &m_type_info;
 };
 

Copied: sandbox/dataflow-rewrite/boost/dataflow/blueprint/factory.hpp (from r48363, /sandbox/SOC/2007/signals/boost/dataflow/blueprint/component_bank.hpp)
==============================================================================
--- /sandbox/SOC/2007/signals/boost/dataflow/blueprint/component_bank.hpp (original)
+++ sandbox/dataflow-rewrite/boost/dataflow/blueprint/factory.hpp 2008-11-10 13:28:46 EST (Mon, 10 Nov 2008)
@@ -1,16 +1,21 @@
-// 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)
+/*=================================---------------------------------------------
+ Copyright 2007,2008 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_BLUEPRINT_COMPONENT_BANK_HPP
-#define BOOST_DATAFLOW_BLUEPRINT_COMPONENT_BANK_HPP
+#ifndef BOOST__DATAFLOW__BLUEPRINT__FACTORY_HPP
+#define BOOST__DATAFLOW__BLUEPRINT__FACTORY_HPP
 
-#include <boost/dataflow/blueprint/component.hpp>
+
+#include <boost/dataflow/blueprint/port_adapter.hpp>
 
 #include <boost/bind.hpp>
 #include <boost/function.hpp>
 #include <boost/functional/factory.hpp>
+#include <boost/iterator/iterator_adaptor.hpp>
 
 #include <map>
 #include <memory>
@@ -42,43 +47,44 @@
     friend class boost::iterator_core_access;
 };
 
-class component_bank
+template<typename BlueprintFramework>
+class factory
 {
- typedef std::map<std::string, boost::function<component * ()> > map_type;
+ typedef typename BlueprintFramework::framework_type framework_type;
+ typedef framework_entity<BlueprintFramework> entity_type;
+ typedef boost::function<entity_type * (framework_object<BlueprintFramework> &)> function_type;
+ typedef std::map<std::string, function_type> map_type;
 public:
     typedef key_iterator<map_type> iterator;
     
- std::auto_ptr<component> make(const std::string &key)
+ std::auto_ptr<entity_type> make(const std::string &key)
     {
- std::auto_ptr<component> ret(m_components[key]());
+ std::auto_ptr<entity_type> ret(m_components[key]());
         return ret;
     }
     key_iterator<map_type> begin()
     { return key_iterator<map_type>(m_components.begin()); }
     key_iterator<map_type> end()
     { return key_iterator<map_type>(m_components.end()); }
- boost::function<component * ()> operator[](const std::string& k)
+ function_type operator[](const std::string& k)
     { return m_components[k]; }
-protected:
- map_type m_components;
-};
 
-template<typename Tag>
-class tag_component_bank : public component_bank
-{
-public:
     template<typename T>
- void add_component(const std::string &s)
+ void add_port(const std::string &s)
     {
- m_components[s] = boost::factory<component_t<T, Tag> *>();
+ m_components[s] = boost::bind(boost::factory<port_adapter<BlueprintFramework, T> *>(), _1);
     }
     template<typename T, typename T0>
- void add_component(const std::string &s, const T0 &t0)
+ void add_port(const std::string &s, const T0 &t0)
     {
- m_components[s] = boost::bind(boost::factory<component_t<T, Tag> *>(), t0);
+ m_components[s] = boost::bind(boost::factory<port_adapter<BlueprintFramework, T> *>(), _1, t0);
     }
+
+protected:
+ map_type m_components;
 };
 
+
 } } } // namespace boost::dataflow::blueprint
 
 #endif // BOOST_DATAFLOW_BLUEPRINT_COMPONENT_BANK_HPP

Modified: sandbox/dataflow-rewrite/boost/dataflow/blueprint/framework.hpp
==============================================================================
--- sandbox/dataflow-rewrite/boost/dataflow/blueprint/framework.hpp (original)
+++ sandbox/dataflow-rewrite/boost/dataflow/blueprint/framework.hpp 2008-11-10 13:28:46 EST (Mon, 10 Nov 2008)
@@ -10,18 +10,21 @@
 #define BOOST__DATAFLOW__BLUEPRINT__FRAMEWORK_HPP
 
 
+#include <boost/dataflow/blueprint/framework_object_fwd.hpp>
+#include <boost/dataflow/blueprint/operation.hpp>
+#include <boost/dataflow/generic/framework.hpp>
 #include <boost/mpl/bool.hpp>
+#include <boost/mpl/transform.hpp>
 
 
 namespace boost { namespace dataflow { namespace blueprint {
 
-template<typename BlueprintFramework>
-class framework_object;
-
 template<typename Framework> struct framework : public Framework
 {
     typedef Framework framework_type;
     typedef framework_object<Framework> framework_object_type;
+ typedef typename has_framework_object<Framework>::type framework_has_object;
+ typedef mpl::vector<operation> operations;
 };
 
 

Modified: sandbox/dataflow-rewrite/boost/dataflow/blueprint/framework_entity.hpp
==============================================================================
--- sandbox/dataflow-rewrite/boost/dataflow/blueprint/framework_entity.hpp (original)
+++ sandbox/dataflow-rewrite/boost/dataflow/blueprint/framework_entity.hpp 2008-11-10 13:28:46 EST (Mon, 10 Nov 2008)
@@ -11,27 +11,28 @@
 
 
 #include <boost/dataflow/blueprint/castable_polymorphic_object.hpp>
-
+#include <boost/dataflow/blueprint/framework_object_fwd.hpp>
 
 namespace boost { namespace dataflow { namespace blueprint {
 
 template<typename BlueprintFramework>
 class framework_entity : public castable_polymorphic_object
 {
+ typedef framework_object<BlueprintFramework> framework_object_type;
 public:
     struct dataflow_traits
     {
         typedef BlueprintFramework framework;
     };
     
- template<typename Entity>
- framework_entity(const Entity &entity)
- : castable_polymorphic_object(entity)
- {}
- virtual ~framework_entity()
+ framework_entity(framework_object<BlueprintFramework> &fo, const std::type_info &ti)
+ : castable_polymorphic_object(ti)
+ , m_framework_object(fo)
     {}
+ framework_object_type &framework_object()
+ { return m_framework_object; }
 private:
- virtual const void *get_ptr() const=0;
+ framework_object_type &m_framework_object;
 };
 
 } } } // namespace boost::dataflow::blueprint

Modified: sandbox/dataflow-rewrite/boost/dataflow/blueprint/framework_entity_adapter.hpp
==============================================================================
--- sandbox/dataflow-rewrite/boost/dataflow/blueprint/framework_entity_adapter.hpp (original)
+++ sandbox/dataflow-rewrite/boost/dataflow/blueprint/framework_entity_adapter.hpp 2008-11-10 13:28:46 EST (Mon, 10 Nov 2008)
@@ -11,31 +11,64 @@
 
 
 #include <boost/dataflow/blueprint/framework_entity.hpp>
+#include <boost/dataflow/blueprint/framework_object.hpp>
 #include <boost/type_traits/remove_reference.hpp>
+#include <boost/utility/enable_if.hpp>
 
 
 namespace boost { namespace dataflow { namespace blueprint {
 
-template<typename BlueprintFramework, typename EntityOrRef, typename Base=framework_entity<BlueprintFramework> >
+template<typename BlueprintFramework, typename EntityOrRef, typename Base=framework_entity<BlueprintFramework>, typename Enable=void >
 class framework_entity_adapter : public Base
 {
 public:
     typedef typename remove_reference<EntityOrRef>::type entity_type;
- framework_entity_adapter()
- : Base(EntityOrRef())
+
+ framework_entity_adapter(framework_object<BlueprintFramework> &fo)
+ : Base(fo, typeid(m_entity))
     {}
     template<typename T>
- framework_entity_adapter(const T &t)
- : Base(t)
+ framework_entity_adapter(framework_object<BlueprintFramework> &fo, const T &t)
+ : Base(fo, typeid(m_entity))
         , m_entity(t)
     {}
     template<typename T>
- framework_entity_adapter(T &t)
- : Base(t)
+ framework_entity_adapter(framework_object<BlueprintFramework> &fo, T &t)
+ : Base(fo, typeid(m_entity))
         , m_entity(t)
     {}
 private:
- virtual const void *get_ptr() const
+ virtual void *get_ptr()
+ {
+ return &m_entity;
+ };
+ EntityOrRef m_entity;
+};
+
+template<typename BlueprintFramework, typename EntityOrRef, typename Base>
+class framework_entity_adapter<BlueprintFramework, EntityOrRef, Base,
+ typename enable_if<typename BlueprintFramework::framework_has_object>::type>
+ : public Base
+{
+public:
+ typedef typename remove_reference<EntityOrRef>::type entity_type;
+
+ framework_entity_adapter(framework_object<BlueprintFramework> &fo)
+ : Base(fo, typeid(m_entity))
+ , m_entity(fo.object())
+ {}
+ template<typename T>
+ framework_entity_adapter(framework_object<BlueprintFramework> &fo, const T &t)
+ : Base(fo, typeid(m_entity))
+ , m_entity(t)
+ {}
+ template<typename T>
+ framework_entity_adapter(framework_object<BlueprintFramework> &fo, T &t)
+ : Base(fo, typeid(m_entity))
+ , m_entity(t)
+ {}
+private:
+ virtual void *get_ptr()
     {
         return &m_entity;
     };

Modified: sandbox/dataflow-rewrite/boost/dataflow/blueprint/framework_object.hpp
==============================================================================
--- sandbox/dataflow-rewrite/boost/dataflow/blueprint/framework_object.hpp (original)
+++ sandbox/dataflow-rewrite/boost/dataflow/blueprint/framework_object.hpp 2008-11-10 13:28:46 EST (Mon, 10 Nov 2008)
@@ -11,6 +11,9 @@
 
 #include <map>
 #include <typeinfo>
+#include <boost/dataflow/blueprint/framework_object_fwd.hpp>
+#include <boost/dataflow/blueprint/port_binary_operation_implementation_adapter.hpp>
+#include <boost/shared_ptr.hpp>
 
 namespace boost { namespace dataflow { namespace blueprint {
 
@@ -20,6 +23,14 @@
     port_binary_operation_key()
     {}
 public:
+ template<typename Port1, typename Port2>
+ port_binary_operation_key(Port1 &port1, Port2 &port2, const operation &op)
+ {
+ m_type_info[0] = &port1.type_info();
+ m_type_info[1] = &port2.type_info();
+ m_type_info[2] = &op.type_info();
+ }
+public:
     bool operator == (const port_binary_operation_key &rhs) const
     {
         for(int i=0; i<3; i++)
@@ -55,14 +66,23 @@
 };
 
 template<typename BlueprintFramework>
-class framework_object
+class framework_object_base
 {
+ BOOST_MPL_ASSERT((is_blueprint_framework<BlueprintFramework>));
+
+ typedef shared_ptr<port_binary_operation_implementation<BlueprintFramework> > implementation_ptr;
+ typedef port<BlueprintFramework> port_type;
 public:
+ bool operator == (const framework_object_base &rhs) const
+ {
+ return this == &rhs;
+ }
     template<typename Port1, typename Port2, typename Operation>
     void register_operation()
     {
         port_binary_operation_key key = construct_port_binary_operation_key<Port1,Port2,Operation>();
- m_operation_implementations[key] = 1;
+ m_operation_implementations[key] = implementation_ptr(
+ new port_binary_operation_implementation_adapter<Port1,Port2,Operation,BlueprintFramework>);
     }
     template<typename Port1, typename Port2, typename Operation>
     bool has_registered_operation() const
@@ -70,10 +90,49 @@
         port_binary_operation_key key = construct_port_binary_operation_key<Port1,Port2,Operation>();
         return m_operation_implementations.find(key) != m_operation_implementations.end();
     }
+ boost::any port_binary_operation(port_type &port1, port_type &port2, const blueprint::operation &op)
+ {
+ port_binary_operation_key key(port1, port2, op);
+ typename operation_implementations_type::iterator it = m_operation_implementations.find(key);
+ if (it == m_operation_implementations.end())
+ return boost::any();
+ return it->second->invoke(port1, port2, op);
+ }
+ bool port_binary_operation_will_succeed(port_type &port1, port_type &port2, const blueprint::operation &op)
+ {
+ port_binary_operation_key key(port1, port2, op);
+ typename operation_implementations_type::iterator it = m_operation_implementations.find(key);
+ if (it == m_operation_implementations.end())
+ return false;
+ return it->second->will_succeed(port1, port2, op);
+ }
 private:
- std::map<port_binary_operation_key, int> m_operation_implementations;
+ typedef std::map<port_binary_operation_key, implementation_ptr> operation_implementations_type;
+ std::map<port_binary_operation_key, implementation_ptr> m_operation_implementations;
 };
 
+
+template<typename BlueprintFramework, typename Enable>
+class framework_object
+ : public framework_object_base<BlueprintFramework>
+{};
+
+template<typename BlueprintFramework>
+class framework_object<BlueprintFramework,
+ typename boost::enable_if<has_framework_object<typename BlueprintFramework::framework_type> >::type>
+ : public framework_object_base<BlueprintFramework>
+{
+ typedef typename BlueprintFramework::framework_type::framework_object_type object_type;
+public:
+ object_type &object()
+ { return m_object; }
+ const object_type &object() const
+ { return m_object; }
+private:
+ object_type m_object;
+};
+
+
 } } } // namespace boost::dataflow::blueprint
 
 

Added: sandbox/dataflow-rewrite/boost/dataflow/blueprint/framework_object_fwd.hpp
==============================================================================
--- (empty file)
+++ sandbox/dataflow-rewrite/boost/dataflow/blueprint/framework_object_fwd.hpp 2008-11-10 13:28:46 EST (Mon, 10 Nov 2008)
@@ -0,0 +1,19 @@
+/*=================================---------------------------------------------
+ Copyright 2007,2008 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__BLUEPRINT__FRAMEWORK_OBJECT_FWD_HPP
+#define BOOST__DATAFLOW__BLUEPRINT__FRAMEWORK_OBJECT_FWD_HPP
+
+namespace boost { namespace dataflow { namespace blueprint {
+
+template<typename BlueprintFramework, typename Enable=void>
+class framework_object;
+
+} } }
+
+#endif

Modified: sandbox/dataflow-rewrite/boost/dataflow/blueprint/operation.hpp
==============================================================================
--- sandbox/dataflow-rewrite/boost/dataflow/blueprint/operation.hpp (original)
+++ sandbox/dataflow-rewrite/boost/dataflow/blueprint/operation.hpp 2008-11-10 13:28:46 EST (Mon, 10 Nov 2008)
@@ -10,31 +10,20 @@
 #define BOOST__DATAFLOW__BLUEPRINT__OPERATION_HPP
 
 
+#include <boost/dataflow/blueprint/castable_polymorphic_object.hpp>
 #include <boost/dataflow/generic/operation.hpp>
 #include <typeinfo>
 
 
 namespace boost { namespace dataflow { namespace blueprint {
 
-class operation : public dataflow::operation<semantics::unknown>
+class operation : public castable_polymorphic_object, public dataflow::operation<semantics::unknown>
 {
 public:
     template<typename Operation>
     operation(const Operation &operation)
- : m_type_info(typeid(operation))
+ : castable_polymorphic_object(typeid(operation))
     {}
- virtual ~operation()
- {}
- template<typename Operation>
- const Operation &get_as() const
- {
- return *reinterpret_cast<const Operation *>(get_ptr());
- }
- const std::type_info &type_info() const
- { return m_type_info; }
-private:
- virtual const void * get_ptr() const = 0;
- const std::type_info &m_type_info;
 };
 
 

Modified: sandbox/dataflow-rewrite/boost/dataflow/blueprint/operation_adapter.hpp
==============================================================================
--- sandbox/dataflow-rewrite/boost/dataflow/blueprint/operation_adapter.hpp (original)
+++ sandbox/dataflow-rewrite/boost/dataflow/blueprint/operation_adapter.hpp 2008-11-10 13:28:46 EST (Mon, 10 Nov 2008)
@@ -24,7 +24,7 @@
         , m_operation(op)
     {}
 private:
- virtual const void * get_ptr() const
+ virtual void * get_ptr()
     {
         return &m_operation;
     };

Modified: sandbox/dataflow-rewrite/boost/dataflow/blueprint/port.hpp
==============================================================================
--- sandbox/dataflow-rewrite/boost/dataflow/blueprint/port.hpp (original)
+++ sandbox/dataflow-rewrite/boost/dataflow/blueprint/port.hpp 2008-11-10 13:28:46 EST (Mon, 10 Nov 2008)
@@ -20,9 +20,8 @@
 {
     typedef framework_entity<BlueprintFramework> base_type;
 public:
- template<typename T>
- port(const T &t)
- : base_type(t)
+ port(framework_object<BlueprintFramework> &fo, const std::type_info &ti)
+ : base_type(fo, ti)
     {}
     struct dataflow_traits : public base_type::dataflow_traits
     {

Modified: sandbox/dataflow-rewrite/boost/dataflow/blueprint/port_adapter.hpp
==============================================================================
--- sandbox/dataflow-rewrite/boost/dataflow/blueprint/port_adapter.hpp (original)
+++ sandbox/dataflow-rewrite/boost/dataflow/blueprint/port_adapter.hpp 2008-11-10 13:28:46 EST (Mon, 10 Nov 2008)
@@ -21,15 +21,17 @@
 {
     typedef framework_entity_adapter<BlueprintFramework, PortOrRef, Base> base_type;
 public:
- port_adapter()
+ port_adapter(framework_object<BlueprintFramework> &fo)
+ : base_type(fo)
+
     {}
     template<typename T>
- port_adapter(const T &t)
- : base_type(t)
+ port_adapter(framework_object<BlueprintFramework> &fo, const T &t)
+ : base_type(fo, t)
     {}
     template<typename T>
- port_adapter(T &t)
- : base_type(t)
+ port_adapter(framework_object<BlueprintFramework> &fo, T &t)
+ : base_type(fo, t)
     {}
 };
 

Modified: sandbox/dataflow-rewrite/boost/dataflow/blueprint/port_binary_operation.hpp
==============================================================================
--- sandbox/dataflow-rewrite/boost/dataflow/blueprint/port_binary_operation.hpp (original)
+++ sandbox/dataflow-rewrite/boost/dataflow/blueprint/port_binary_operation.hpp 2008-11-10 13:28:46 EST (Mon, 10 Nov 2008)
@@ -13,8 +13,9 @@
 #include <boost/dataflow/generic/port_binary_operation.hpp>
 #include <boost/dataflow/generic/framework_entity/traits_of.hpp>
 #include <boost/dataflow/blueprint/framework.hpp>
+#include <boost/dataflow/blueprint/framework_object.hpp>
 #include <boost/dataflow/blueprint/operation.hpp>
-
+#include <boost/assert.hpp>
 
 namespace boost { namespace dataflow { namespace extension {
 
@@ -27,11 +28,14 @@
>
>::type>
 {
- typedef void result_type;
+ typedef boost::any result_type;
 
     template<typename Port1, typename Port2>
- void operator()(Port1 &port1, Port2 &port2, const blueprint::operation &operation)
- {}
+ boost::any operator()(Port1 &port1, Port2 &port2, const blueprint::operation &operation)
+ {
+ BOOST_ASSERT(port1.framework_object() == port2.framework_object());
+ return port1.framework_object().port_binary_operation(port1, port2, operation);
+ }
 };
 
 template<typename Traits1, typename Traits2>
@@ -48,7 +52,8 @@
     template<typename Port1, typename Port2>
     bool operator()(Port1 &port1, Port2 &port2, const blueprint::operation &operation)
     {
- return false;
+ BOOST_ASSERT(port1.framework_object() == port2.framework_object());
+ return port1.framework_object().port_binary_operation_will_succeed(port1, port2, operation);
     }
 };
 

Modified: sandbox/dataflow-rewrite/boost/dataflow/blueprint/port_binary_operation_implementation.hpp
==============================================================================
--- sandbox/dataflow-rewrite/boost/dataflow/blueprint/port_binary_operation_implementation.hpp (original)
+++ sandbox/dataflow-rewrite/boost/dataflow/blueprint/port_binary_operation_implementation.hpp 2008-11-10 13:28:46 EST (Mon, 10 Nov 2008)
@@ -15,7 +15,7 @@
 #include <boost/dataflow/blueprint/framework.hpp>
 #include <boost/dataflow/blueprint/port.hpp>
 #include <boost/dataflow/blueprint/operation.hpp>
-
+#include <boost/any.hpp>
 
 namespace boost { namespace dataflow { namespace blueprint {
 
@@ -24,7 +24,7 @@
 {
     typedef port<BlueprintFramework> port_type;
 public:
- virtual void invoke(port_type &port1, port_type &port2, const operation &op)=0;
+ virtual boost::any invoke(port_type &port1, port_type &port2, const operation &op)=0;
     virtual bool will_succeed(port_type &port1, port_type &port2, const operation &op)=0;
     virtual ~port_binary_operation_implementation() {};
 };

Modified: sandbox/dataflow-rewrite/boost/dataflow/blueprint/port_binary_operation_implementation_adapter.hpp
==============================================================================
--- sandbox/dataflow-rewrite/boost/dataflow/blueprint/port_binary_operation_implementation_adapter.hpp (original)
+++ sandbox/dataflow-rewrite/boost/dataflow/blueprint/port_binary_operation_implementation_adapter.hpp 2008-11-10 13:28:46 EST (Mon, 10 Nov 2008)
@@ -17,6 +17,41 @@
 
 namespace boost { namespace dataflow { namespace blueprint {
 
+namespace detail {
+
+template<typename Framework, typename Port1, typename Port2, typename Operation>
+typename enable_if<
+ is_same<
+ typename result_of::port_binary_operation<Port1, Port2, Operation, Framework, Framework>::type,
+ void>,
+ any>::type
+handle_result_type(Port1 &port1, Port2 &port2, const Operation &op)
+{
+ dataflow::port_binary_operation_framework
+ <Operation, Framework, Framework>(
+ port1,
+ port2,
+ op);
+ return boost::any();
+}
+
+template<typename Framework, typename Port1, typename Port2, typename Operation>
+typename disable_if<
+ is_same<
+ typename result_of::port_binary_operation<Port1, Port2, Operation, Framework, Framework>::type,
+ void>,
+ any>::type
+handle_result_type(Port1 &port1, Port2 &port2, const Operation &op)
+{
+ return dataflow::port_binary_operation_framework
+ <Operation, Framework, Framework>(
+ port1,
+ port2,
+ op);
+}
+
+}
+
 template<typename Port1, typename Port2, typename Operation, typename BlueprintFramework>
 class port_binary_operation_implementation_adapter
     : public port_binary_operation_implementation<BlueprintFramework>
@@ -24,10 +59,15 @@
     typedef typename BlueprintFramework::framework_type framework_type;
     typedef port<BlueprintFramework> port_type;
 public:
- virtual void invoke(port_type &port1, port_type &port2, const operation &op)
+ virtual boost::any invoke(port_type &port1, port_type &port2, const operation &op)
     {
         if(!check_types(port1, port2, op))
- return;
+ return boost::any();
+
+ return detail::handle_result_type<framework_type>(
+ port1.template get_as<Port1>(),
+ port2.template get_as<Port2>(),
+ op.template get_as<const Operation>());
     }
     virtual bool will_succeed(port_type &port1, port_type &port2, const operation &op)
     {
@@ -38,7 +78,7 @@
             <Operation, framework_type, framework_type>(
                 port1.template get_as<Port1>(),
                 port2.template get_as<Port2>(),
- op.template get_as<Operation>());
+ op.template get_as<const Operation>());
     }
 private:
     bool check_types(port_type &port1, port_type &port2, const operation &op)

Modified: sandbox/dataflow-rewrite/boost/dataflow/generic/framework.hpp
==============================================================================
--- sandbox/dataflow-rewrite/boost/dataflow/generic/framework.hpp (original)
+++ sandbox/dataflow-rewrite/boost/dataflow/generic/framework.hpp 2008-11-10 13:28:46 EST (Mon, 10 Nov 2008)
@@ -10,6 +10,9 @@
 #define BOOST__DATAFLOW__GENERIC__FRAMEWORK_HPP
 
 
+#include <boost/dataflow/generic/operation.hpp>
+#include <boost/dataflow/utility/enable_if_type.hpp>
+#include <boost/dataflow/utility/forced_sequence.hpp>
 #include <boost/mpl/bool.hpp>
 #include <boost/mpl/is_sequence.hpp>
 #include <boost/mpl/vector.hpp>
@@ -19,21 +22,28 @@
 namespace boost { namespace dataflow {
 
 
-template<typename ConnectOperations>
+template<typename Operations, typename FrameworkObject=void>
 struct framework
 {
- typedef ConnectOperations connect_operations;
+ typedef typename utility::forced_sequence<Operations>::type operations;
+ typedef FrameworkObject framework_object_type;
+};
+
+template<typename Operations>
+struct framework<Operations>
+{
+ typedef typename utility::forced_sequence<Operations>::type operations;
 };
 
 namespace operations {
 
-struct connect {};
+struct connect : public operation<semantics::connect> {};
 
 }
 
 /// The default Framework argument for Dataflow templates.
 struct default_framework
- : public framework<mpl::vector<operations::connect> >
+ : public framework<operations::connect>
 {};
 
 /// Boolean metafunction determining whether a type is a Framework.
@@ -43,9 +53,18 @@
 
 template<typename T>
 struct is_framework<T,
- typename enable_if<mpl::is_sequence<typename T::connect_operations> >::type>
+ typename enable_if<mpl::is_sequence<typename T::operations> >::type>
     : public mpl::true_ {};
 
+/// Boolean metafunction determining whether a type is a Framework.
+template<typename T, typename Enable=void>
+struct has_framework_object
+ : public mpl::false_ {};
+
+template<typename T>
+struct has_framework_object<T,
+ typename utility::enable_if_type<typename T::framework_object_type>::type>
+ : public mpl::true_ {};
 
 } } // namespace boost::dataflow
 

Copied: sandbox/dataflow-rewrite/boost/dataflow/generic/fusion_static_vector.hpp (from r48363, /sandbox/SOC/2007/signals/boost/dataflow/support/fusion_port_vector.hpp)
==============================================================================
--- /sandbox/SOC/2007/signals/boost/dataflow/support/fusion_port_vector.hpp (original)
+++ sandbox/dataflow-rewrite/boost/dataflow/generic/fusion_static_vector.hpp 2008-11-10 13:28:46 EST (Mon, 10 Nov 2008)
@@ -1,10 +1,14 @@
-// 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)
+/*=================================---------------------------------------------
+ Copyright 2007,2008 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_FUSION_PORT_VECTOR_HPP
-#define BOOST_DATAFLOW_SUPPORT_FUSION_PORT_VECTOR_HPP
+
+#ifndef BOOST__DATAFLOW__GENERIC__FUSION_STATIC_VECTOR_HPP
+#define BOOST__DATAFLOW__GENERIC__FUSION_STATIC_VECTOR_HPP
 
 #include <boost/dataflow/detail/transform_remove_reference.hpp>
 #include <boost/dataflow/support/port_vector.hpp>
@@ -65,4 +69,4 @@
 
 }}
 
-#endif // BOOST_DATAFLOW_SUPPORT_FUSION_PORT_VECTOR_HPP
+#endif // BOOST__DATAFLOW__GENERIC__FUSION_STATIC_VECTOR_HPP

Added: sandbox/dataflow-rewrite/boost/dataflow/generic/port.hpp
==============================================================================
--- (empty file)
+++ sandbox/dataflow-rewrite/boost/dataflow/generic/port.hpp 2008-11-10 13:28:46 EST (Mon, 10 Nov 2008)
@@ -0,0 +1,10 @@
+/*=================================---------------------------------------------
+ Copyright 2007,2008 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)
+-----------------------------------------------===============================*/
+
+
+#include <boost/dataflow/generic/port/port.hpp>

Copied: sandbox/dataflow-rewrite/boost/dataflow/generic/static_vector.hpp (from r48363, /sandbox/SOC/2007/signals/boost/dataflow/support/port_vector.hpp)
==============================================================================
--- /sandbox/SOC/2007/signals/boost/dataflow/support/port_vector.hpp (original)
+++ sandbox/dataflow-rewrite/boost/dataflow/generic/static_vector.hpp 2008-11-10 13:28:46 EST (Mon, 10 Nov 2008)
@@ -1,115 +1,11 @@
-// 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)
+/*=================================---------------------------------------------
+ Copyright 2007,2008 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_PORT_VECTOR_HPP
-#define BOOST_DATAFLOW_SUPPORT_PORT_VECTOR_HPP
 
-#include <boost/dataflow/support/traits.hpp>
-#include <boost/utility/result_of.hpp>
-#include <boost/mpl/is_sequence.hpp>
-#include <boost/static_assert.hpp>
-
-namespace boost { namespace dataflow {
-
-template<typename PortSequence, typename Tag=default_tag>
-struct port_vector_traits
- : public traits<Tag>
-{
- typedef PortSequence ports;
- BOOST_MPL_ASSERT(( mpl::is_sequence<PortSequence> ));
-};
-
-#ifndef DOXYGEN_DOCS_BUILD
-namespace extension {
-
- template<typename ComponentTraits, typename Enable=void>
- struct get_port_impl
- {
- BOOST_MPL_ASSERT((is_same<Enable, void>));
-
- typedef void result_type;
-
- typedef void not_specialized;
-
- template<typename Component, int N>
- void operator()(Component &, mpl::int_<N>)
- {
- // Error: get_port_impl has not been
- // implemented for ComponentTraits.
- BOOST_STATIC_ASSERT(sizeof(Component)==0);
- }
- };
-
-} // namespace extension
-
-namespace result_of
-{
- template<typename Component, int N, typename Tag=default_tag>
- struct get_port_c
- {
- typedef typename boost::result_of<
- extension::get_port_impl<
- typename traits_of<Component, Tag>::type
- >(Component &, mpl::int_<N>)>::type type;
- };
-
- template<typename Component, typename N, typename Tag=default_tag>
- struct get_port
- {
- typedef typename get_port_c<Component, N::value, Tag>::type type;
- };
-}
-
-template<int N, typename Tag, typename Component>
-inline typename result_of::get_port_c<Component, N, Tag>::type
-get_port_c(Component &component)
-{
- return
- extension::get_port_impl<
- typename traits_of<Component, Tag>::type
- >()(component, mpl::int_<N>());
-}
-
-template<int N, typename Component>
-inline typename lazy_enable_if<
- is_entity<Component>,
- result_of::get_port_c<Component, N>
->::type
-get_port_c(Component &component)
-{
- return
- extension::get_port_impl<
- typename traits_of<Component>::type
- >()(component, mpl::int_<N>());
-}
-
-template<typename N, typename Tag, typename Component>
-inline typename result_of::get_port<Component, N, Tag>::type
-get_port(Component &component)
-{
- return
- extension::get_port_impl<
- typename traits_of<Component, Tag>::type
- >()(component, mpl::int_<N::value>());
-}
-
-template<typename N, typename Component>
-inline typename lazy_enable_if<
- is_entity<Component>,
- result_of::get_port<Component, N>
->::type
-get_port(Component &component)
-{
- return
- extension::get_port_impl<
- typename traits_of<Component>::type
- >()(component, mpl::int_<N::value>());
-}
-
-#endif // DOXYGEN_DOCS_BUILD
-
-} } // namespace boost::dataflow
-
-#endif // BOOST_DATAFLOW_SUPPORT_COMPONENT_HPP
+#include <boost/dataflow/generic/static_vector/static_vector.hpp>
+#include <boost/dataflow/generic/static_vector/get_port.hpp>

Added: sandbox/dataflow-rewrite/boost/dataflow/generic/static_vector/get_port.hpp
==============================================================================
--- (empty file)
+++ sandbox/dataflow-rewrite/boost/dataflow/generic/static_vector/get_port.hpp 2008-11-10 13:28:46 EST (Mon, 10 Nov 2008)
@@ -0,0 +1,214 @@
+/*=================================---------------------------------------------
+ Copyright 2007,2008 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__GENERIC__GET_PORT_HPP
+#define BOOST__DATAFLOW__GENERIC__GET_PORT_HPP
+
+
+#include <boost/mpl/assert.hpp>
+#include <boost/utility/result_of.hpp>
+#include <boost/type_traits/is_same.hpp>
+#include <boost/dataflow/generic/framework_entity/default_framework_of.hpp>
+#include <boost/dataflow/generic/framework_entity/traits_of.hpp>
+#include <boost/dataflow/generic/framework_entity.hpp>
+namespace boost { namespace dataflow {
+
+namespace detail {
+
+ struct not_specialized
+ {};
+
+}
+
+namespace extension
+{
+ template<typename Traits1,typename Enable=void>
+ struct get_port_impl
+ {
+ BOOST_MPL_ASSERT(( is_same<Enable, void> ));
+
+ typedef detail::not_specialized result_type;
+
+ template<typename T1,typename Index>
+ result_type operator()(T1 &t1,const Index &index)
+ {
+ // Error: get_port_impl has not been
+ // specialized appropriately.
+ BOOST_MPL_ASSERT(( mpl::bool_<sizeof(T1)==0> ));
+ return result_type();
+ }
+ };
+
+ template<typename Traits1,typename Enable=void>
+ struct get_port_will_succeed_impl
+ {
+ BOOST_MPL_ASSERT(( is_same<Enable, void> ));
+
+ typedef bool result_type;
+
+ template<typename T1,typename Index>
+ result_type operator()(T1 &t1,const Index &index)
+ {
+ return
+ !is_same<
+ typename extension::get_port_impl<
+ Traits1
+ >::result_type,
+ detail::not_specialized
+ >::value;
+ }
+ };
+}
+
+namespace detail
+{
+
+ template<typename T1,typename Index,typename Framework1=typename default_framework_of<T1>::type,typename Enable=void>
+ struct has_ports_specialized
+ : public mpl::true_
+ {};
+
+ template<typename T1,typename Index,typename Framework1>
+ struct has_ports_specialized<
+ T1,Index,Framework1
+ ,
+ typename enable_if<
+ is_same<
+ typename extension::get_port_impl<
+ typename traits_of<T1, Framework1>::type
+ >::result_type,
+ detail::not_specialized>
+ >::type>
+ : public mpl::false_
+ {};
+
+}
+
+template<typename T1,typename Framework1=typename default_framework_of<T1>::type,typename Enable=void>
+struct has_ports
+ : public mpl::false_
+{
+ BOOST_MPL_ASSERT((mpl::and_<is_framework_entity<T1,Framework1> >));
+};
+
+template<typename T1,typename Framework1>
+struct has_ports<
+ T1,Framework1,
+ typename enable_if<
+ detail::has_ports_specialized<
+ T1,Framework1>
+ >::type>
+ : public mpl::true_
+{
+ BOOST_MPL_ASSERT((mpl::and_<is_framework_entity<T1,Framework1> >));
+};
+
+namespace result_of {
+
+ template<typename T1,typename Index,typename Framework1=typename default_framework_of<T1>::type>
+ struct get_port
+ {
+ typedef typename boost::result_of<
+ extension::get_port_impl<
+ typename traits_of<T1, Framework1>::type
+ >
+ (T1,Index)
+ >::type type;
+ };
+
+}
+
+
+template<typename Index,typename Framework1,typename T1>
+inline typename result_of::get_port<
+ T1,Index,Framework1
+ >::type
+get_port_framework(T1 &t1,const Index &index=Index())
+{
+ return extension::get_port_impl<
+ typename traits_of<T1, Framework1>::type
+ >()(t1,index);
+}
+
+template<typename Index,typename T1>
+inline typename result_of::get_port<
+ T1,Index,typename default_framework_of<T1>::type
+ >::type
+get_port(T1 &t1,const Index &index=Index())
+{
+ typedef typename default_framework_of<T1>::type Framework1;
+ return extension::get_port_impl<
+ typename traits_of<T1, Framework1>::type
+ >()(t1,index);
+}
+
+template<typename Index,typename Framework1,typename T1>
+inline bool
+get_port_will_succeed_framework(T1 &t1,const Index &index=Index())
+{
+ return extension::get_port_will_succeed_impl<
+ typename traits_of<T1, Framework1>::type
+ >()(t1,index);
+}
+
+template<typename Index,typename T1>
+inline bool
+get_port_will_succeed(T1 &t1,const Index &index=Index())
+{
+ typedef typename default_framework_of<T1>::type Framework1;
+ return extension::get_port_will_succeed_impl<
+ typename traits_of<T1, Framework1>::type
+ >()(t1,index);
+}
+
+template<typename Index,typename Framework1,typename T1>
+inline typename result_of::get_port<
+ T1,Index,Framework1
+ >::type
+get_port_framework(const T1 &t1,const Index &index=Index())
+{
+ return extension::get_port_impl<
+ typename traits_of<T1, Framework1>::type
+ >()(t1,index);
+}
+
+template<typename Index,typename T1>
+inline typename result_of::get_port<
+ T1,Index,typename default_framework_of<T1>::type
+ >::type
+get_port(const T1 &t1,const Index &index=Index())
+{
+ typedef typename default_framework_of<T1>::type Framework1;
+ return extension::get_port_impl<
+ typename traits_of<T1, Framework1>::type
+ >()(t1,index);
+}
+
+template<typename Index,typename Framework1,typename T1>
+inline bool
+get_port_will_succeed_framework(const T1 &t1,const Index &index=Index())
+{
+ return extension::get_port_will_succeed_impl<
+ typename traits_of<T1, Framework1>::type
+ >()(t1,index);
+}
+
+template<typename Index,typename T1>
+inline bool
+get_port_will_succeed(const T1 &t1,const Index &index=Index())
+{
+ typedef typename default_framework_of<T1>::type Framework1;
+ return extension::get_port_will_succeed_impl<
+ typename traits_of<T1, Framework1>::type
+ >()(t1,index);
+}
+
+}}
+
+
+#endif // BOOST__DATAFLOW__GENERIC__GET_PORT_HPP

Added: sandbox/dataflow-rewrite/boost/dataflow/generic/static_vector/static_vector.hpp
==============================================================================
--- (empty file)
+++ sandbox/dataflow-rewrite/boost/dataflow/generic/static_vector/static_vector.hpp 2008-11-10 13:28:46 EST (Mon, 10 Nov 2008)
@@ -0,0 +1,59 @@
+/*=================================---------------------------------------------
+ Copyright 2007,2008 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__GENERIC__STATIC_VECTOR__STATIC_VECTOR_HPP
+#define BOOST__DATAFLOW__GENERIC__STATIC_VECTOR__STATIC_VECTOR_HPP
+
+#include <boost/dataflow/generic/static_vector/traits.hpp>
+#include <boost/dataflow/generic/framework_entity/default_framework_of.hpp>
+#include <boost/dataflow/generic/framework_entity/traits_of.hpp>
+
+namespace boost { namespace dataflow {
+
+/// Boolean Metafunction determining whether a type is a Port.
+/** is_port<T, Framework> is an Integral Constant of type bool.
+ It evaluates to true if T models Port, false otherwise.
+*/
+template<typename T, typename Framework=typename default_framework_of<T>::type, typename Enable=void>
+struct is_static_vector
+ : public mpl::false_
+{
+#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 Framework>
+struct is_static_vector<
+ T,
+ Framework,
+ typename enable_if<
+ is_static_vector_traits<typename traits_of<T, Framework>::type>
+ >::type >
+ : public mpl::true_ {};
+
+/// Convenience base class for Port types.
+template<typename StaticVectorTraits>
+struct static_vector
+{
+ /// PortTraits for the Port.
+ typedef StaticVectorTraits dataflow_traits;
+ /// INTERNAL ONLY
+ BOOST_MPL_ASSERT(( is_static_vector_traits<StaticVectorTraits> ));
+};
+
+} } // namespace boost::dataflow
+
+#endif // BOOST__DATAFLOW__GENERIC__STATIC_VECTOR__STATIC_VECTOR_HPP

Added: sandbox/dataflow-rewrite/boost/dataflow/generic/static_vector/traits.hpp
==============================================================================
--- (empty file)
+++ sandbox/dataflow-rewrite/boost/dataflow/generic/static_vector/traits.hpp 2008-11-10 13:28:46 EST (Mon, 10 Nov 2008)
@@ -0,0 +1,54 @@
+/*=================================---------------------------------------------
+ Copyright 2007,2008 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__GENERIC__STATIC_VECTOR__TRAITS_HPP
+#define BOOST__DATAFLOW__GENERIC__STATIC_VECTOR__TRAITS_HPP
+
+#include <boost/dataflow/generic/framework_entity/traits.hpp>
+#include <boost/mpl/is_sequence.hpp>
+
+namespace boost { namespace dataflow {
+
+template<typename EntitySequence, typename Framework=default_framework>
+struct static_vector_traits
+ : public traits<Framework>
+{
+ typedef EntitySequence static_ports;
+ BOOST_MPL_ASSERT(( mpl::is_sequence<EntitySequence> ));
+};
+
+/// Boolean Metafunction determining whether a type is a PortTraits.
+template<typename StaticVectorTraits, typename Enable=detail::enable_guard>
+struct is_static_vector_traits : public mpl::false_
+{
+ /// INTERNAL ONLY
+ BOOST_MPL_ASSERT(( is_same<Enable, detail::enable_guard> ));
+};
+
+/// INTERNAL ONLY
+template<typename StaticVectorTraits>
+struct is_static_vector_traits<StaticVectorTraits,
+ typename utility::enable_if_type<
+ utility::all_of<
+ typename StaticVectorTraits::framework,
+ typename StaticVectorTraits::static_ports
+ >,
+ detail::enable_guard
+ >::type>
+ : public mpl::true_
+{
+ /// INTERNAL ONLY
+ BOOST_MPL_ASSERT(( is_framework<typename StaticVectorTraits::framework>));
+ /// INTERNAL ONLY
+ BOOST_MPL_ASSERT(( mpl::is_sequence<typename StaticVectorTraits::static_ports> ));
+};
+
+} } // namespace boost::dataflow
+
+#endif // BOOST__DATAFLOW__GENERIC__STATIC_VECTOR_HPP

Copied: sandbox/dataflow-rewrite/boost/dataflow/utility/forced_sequence.hpp (from r48363, /sandbox/SOC/2007/signals/boost/dataflow/utility/forced_sequence.hpp)
==============================================================================
--- /sandbox/SOC/2007/signals/boost/dataflow/utility/forced_sequence.hpp (original)
+++ sandbox/dataflow-rewrite/boost/dataflow/utility/forced_sequence.hpp 2008-11-10 13:28:46 EST (Mon, 10 Nov 2008)
@@ -1,15 +1,21 @@
-// 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)
+/*=================================---------------------------------------------
+ Copyright 2007,2008 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__UTILITY__FORCED_AS_SEQUENCE_HPP
+#define BOOST__DATAFLOW__UTILITY__FORCED_AS_SEQUENCE_HPP
 
-#ifndef BOOST_DATAFLOW_UTILITY_FORCED_AS_SEQUENCE_HPP
-#define BOOST_DATAFLOW_UTILITY_FORCED_AS_SEQUENCE_HPP
 
 #include <boost/mpl/is_sequence.hpp>
 #include <boost/mpl/vector.hpp>
 #include <boost/utility/enable_if.hpp>
 
+
 namespace boost { namespace dataflow {
 
 namespace utility {
@@ -36,4 +42,4 @@
 
 } }
 
-#endif
+#endif // BOOST__DATAFLOW__UTILITY__FORCED_AS_SEQUENCE_HPP

Added: sandbox/dataflow-rewrite/boost/dataflow/vivid/entity_widget.hpp
==============================================================================
--- (empty file)
+++ sandbox/dataflow-rewrite/boost/dataflow/vivid/entity_widget.hpp 2008-11-10 13:28:46 EST (Mon, 10 Nov 2008)
@@ -0,0 +1,52 @@
+/*=================================---------------------------------------------
+ Copyright 2007,2008 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__VIVID__ENTITY_WIDGET_HPP
+#define BOOST__DATAFLOW__VIVID__ENTITY_WIDGET_HPP
+
+
+#include <boost/dataflow/blueprint/framework_entity.hpp>
+
+#include <boost/guigl/widget/labeled_button.hpp>
+#include <boost/guigl/view/impl/draggable.hpp>
+#include <boost/scoped_ptr.hpp>
+
+namespace boost { namespace dataflow { namespace vivid {
+
+BOOST_PARAMETER_UNTYPED_NAME(entity);
+
+template<typename BlueprintFramework>
+class entity_widget
+ : public guigl::view::draggable<entity_widget<BlueprintFramework>, guigl::button::right_type,
+ guigl::widget::labeled_button>
+{
+ typedef blueprint::framework_entity<BlueprintFramework> framework_entity_type;
+public:
+ typedef guigl::view::draggable<entity_widget<BlueprintFramework>, guigl::button::right_type,
+ guigl::widget::labeled_button> base_type;
+
+ template<typename Args>
+ entity_widget(const Args &args)
+ : base_type(args)
+ , m_entity(args[_entity])
+ {}
+ void draggable_on_drag(const guigl::position_type &position)
+ {
+ guigl::position_type difference(position - base_type::drag_origin());
+ base_type::set_position(base_type::position() + difference);
+ guigl::window::redraw(*this);
+ }
+ framework_entity_type &entity()
+ { return *m_entity; }
+private:
+ boost::scoped_ptr<framework_entity_type> m_entity;
+};
+
+} } }
+
+#endif // BOOST__DATAFLOW__VIVID__FACTORY_WINDOW_HPP

Copied: sandbox/dataflow-rewrite/boost/dataflow/vivid/factory_window.hpp (from r48363, /sandbox/SOC/2007/signals/libs/dataflow/example/glv_gui/blueprint_bank.hpp)
==============================================================================
--- /sandbox/SOC/2007/signals/libs/dataflow/example/glv_gui/blueprint_bank.hpp (original)
+++ sandbox/dataflow-rewrite/boost/dataflow/vivid/factory_window.hpp 2008-11-10 13:28:46 EST (Mon, 10 Nov 2008)
@@ -1,57 +1,81 @@
-// 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)
+/*=================================---------------------------------------------
+ Copyright 2007,2008 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__VIVID__FACTORY_WINDOW_HPP
+#define BOOST__DATAFLOW__VIVID__FACTORY_WINDOW_HPP
 
-#ifndef BLUEPRINT_COMPONENT_BANK_HPP
-#define BLUEPRINT_COMPONENT_BANK_HPP
 
-#include <boost/dataflow/blueprint/component_bank.hpp>
-#include <boost/ptr_container/ptr_vector.hpp>
+#include <boost/dataflow/blueprint/factory.hpp>
 
-#include <glv.h>
-#include <glv_pimpl_binding.h>
+#include <boost/guigl/window.hpp>
+#include <boost/guigl/widget/labeled_button.hpp>
+#include <boost/guigl/widget/label.hpp>
+#include <boost/guigl/layout/grid.hpp>
 
-namespace boost { namespace dataflow { namespace glv_gui {
+#include <memory>
 
-class blueprint_window;
 
-class blueprint_bank
+namespace boost { namespace dataflow { namespace vivid {
+
+template<typename BlueprintFramework>
+class network_window;
+
+template<typename BlueprintFramework>
+class factory_window
 {
+ typedef blueprint::factory<BlueprintFramework> factory_type;
+ typedef blueprint::framework_entity<BlueprintFramework> framework_entity_type;
 public:
- blueprint_bank()
- : m_view(glv::Rect(70, 600))
- , m_layout(m_view, glv::Direction::S, glv::Place::TL, 5, 5, 5)
- {
- m_view.colors().back.set(0);
- };
+ factory_window()
+ : m_window(( guigl::_label="Factory", guigl::_size=guigl::size_type(60, 600) ))
+ {};
 
- void set_bank(const blueprint::component_bank &bank)
+ void set_factory(const factory_type &factory)
     {
- m_bank = bank;
+ m_factory = factory;
         rearrange();
     }
- void set_blueprint(blueprint_window &blueprint)
+ void set_network_window(network_window<BlueprintFramework> &network)
     {
- m_blueprint = &blueprint;
+ m_network = &network;
     }
     
- glv::View &view()
- { return m_view; }
+ guigl::window &window()
+ { return m_window; }
 
- typedef boost::ptr_vector<glv::Button> component_buttons_type;
 private:
- void rearrange();
- blueprint_window * m_blueprint;
- blueprint::component_bank m_bank;
- glv::View m_view;
- glv::Placer m_layout;
+ void rearrange()
+ {
+ guigl::layout::grid layout((guigl::_grid_size=m_window.size(), guigl::_vertical=10));
+ for(typename factory_type::iterator it=m_factory.begin(); it!=m_factory.end(); it++)
+ {
+ guigl::widget::labeled_button *button;
+ m_window << (button = layout.create<guigl::widget::labeled_button>((guigl::_label=it->c_str())));
+ button->on_click.connect(boost::bind(&factory_window::select, this, *it));
+ }
+ }
+ void select(const std::string &key)
+ {
+ if(m_network)
+ {
+ std::auto_ptr<framework_entity_type> entity(
+ m_factory[key](m_network->framework_object()));
+ m_network->add_entity(entity);
+ }
+ }
+ network_window<BlueprintFramework> * m_network;
+ factory_type m_factory;
+ guigl::window m_window;
         
- component_buttons_type m_component_buttons;
- friend class component_button;
+// component_buttons_type m_component_buttons;
+// friend class component_button;
 };
 
 } } }
 
-#endif
+#endif // BOOST__DATAFLOW__VIVID__FACTORY_WINDOW_HPP

Copied: sandbox/dataflow-rewrite/boost/dataflow/vivid/network_window.hpp (from r48363, /sandbox/SOC/2007/signals/libs/dataflow/example/glv_gui/blueprint_window.hpp)
==============================================================================
--- /sandbox/SOC/2007/signals/libs/dataflow/example/glv_gui/blueprint_window.hpp (original)
+++ sandbox/dataflow-rewrite/boost/dataflow/vivid/network_window.hpp 2008-11-10 13:28:46 EST (Mon, 10 Nov 2008)
@@ -1,50 +1,150 @@
-// 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)
+/*=================================---------------------------------------------
+ Copyright 2007,2008 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__VIVID__NETWORK_WINDOW_HPP
+#define BOOST__DATAFLOW__VIVID__NETWORK_WINDOW_HPP
+
+
+#include <boost/dataflow/blueprint/port_binary_operation.hpp>
+#include <boost/dataflow/blueprint/operation_adapter.hpp>
+#include <boost/dataflow/vivid/entity_widget.hpp>
+#include <boost/guigl/draw.hpp>
+#include <boost/guigl/geometry.hpp>
+#include <boost/guigl/window.hpp>
+#include <boost/guigl/widget/compound.hpp>
+#include <boost/guigl/widget/label.hpp>
+#include <boost/guigl/layout/grid.hpp>
+#include <boost/ptr_container/ptr_vector.hpp>
+#include <memory>
 
-#ifndef BLUEPRINT_WINDOW_HPP
-#define BLUEPRINT_WINDOW_HPP
 
-#include "glv.h"
-#include "glv_pimpl_binding.h"
+namespace boost { namespace dataflow { namespace vivid {
 
-#include <boost/dataflow/blueprint/network.hpp>
-#include <boost/dataflow/signals/runtime_support.hpp>
 
-namespace boost { namespace dataflow { namespace glv_gui {
-
-class blueprint_component;
-class blueprint_component_port;
-
-class connection
- : public std::pair<blueprint_component_port *, blueprint_component_port *>
+template<typename BlueprintFramework>
+class network_widget : public guigl::widget::compound
 {
+ typedef entity_widget<BlueprintFramework> entity_widget_type;
+
 public:
- connection(blueprint_component_port *p1, blueprint_component_port *p2)
- : std::pair<blueprint_component_port *, blueprint_component_port *>(p1, p2)
+ typedef guigl::widget::compound base_type;
+
+ template<typename Args>
+ network_widget(const Args &args)
+ : base_type(args)
     {}
+ void draw_prologue()
+ {
+ base_type::draw_prologue();
+ glLineWidth(5);
+ glBegin(GL_LINES);
+ glColor3f(0,1,0);
+ for(typename std::vector<connection_type>::iterator it=m_connections.begin(); it!= m_connections.end(); it++)
+ {
+ guigl::draw::vertex(guigl::geometry::midpoint(*it->first));
+ guigl::draw::vertex(guigl::geometry::midpoint(*it->second));
+ }
+ glEnd();
+ }
+ void draw()
+ {
+ draw_prologue();
+ draw_epilogue();
+ }
+ void add_connection(entity_widget_type *port1, entity_widget_type *port2)
+ {
+ m_connections.push_back(connection_type(port1, port2));
+ }
+private:
+ typedef std::pair<entity_widget_type *,entity_widget_type *> connection_type;
+ std::vector<connection_type> m_connections;
 };
 
-class blueprint_window
- : public glv::View
+template<typename BlueprintFramework>
+class network_window
 {
+ typedef blueprint::framework_entity<BlueprintFramework> framework_entity_type;
+ typedef blueprint::framework_object<BlueprintFramework> framework_object_type;
+ typedef entity_widget<BlueprintFramework> entity_widget_type;
+ typedef blueprint::port<BlueprintFramework> port_type;
 public:
- blueprint_window();
- void add_component(std::auto_ptr<blueprint::component> c, const std::string &name);
- void register_port_click(blueprint_component_port *port);
+ network_window()
+ : m_window(( guigl::_label="Network", guigl::_size=guigl::size_type(800, 600) ))
+ , m_layout(( guigl::_grid_size=guigl::size_type(800, 500), guigl::_horizontal=8, guigl::_vertical=5 ))
+ , m_dragged(0)
+ {
+ m_window << (m_status = new guigl::widget::label((
+ guigl::_label="Status bar...",
+ guigl::_size(800, 50),
+ guigl::_position(0, 550) )) );
+ m_window << (m_network_widget = new network_widget<BlueprintFramework>(( guigl::_background(1,1,1), guigl::_size(800, 500) )) );
+
+ add_operation(typename mpl::at_c<typename BlueprintFramework::framework_type::operations, 0>::type());
+ m_selected_operation = &m_operations[0];
+ }
+
+ void add_entity(std::auto_ptr<framework_entity_type> entity)
+ {
+ entity_widget_type *widget = m_layout.create<entity_widget_type>((
+ _entity=entity.release(),
+ guigl::_background(.5,.5,.5),
+ guigl::_label="entity" ));
+
+ (*m_network_widget) << widget;
+ guigl::window::redraw(*m_network_widget);
+
+ widget->on_click.connect(boost::bind(&network_window::clicked, this, widget));
+ }
+
+ framework_object_type &framework_object()
+ { return m_framework_object; }
+
+ template<typename Operation>
+ void add_operation(const Operation &operation)
+ {
+ m_operations.push_back(new blueprint::operation_adapter<Operation>(operation));
+ }
 private:
- static void style_change_handler(glv::Notifier *sender, void *this_);
- void onDraw();
- blueprint::network m_network;
- std::vector<blueprint_component *> m_components;
- blueprint_component_port *m_dragged;
- std::vector<connection> m_connections;
- std::vector<connection>::iterator m_selected;
- glv::LayoutGrid m_layout;
- glv::Label m_status;
- glv::Button m_rotate_component_layout;
+ void clicked(entity_widget_type *widget)
+ {
+ if(m_dragged)
+ {
+ port_type
+ & port1 = static_cast<blueprint::port<BlueprintFramework> &>(m_dragged->entity())
+ , & port2 = static_cast<blueprint::port<BlueprintFramework> &>(widget->entity());
+
+ if (port_binary_operation_will_succeed(port1, port2, *m_selected_operation))
+ {
+ port_binary_operation(port1, port2, *m_selected_operation);
+ m_network_widget->add_connection(m_dragged, widget);
+ m_status->set_label("Ports connected...");
+ }
+ else
+ m_status->set_label("Ports not connectable");
+ m_dragged = NULL;
+ }
+ else
+ {
+ m_status->set_label("Initiating connect - click on destination port to make connection");
+ m_dragged = widget;
+ }
+ }
+
+ framework_object_type m_framework_object;
+ guigl::window m_window;
+ guigl::widget::label *m_status;
+ network_widget<BlueprintFramework> *m_network_widget;
+ guigl::layout::grid m_layout;
+ entity_widget_type *m_dragged;
+
+ blueprint::operation *m_selected_operation;
+ boost::ptr_vector<blueprint::operation> m_operations;
 };
 
 } } }
-#endif
+#endif // BOOST__DATAFLOW__VIVID__NETWORK_WINDOW_HPP

Modified: sandbox/dataflow-rewrite/libs/dataflow/build/xcodeide/dataflow.xcodeproj/project.pbxproj
==============================================================================
--- sandbox/dataflow-rewrite/libs/dataflow/build/xcodeide/dataflow.xcodeproj/project.pbxproj (original)
+++ sandbox/dataflow-rewrite/libs/dataflow/build/xcodeide/dataflow.xcodeproj/project.pbxproj 2008-11-10 13:28:46 EST (Mon, 10 Nov 2008)
@@ -116,6 +116,7 @@
                 0826E4470EA563930090AB4E /* port_binary_operation_implementation_adapter.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = port_binary_operation_implementation_adapter.hpp; sourceTree = "<group>"; };
                 0826E44D0EA566F70090AB4E /* test_port_binary_operation_implementation.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = test_port_binary_operation_implementation.cpp; sourceTree = "<group>"; };
                 0826E4BB0EA57D110090AB4E /* castable_polymorphic_object.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = castable_polymorphic_object.hpp; sourceTree = "<group>"; };
+ 083C434C0EB2DC6E00D2C009 /* network_window.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = network_window.hpp; sourceTree = "<group>"; };
                 087535BE0E9C141200AD4E99 /* my_blueprint_framework.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = my_blueprint_framework.hpp; sourceTree = "<group>"; };
                 087535C70E9C1BCF00AD4E99 /* framework_entity_adapter.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = framework_entity_adapter.hpp; sourceTree = "<group>"; };
                 0875360D0E9C29BC00AD4E99 /* port_adapter.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = port_adapter.hpp; sourceTree = "<group>"; };
@@ -137,7 +138,21 @@
                 089A28B10E8D96F2000FCCC9 /* my_framework.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = my_framework.hpp; sourceTree = "<group>"; };
                 089A28B50E8D9772000FCCC9 /* my_ports.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = my_ports.hpp; sourceTree = "<group>"; };
                 089A28D80E8D99BC000FCCC9 /* my_entity.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = my_entity.hpp; sourceTree = "<group>"; };
+ 089F17380EAE8B3D00560022 /* my_framework_with_object.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = my_framework_with_object.hpp; sourceTree = "<group>"; };
+ 089F17400EAE8E5200560022 /* framework_object_fwd.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = framework_object_fwd.hpp; sourceTree = "<group>"; };
                 08A0FF8A0E8B4012000F0F8F /* file_template.py */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.script.python; path = file_template.py; sourceTree = "<group>"; };
+ 08A227910EAE417000F70466 /* Jamfile */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.jam; path = Jamfile; sourceTree = "<group>"; };
+ 08A227930EAE417C00F70466 /* Jamfile */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.jam; path = Jamfile; sourceTree = "<group>"; };
+ 08A227960EAE41AD00F70466 /* vivid_graph_example.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = vivid_graph_example.cpp; sourceTree = "<group>"; };
+ 08A2279C0EAE427000F70466 /* graph_example.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = graph_example.cpp; sourceTree = "<group>"; };
+ 08A2279D0EAE427700F70466 /* Jamfile */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.jam; path = Jamfile; sourceTree = "<group>"; };
+ 08A227A00EAE429600F70466 /* graph_framework.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = graph_framework.hpp; sourceTree = "<group>"; };
+ 08A227A90EAE434300F70466 /* port.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = port.hpp; sourceTree = "<group>"; };
+ 08A486B30EC11632007D73CC /* test_get_port.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = test_get_port.cpp; sourceTree = "<group>"; };
+ 08A53F850EAC07E6000B9C17 /* blueprint_component.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = blueprint_component.hpp; sourceTree = "<group>"; };
+ 08A53F8E0EAC0AC1000B9C17 /* factory.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = factory.hpp; sourceTree = "<group>"; };
+ 08A53F920EAC14A4000B9C17 /* test_factory.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = test_factory.cpp; sourceTree = "<group>"; };
+ 08A59AB60EA6AED700F96721 /* forced_sequence.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = forced_sequence.hpp; sourceTree = "<group>"; };
                 08A77AB30E4F91AA00B8793E /* Jamroot */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; name = Jamroot; path = ../../../../Jamroot; sourceTree = SOURCE_ROOT; };
                 08A77AB40E4F91AB00B8793E /* LICENSE_1_0.txt */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; name = LICENSE_1_0.txt; path = ../../../../LICENSE_1_0.txt; sourceTree = SOURCE_ROOT; };
                 08A77ADC0E4FB06600B8793E /* framework.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = framework.hpp; sourceTree = "<group>"; };
@@ -145,12 +160,24 @@
                 08A77AEE0E4FB4C800B8793E /* is_type.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = is_type.hpp; sourceTree = "<group>"; };
                 08A77B010E4FC51C00B8793E /* Jamfile */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.jam; path = Jamfile; sourceTree = "<group>"; };
                 08A77B060E4FC58D00B8793E /* Jamfile */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.jam; path = Jamfile; sourceTree = "<group>"; };
+ 08AA903B0EAD3BF100409A2E /* factory_window.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = factory_window.hpp; sourceTree = "<group>"; };
+ 08AA90410EAD43BA00409A2E /* Jamfile */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.jam; path = Jamfile; sourceTree = "<group>"; };
+ 08AA90440EAD43F700409A2E /* test_factory_window.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = test_factory_window.cpp; sourceTree = "<group>"; };
+ 08AA90690EAD46A000409A2E /* Jamfile */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.jam; path = Jamfile; sourceTree = "<group>"; };
+ 08AB81AA0EC7A1F700A2B98A /* traits.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = traits.hpp; sourceTree = "<group>"; };
+ 08AB81AB0EC7A20200A2B98A /* static_vector.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = static_vector.hpp; sourceTree = "<group>"; };
+ 08AB81B70EC7A45900A2B98A /* get_port.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = get_port.hpp; sourceTree = "<group>"; };
+ 08AB81BB0EC7A50200A2B98A /* test_static_vector.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = test_static_vector.cpp; sourceTree = "<group>"; };
+ 08AB81BF0EC7A52F00A2B98A /* my_static_vector.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = my_static_vector.hpp; sourceTree = "<group>"; };
+ 08B44C1B0EB63549004B133F /* entity_widget.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = entity_widget.hpp; sourceTree = "<group>"; };
                 08B8F1AC0E512CF7000545B8 /* traits_sequence_intrusive_registration.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = traits_sequence_intrusive_registration.hpp; sourceTree = "<group>"; };
                 08B8F1AD0E512D31000545B8 /* framework_entity.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = framework_entity.hpp; sourceTree = "<group>"; };
                 08B8F1B60E512DA3000545B8 /* test_framework_entity.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = test_framework_entity.cpp; sourceTree = "<group>"; };
                 08B8F1BE0E512E72000545B8 /* traits.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = traits.hpp; sourceTree = "<group>"; };
                 08B8F1C00E512F45000545B8 /* test_framework_entity_traits.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = test_framework_entity_traits.cpp; sourceTree = "<group>"; };
                 08B8F1D00E513569000545B8 /* test_framework.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = test_framework.cpp; sourceTree = "<group>"; };
+ 08D18D760EBE25E800B1A160 /* fusion_static_vector.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = fusion_static_vector.hpp; sourceTree = "<group>"; };
+ 08D18D770EBE25E800B1A160 /* static_vector.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = static_vector.hpp; sourceTree = "<group>"; };
                 08D965820E83A2F900087C6F /* framework_entity.qbk */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = framework_entity.qbk; sourceTree = "<group>"; };
                 08D965C80E83A94E00087C6F /* category.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = category.hpp; sourceTree = "<group>"; };
                 08D965C90E83A94E00087C6F /* port.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = port.hpp; sourceTree = "<group>"; };
@@ -175,6 +202,7 @@
                 080DD7560C13908400EEB53D = {
                         isa = PBXGroup;
                         children = (
+ 08AA90670EAD469600409A2E /* external */,
                                 08A77ACC0E4F941C00B8793E /* dataflow */,
                                 08A77AB30E4F91AA00B8793E /* Jamroot */,
                                 08A77AB40E4F91AB00B8793E /* LICENSE_1_0.txt */,
@@ -196,6 +224,9 @@
                 08668C4D0C19A16300ACB19A /* example */ = {
                         isa = PBXGroup;
                         children = (
+ 08A2279B0EAE425000F70466 /* generic */,
+ 08A2277C0EAE3E6D00F70466 /* vivid */,
+ 08A227910EAE417000F70466 /* Jamfile */,
                         );
                         name = example;
                         path = ../../example;
@@ -235,6 +266,25 @@
                         path = examples;
                         sourceTree = "<group>";
                 };
+ 08A2277C0EAE3E6D00F70466 /* vivid */ = {
+ isa = PBXGroup;
+ children = (
+ 08A227930EAE417C00F70466 /* Jamfile */,
+ 08A227960EAE41AD00F70466 /* vivid_graph_example.cpp */,
+ );
+ path = vivid;
+ sourceTree = "<group>";
+ };
+ 08A2279B0EAE425000F70466 /* generic */ = {
+ isa = PBXGroup;
+ children = (
+ 08A2279C0EAE427000F70466 /* graph_example.cpp */,
+ 08A2279D0EAE427700F70466 /* Jamfile */,
+ 08A227A00EAE429600F70466 /* graph_framework.hpp */,
+ );
+ path = generic;
+ sourceTree = "<group>";
+ };
                 08A439340E295B35009845FD /* build */ = {
                         isa = PBXGroup;
                         children = (
@@ -246,9 +296,21 @@
                         path = ..;
                         sourceTree = SOURCE_ROOT;
                 };
+ 08A59A8C0EA69D9D00F96721 /* vivid */ = {
+ isa = PBXGroup;
+ children = (
+ 083C434C0EB2DC6E00D2C009 /* network_window.hpp */,
+ 08AA903B0EAD3BF100409A2E /* factory_window.hpp */,
+ 08A53F850EAC07E6000B9C17 /* blueprint_component.hpp */,
+ 08B44C1B0EB63549004B133F /* entity_widget.hpp */,
+ );
+ path = vivid;
+ sourceTree = "<group>";
+ };
                 08A77ACC0E4F941C00B8793E /* dataflow */ = {
                         isa = PBXGroup;
                         children = (
+ 08A59A8C0EA69D9D00F96721 /* vivid */,
                                 08EE1D690E9533ED00EF3E66 /* blueprint */,
                                 08A77AEC0E4FB4C800B8793E /* utility */,
                                 08A77ACD0E4F941C00B8793E /* generic */,
@@ -260,7 +322,11 @@
                 08A77ACD0E4F941C00B8793E /* generic */ = {
                         isa = PBXGroup;
                         children = (
+ 08AB81A90EC7A1E300A2B98A /* static_vector */,
+ 08D18D760EBE25E800B1A160 /* fusion_static_vector.hpp */,
+ 08D18D770EBE25E800B1A160 /* static_vector.hpp */,
                                 0898B4700E83E6E1004F3E91 /* port_binary_operation.hpp */,
+ 08A227A90EAE434300F70466 /* port.hpp */,
                                 08D965C50E83A83600087C6F /* port */,
                                 08A77ADC0E4FB06600B8793E /* framework.hpp */,
                                 08B8F1AD0E512D31000545B8 /* framework_entity.hpp */,
@@ -274,6 +340,7 @@
                 08A77AEC0E4FB4C800B8793E /* utility */ = {
                         isa = PBXGroup;
                         children = (
+ 08A59AB60EA6AED700F96721 /* forced_sequence.hpp */,
                                 08A77AED0E4FB4C800B8793E /* enable_if_type.hpp */,
                                 0826E3370EA53F0C0090AB4E /* guarded_enable_if_type.hpp */,
                                 08A77AEE0E4FB4C800B8793E /* is_type.hpp */,
@@ -299,10 +366,50 @@
                                 089A28B50E8D9772000FCCC9 /* my_ports.hpp */,
                                 089A28D80E8D99BC000FCCC9 /* my_entity.hpp */,
                                 0826E2DC0EA52A850090AB4E /* my_connect.hpp */,
+ 089F17380EAE8B3D00560022 /* my_framework_with_object.hpp */,
+ 08AB81BF0EC7A52F00A2B98A /* my_static_vector.hpp */,
+ 08A486B30EC11632007D73CC /* test_get_port.cpp */,
+ 08AB81BB0EC7A50200A2B98A /* test_static_vector.cpp */,
                         );
                         path = generic;
                         sourceTree = "<group>";
                 };
+ 08AA90400EAD43AD00409A2E /* vivid */ = {
+ isa = PBXGroup;
+ children = (
+ 08AA90410EAD43BA00409A2E /* Jamfile */,
+ 08AA90440EAD43F700409A2E /* test_factory_window.cpp */,
+ );
+ path = vivid;
+ sourceTree = "<group>";
+ };
+ 08AA90670EAD469600409A2E /* external */ = {
+ isa = PBXGroup;
+ children = (
+ 08AA90680EAD469600409A2E /* guigl */,
+ );
+ name = external;
+ path = ../../../external;
+ sourceTree = SOURCE_ROOT;
+ };
+ 08AA90680EAD469600409A2E /* guigl */ = {
+ isa = PBXGroup;
+ children = (
+ 08AA90690EAD46A000409A2E /* Jamfile */,
+ );
+ path = guigl;
+ sourceTree = "<group>";
+ };
+ 08AB81A90EC7A1E300A2B98A /* static_vector */ = {
+ isa = PBXGroup;
+ children = (
+ 08AB81B70EC7A45900A2B98A /* get_port.hpp */,
+ 08AB81AA0EC7A1F700A2B98A /* traits.hpp */,
+ 08AB81AB0EC7A20200A2B98A /* static_vector.hpp */,
+ );
+ path = static_vector;
+ sourceTree = "<group>";
+ };
                 08B8F1AB0E512CF7000545B8 /* framework_entity */ = {
                         isa = PBXGroup;
                         children = (
@@ -317,6 +424,7 @@
                 08C675960C13A03E00D85379 /* test */ = {
                         isa = PBXGroup;
                         children = (
+ 08AA90400EAD43AD00409A2E /* vivid */,
                                 08ED9F2B0E9AFE0F00894656 /* blueprint */,
                                 08A77AFF0E4FC51C00B8793E /* generic */,
                                 08A77B010E4FC51C00B8793E /* Jamfile */,
@@ -348,6 +456,7 @@
                                 0826E3FD0EA55D1B0090AB4E /* test_framework_object.cpp */,
                                 087535BE0E9C141200AD4E99 /* my_blueprint_framework.hpp */,
                                 0826E2AE0EA526F70090AB4E /* my_blueprint_ports.hpp */,
+ 08A53F920EAC14A4000B9C17 /* test_factory.cpp */,
                         );
                         path = blueprint;
                         sourceTree = "<group>";
@@ -355,6 +464,7 @@
                 08EE1D690E9533ED00EF3E66 /* blueprint */ = {
                         isa = PBXGroup;
                         children = (
+ 08A53F8E0EAC0AC1000B9C17 /* factory.hpp */,
                                 08EE1D7C0E95453200EF3E66 /* framework.hpp */,
                                 08EE1D6A0E95348400EF3E66 /* framework_entity.hpp */,
                                 087535C70E9C1BCF00AD4E99 /* framework_entity_adapter.hpp */,
@@ -367,6 +477,7 @@
                                 0826E3950EA543F60090AB4E /* operation_adapter.hpp */,
                                 0826E3FA0EA5537B0090AB4E /* framework_object.hpp */,
                                 0826E4BB0EA57D110090AB4E /* castable_polymorphic_object.hpp */,
+ 089F17400EAE8E5200560022 /* framework_object_fwd.hpp */,
                         );
                         path = blueprint;
                         sourceTree = "<group>";

Modified: sandbox/dataflow-rewrite/libs/dataflow/doc/dataflow.qbk
==============================================================================
--- sandbox/dataflow-rewrite/libs/dataflow/doc/dataflow.qbk (original)
+++ sandbox/dataflow-rewrite/libs/dataflow/doc/dataflow.qbk 2008-11-10 13:28:46 EST (Mon, 10 Nov 2008)
@@ -14,7 +14,7 @@
 
 [template concepts[] [link boost_dataflow.generic.concepts concepts]]
 
-[template Framework[] [link boost_dataflow.generic.concepts.general.tag [^Framework]]]
+[template Framework[] [link boost_dataflow.generic.concepts.general.framework [^Framework]]]
 [template FrameworkEntityTraits[] [link boost_dataflow.generic.concepts.general.entity [^FrameworkEntityTraits]]]
 [template FrameworkEntity[] [link boost_dataflow.generic.concepts.general.entity [^FrameworkEntity]]]
 

Added: sandbox/dataflow-rewrite/libs/dataflow/example/Jamfile
==============================================================================
--- (empty file)
+++ sandbox/dataflow-rewrite/libs/dataflow/example/Jamfile 2008-11-10 13:28:46 EST (Mon, 10 Nov 2008)
@@ -0,0 +1,21 @@
+#==================================---------------------------------------------
+# Copyright 2008 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)
+#----------------------------------------------===============================*/
+
+
+project dataflow/example
+ : requirements
+ <define>BOOST_ALL_NO_LIB=1
+ ;
+
+build-project generic ;
+
+if $(guigl_present)
+{
+ build-project vivid ;
+}
+

Added: sandbox/dataflow-rewrite/libs/dataflow/example/generic/Jamfile
==============================================================================
--- (empty file)
+++ sandbox/dataflow-rewrite/libs/dataflow/example/generic/Jamfile 2008-11-10 13:28:46 EST (Mon, 10 Nov 2008)
@@ -0,0 +1,10 @@
+#==================================---------------------------------------------
+# Copyright 2008 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)
+#----------------------------------------------===============================*/
+
+
+exe graph_example : graph_example.cpp /boost_guigl//boost_guigl/<link>static ;

Added: sandbox/dataflow-rewrite/libs/dataflow/example/generic/graph_example.cpp
==============================================================================
--- (empty file)
+++ sandbox/dataflow-rewrite/libs/dataflow/example/generic/graph_example.cpp 2008-11-10 13:28:46 EST (Mon, 10 Nov 2008)
@@ -0,0 +1,16 @@
+/*=================================---------------------------------------------
+ Copyright 2007,2008 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)
+-----------------------------------------------===============================*/
+
+
+#include "graph_framework.hpp"
+
+
+int main()
+{
+ return 0;
+}

Added: sandbox/dataflow-rewrite/libs/dataflow/example/generic/graph_framework.hpp
==============================================================================
--- (empty file)
+++ sandbox/dataflow-rewrite/libs/dataflow/example/generic/graph_framework.hpp 2008-11-10 13:28:46 EST (Mon, 10 Nov 2008)
@@ -0,0 +1,61 @@
+/*=================================---------------------------------------------
+ Copyright 2007,2008 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)
+-----------------------------------------------===============================*/
+
+
+#include <boost/dataflow/generic/port.hpp>
+#include <boost/dataflow/generic/port_binary_operation.hpp>
+#include <boost/graph/adjacency_list.hpp>
+
+
+// provide Dataflow support for an undirected BGL graph type
+namespace boost { namespace dataflow { namespace ugraph {
+
+// for this example, we support one specific BGL type.
+typedef boost::adjacency_list<
+ boost::vecS, boost::vecS, boost::undirectedS> graph_type;
+
+// our framework will support only the connect operation.
+struct framework : public dataflow::framework<operations::connect, graph_type>
+{};
+
+struct vertex_port_traits
+ : public dataflow::port_traits<ports::producer_consumer, framework>
+{};
+
+struct vertex : public dataflow::port<vertex_port_traits>
+{
+ vertex(graph_type &graph)
+ : m_graph(graph)
+ {
+ m_vertex_descriptor = add_vertex(graph);
+ }
+ graph_type &m_graph;
+ graph_type::vertex_descriptor m_vertex_descriptor;
+};
+
+}
+
+namespace extension {
+
+ // how to connect two vertices
+ template<>
+ struct port_binary_operation_impl<ugraph::vertex_port_traits, ugraph::vertex_port_traits, operations::connect>
+ {
+ typedef void result_type;
+
+ template<typename Port1, typename Port2>
+ result_type operator()(Port1 &port1, Port2 &port2, const operations::connect &)
+ {
+ BOOST_ASSERT(&port1.m_graph == &port2.m_graph);
+ add_edge(port1.m_vertex_descriptor, port2.m_vertex_descriptor, port1.m_graph);
+ }
+ };
+
+}
+
+} }

Added: sandbox/dataflow-rewrite/libs/dataflow/example/vivid/Jamfile
==============================================================================
--- (empty file)
+++ sandbox/dataflow-rewrite/libs/dataflow/example/vivid/Jamfile 2008-11-10 13:28:46 EST (Mon, 10 Nov 2008)
@@ -0,0 +1,10 @@
+#==================================---------------------------------------------
+# Copyright 2008 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)
+#----------------------------------------------===============================*/
+
+
+exe vivid_graph_example : vivid_graph_example.cpp /boost_guigl//boost_guigl/<link>static ;

Added: sandbox/dataflow-rewrite/libs/dataflow/example/vivid/vivid_graph_example.cpp
==============================================================================
--- (empty file)
+++ sandbox/dataflow-rewrite/libs/dataflow/example/vivid/vivid_graph_example.cpp 2008-11-10 13:28:46 EST (Mon, 10 Nov 2008)
@@ -0,0 +1,55 @@
+/*=================================---------------------------------------------
+ Copyright 2008 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)
+-----------------------------------------------===============================*/
+
+
+#include <boost/dataflow/blueprint/framework.hpp>
+#include <boost/dataflow/vivid/factory_window.hpp>
+#include <boost/dataflow/vivid/network_window.hpp>
+#include <boost/guigl/application.hpp>
+#include <boost/graph/connected_components.hpp>
+#include "../generic/graph_framework.hpp"
+
+
+namespace df = boost::dataflow;
+typedef df::blueprint::framework<df::ugraph::framework> graph_blueprint_framework;
+
+void connected_components(const df::blueprint::framework_object<graph_blueprint_framework> &bfo)
+{
+ std::vector<int> component(num_vertices(bfo.object()));
+ int num = connected_components(bfo.object(), &component[0]);
+
+ std::cout << num << std::endl;
+}
+
+int main()
+{
+ using namespace boost::guigl::keywords;
+ boost::guigl::window controls((_label="Controls", _size=boost::guigl::size_type(300,50) ));
+ boost::guigl::widget::labeled_button *connected_components_button;
+ controls << (connected_components_button = new boost::guigl::widget::labeled_button((_label="Components", _size(300,50), _background(0,0,1) )) );
+
+ df::vivid::factory_window<graph_blueprint_framework> factory_window;
+ df::vivid::network_window<graph_blueprint_framework> network_window;
+ factory_window.set_network_window(network_window);
+
+ df::blueprint::factory<graph_blueprint_framework> factory;
+
+ factory.add_port<df::ugraph::vertex>("vertex");
+ network_window.framework_object().register_operation<df::ugraph::vertex, df::ugraph::vertex, df::operations::connect>();
+
+ factory_window.set_factory(factory);
+
+
+ connected_components_button->on_click.connect(boost::bind(&connected_components, boost::ref(network_window.framework_object())));
+ boost::guigl::window::redraw(*connected_components_button);
+
+ boost::guigl::application::run();
+
+
+ return 0;
+}

Modified: sandbox/dataflow-rewrite/libs/dataflow/test/Jamfile
==============================================================================
--- sandbox/dataflow-rewrite/libs/dataflow/test/Jamfile (original)
+++ sandbox/dataflow-rewrite/libs/dataflow/test/Jamfile 2008-11-10 13:28:46 EST (Mon, 10 Nov 2008)
@@ -17,3 +17,8 @@
 
 build-project generic ;
 build-project blueprint ;
+
+if $(guigl_present)
+{
+ build-project vivid ;
+}
\ No newline at end of file

Modified: sandbox/dataflow-rewrite/libs/dataflow/test/blueprint/Jamfile
==============================================================================
--- sandbox/dataflow-rewrite/libs/dataflow/test/blueprint/Jamfile (original)
+++ sandbox/dataflow-rewrite/libs/dataflow/test/blueprint/Jamfile 2008-11-10 13:28:46 EST (Mon, 10 Nov 2008)
@@ -14,3 +14,4 @@
 run test_port_binary_operation_implementation.cpp ;
 run test_operation.cpp ;
 run test_framework_object.cpp ;
+run test_factory.cpp ;

Modified: sandbox/dataflow-rewrite/libs/dataflow/test/blueprint/my_blueprint_framework.hpp
==============================================================================
--- sandbox/dataflow-rewrite/libs/dataflow/test/blueprint/my_blueprint_framework.hpp (original)
+++ sandbox/dataflow-rewrite/libs/dataflow/test/blueprint/my_blueprint_framework.hpp 2008-11-10 13:28:46 EST (Mon, 10 Nov 2008)
@@ -8,9 +8,11 @@
 
 
 #include <boost/dataflow/blueprint/framework.hpp>
+#include <boost/dataflow/blueprint/framework_object.hpp>
 
 #include "../generic/my_framework.hpp"
 
 namespace df = boost::dataflow;
 
 typedef df::blueprint::framework<my_framework> my_blueprint_framework;
+typedef df::blueprint::framework_object<my_blueprint_framework> my_blueprint_framework_object;
\ No newline at end of file

Added: sandbox/dataflow-rewrite/libs/dataflow/test/blueprint/test_factory.cpp
==============================================================================
--- (empty file)
+++ sandbox/dataflow-rewrite/libs/dataflow/test/blueprint/test_factory.cpp 2008-11-10 13:28:46 EST (Mon, 10 Nov 2008)
@@ -0,0 +1,31 @@
+/*=================================---------------------------------------------
+ Copyright 2008 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)
+-----------------------------------------------===============================*/
+
+
+#include <boost/dataflow/blueprint/factory.hpp>
+
+#include "my_blueprint_framework.hpp"
+#include "../generic/my_ports.hpp"
+
+#define BOOST_TEST_MAIN
+#include <boost/test/unit_test.hpp>
+
+
+namespace df = boost::dataflow;
+
+BOOST_AUTO_TEST_CASE( test )
+{
+ df::blueprint::factory<my_blueprint_framework> factory;
+ factory.add_port<my_port_producer>("my_port_producer");
+
+ df::blueprint::framework_object<my_blueprint_framework> fo;
+ df::blueprint::framework_entity<my_blueprint_framework> *entity = factory["my_port_producer"](fo);
+
+ BOOST_CHECK_EQUAL(&entity->framework_object(), &fo);
+ BOOST_CHECK(entity->type_info() == typeid(my_port_producer));
+}
\ No newline at end of file

Modified: sandbox/dataflow-rewrite/libs/dataflow/test/blueprint/test_framework_entity.cpp
==============================================================================
--- sandbox/dataflow-rewrite/libs/dataflow/test/blueprint/test_framework_entity.cpp (original)
+++ sandbox/dataflow-rewrite/libs/dataflow/test/blueprint/test_framework_entity.cpp 2008-11-10 13:28:46 EST (Mon, 10 Nov 2008)
@@ -21,9 +21,11 @@
 
 BOOST_AUTO_TEST_CASE( test )
 {
+ my_blueprint_framework_object fo;
+
     my_port_producer p;
- df::blueprint::framework_entity_adapter<my_blueprint_framework, my_port_producer &> ref_entity(p);
- df::blueprint::framework_entity_adapter<my_blueprint_framework, my_port_producer> composition_entity;
+ df::blueprint::framework_entity_adapter<my_blueprint_framework, my_port_producer &> ref_entity(fo, p);
+ df::blueprint::framework_entity_adapter<my_blueprint_framework, my_port_producer> composition_entity(fo);
     
     BOOST_CHECK(ref_entity.type_info() == typeid(p));
     BOOST_CHECK(composition_entity.type_info() == typeid(p));

Modified: sandbox/dataflow-rewrite/libs/dataflow/test/blueprint/test_framework_object.cpp
==============================================================================
--- sandbox/dataflow-rewrite/libs/dataflow/test/blueprint/test_framework_object.cpp (original)
+++ sandbox/dataflow-rewrite/libs/dataflow/test/blueprint/test_framework_object.cpp 2008-11-10 13:28:46 EST (Mon, 10 Nov 2008)
@@ -8,10 +8,14 @@
 
 
 #include <boost/dataflow/blueprint/framework_object.hpp>
+#include <boost/dataflow/blueprint/operation_adapter.hpp>
+#include <boost/dataflow/blueprint/port_binary_operation.hpp>
 
-#include "my_blueprint_framework.hpp"
+#include "my_blueprint_ports.hpp"
 #include "../generic/my_connect.hpp"
 
+#include "../generic/my_framework_with_object.hpp"
+
 #define BOOST_TEST_MAIN
 #include <boost/test/unit_test.hpp>
 
@@ -22,7 +26,27 @@
 BOOST_AUTO_TEST_CASE( test )
 {
     df::blueprint::framework_object<my_blueprint_framework> object;
+
     object.register_operation<my_port_producer, my_port_consumer, connect>();
     BOOST_CHECK((object.has_registered_operation<my_port_producer, my_port_consumer, connect>()));
- BOOST_CHECK((!object.has_registered_operation<my_port_consumer, my_port_producer, connect>()));
+ BOOST_CHECK((!object.has_registered_operation<my_port_consumer, my_port_producer, connect>()));
+
+ my_blueprint_port_producer producer(object);
+ my_blueprint_port_consumer consumer(object);
+ df::blueprint::operation_adapter<connect> blueprint_connect(connect(1));
+
+ BOOST_CHECK(( df::port_binary_operation_will_succeed<df::blueprint::operation>(producer, consumer, blueprint_connect) ));
+ BOOST_CHECK(( !df::port_binary_operation_will_succeed<df::blueprint::operation>(consumer, producer, blueprint_connect) ));
+ BOOST_CHECK_EQUAL( boost::any_cast<int>(df::port_binary_operation<df::blueprint::operation>(producer, consumer, blueprint_connect)), 1);
 }
+
+BOOST_AUTO_TEST_CASE( test_framework_with_object )
+{
+ typedef df::blueprint::framework<my_framework_with_object> my_blueprint_framework_with_object;
+
+ df::blueprint::framework_object<my_blueprint_framework_with_object> object;
+
+ object.object();
+}
+
+

Modified: sandbox/dataflow-rewrite/libs/dataflow/test/blueprint/test_operation.cpp
==============================================================================
--- sandbox/dataflow-rewrite/libs/dataflow/test/blueprint/test_operation.cpp (original)
+++ sandbox/dataflow-rewrite/libs/dataflow/test/blueprint/test_operation.cpp 2008-11-10 13:28:46 EST (Mon, 10 Nov 2008)
@@ -17,9 +17,8 @@
 
 namespace df = boost::dataflow;
 
-
 BOOST_AUTO_TEST_CASE( test )
 {
     df::blueprint::operation_adapter<connect> c;
- df::blueprint::operation_adapter<connect> c10(10);
+ df::blueprint::operation_adapter<connect> c10(10);
 }

Modified: sandbox/dataflow-rewrite/libs/dataflow/test/blueprint/test_port.cpp
==============================================================================
--- sandbox/dataflow-rewrite/libs/dataflow/test/blueprint/test_port.cpp (original)
+++ sandbox/dataflow-rewrite/libs/dataflow/test/blueprint/test_port.cpp 2008-11-10 13:28:46 EST (Mon, 10 Nov 2008)
@@ -15,9 +15,10 @@
 
 namespace df = boost::dataflow;
 
-
 BOOST_AUTO_TEST_CASE( test )
 {
- my_blueprint_port_producer producer;
- my_blueprint_port_consumer consumer;
+ my_blueprint_framework_object fo;
+
+ my_blueprint_port_producer producer(fo);
+ my_blueprint_port_consumer consumer(fo);
 }

Modified: sandbox/dataflow-rewrite/libs/dataflow/test/blueprint/test_port_binary_operation.cpp
==============================================================================
--- sandbox/dataflow-rewrite/libs/dataflow/test/blueprint/test_port_binary_operation.cpp (original)
+++ sandbox/dataflow-rewrite/libs/dataflow/test/blueprint/test_port_binary_operation.cpp 2008-11-10 13:28:46 EST (Mon, 10 Nov 2008)
@@ -22,12 +22,16 @@
 
 BOOST_AUTO_TEST_CASE( test )
 {
- my_blueprint_port_producer producer;
- my_blueprint_port_consumer consumer;
+ my_blueprint_framework_object fo;
+
+ my_blueprint_port_producer producer(fo);
+ my_blueprint_port_consumer consumer(fo);
     df::blueprint::operation_adapter<connect> blueprint_connect;
-
+
     BOOST_CHECK(( df::are_port_binary_operable<my_blueprint_port_producer, my_blueprint_port_consumer, df::blueprint::operation>::value ));
     BOOST_CHECK(( df::are_port_binary_operable<my_blueprint_port_consumer, my_blueprint_port_producer, df::blueprint::operation>::value ));
+
+ // will not succeed without the operation being added to the framework object.
     BOOST_CHECK(( !df::port_binary_operation_will_succeed<df::blueprint::operation>(producer, consumer, blueprint_connect) ));
     BOOST_CHECK(( !df::port_binary_operation_will_succeed<df::blueprint::operation>(consumer, producer, blueprint_connect) ));
 }

Modified: sandbox/dataflow-rewrite/libs/dataflow/test/blueprint/test_port_binary_operation_implementation.cpp
==============================================================================
--- sandbox/dataflow-rewrite/libs/dataflow/test/blueprint/test_port_binary_operation_implementation.cpp (original)
+++ sandbox/dataflow-rewrite/libs/dataflow/test/blueprint/test_port_binary_operation_implementation.cpp 2008-11-10 13:28:46 EST (Mon, 10 Nov 2008)
@@ -8,10 +8,28 @@
 
 
 #include <boost/dataflow/blueprint/port_binary_operation_implementation_adapter.hpp>
+#include <boost/dataflow/blueprint/operation_adapter.hpp>
 
 #include "my_blueprint_ports.hpp"
 #include "../generic/my_connect.hpp"
 
+struct void_connect : public df::operation<df::semantics::connect>
+{};
+
+namespace boost { namespace dataflow { namespace extension {
+
+template<>
+struct port_binary_operation_impl<my_port_producer_traits, my_port_consumer_traits, void_connect>
+{
+ typedef void result_type;
+
+ template<typename Port1, typename Port2>
+ void operator()(Port1 &port1, Port2 &port2, void_connect op)
+ {}
+};
+
+}}}
+
 #define BOOST_TEST_MAIN
 #include <boost/test/unit_test.hpp>
 
@@ -21,9 +39,25 @@
 
 BOOST_AUTO_TEST_CASE( test )
 {
- my_blueprint_port_producer producer;
- my_blueprint_port_consumer consumer;
+ my_blueprint_framework_object fo;
+
+ my_blueprint_port_producer producer(fo);
+ my_blueprint_port_consumer consumer(fo);
     
+ df::blueprint::operation_adapter<connect> c;
+ df::blueprint::operation_adapter<connect> c1(1);
+ df::blueprint::operation_adapter<connect> c11(11);
+
     std::auto_ptr<df::blueprint::port_binary_operation_implementation<my_blueprint_framework> >
         op(new df::blueprint::port_binary_operation_implementation_adapter<my_port_producer, my_port_consumer, connect, my_blueprint_framework>);
+
+ BOOST_CHECK(( op->will_succeed(producer, consumer, c) ));
+ BOOST_CHECK(( op->will_succeed(producer, consumer, c1) ));
+ BOOST_CHECK(( !op->will_succeed(producer, consumer, c11) ));
+
+ BOOST_CHECK_EQUAL( boost::any_cast<int>(op->invoke(producer, consumer, c)), 0 );
+ BOOST_CHECK_EQUAL( boost::any_cast<int>(op->invoke(producer, consumer, c1)), 1 );
+
+ std::auto_ptr<df::blueprint::port_binary_operation_implementation<my_blueprint_framework> >
+ void_op(new df::blueprint::port_binary_operation_implementation_adapter<my_port_producer, my_port_consumer, void_connect, my_blueprint_framework>);
 }

Modified: sandbox/dataflow-rewrite/libs/dataflow/test/generic/Jamfile
==============================================================================
--- sandbox/dataflow-rewrite/libs/dataflow/test/generic/Jamfile (original)
+++ sandbox/dataflow-rewrite/libs/dataflow/test/generic/Jamfile 2008-11-10 13:28:46 EST (Mon, 10 Nov 2008)
@@ -18,3 +18,6 @@
 
 run test_port_binary_operation.cpp ;
 run test_operation.cpp ;
+
+run test_static_vector.cpp ;
+run test_get_port.cpp ;

Added: sandbox/dataflow-rewrite/libs/dataflow/test/generic/my_framework_with_object.hpp
==============================================================================
--- (empty file)
+++ sandbox/dataflow-rewrite/libs/dataflow/test/generic/my_framework_with_object.hpp 2008-11-10 13:28:46 EST (Mon, 10 Nov 2008)
@@ -0,0 +1,24 @@
+/*=================================---------------------------------------------
+ Copyright 2007,2008 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__TEST__GENERIC__MY_FRAMEWORK_WITH_OBJECT_HPP
+#define BOOST__DATAFLOW__TEST__GENERIC__MY_FRAMEWORK_WITH_OBJECT_HPP
+
+
+#include <boost/dataflow/generic/framework.hpp>
+
+
+struct my_object
+{};
+
+struct my_framework_with_object
+ : public df::framework<void, my_object>
+{};
+
+
+#endif // BOOST__DATAFLOW__TEST__GENERIC__MY_FRAMEWORK_WITH_OBJECT_HPP
\ No newline at end of file

Added: sandbox/dataflow-rewrite/libs/dataflow/test/generic/my_static_vector.hpp
==============================================================================
--- (empty file)
+++ sandbox/dataflow-rewrite/libs/dataflow/test/generic/my_static_vector.hpp 2008-11-10 13:28:46 EST (Mon, 10 Nov 2008)
@@ -0,0 +1,60 @@
+/*=================================---------------------------------------------
+ Copyright 2007,2008 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__TEST__GENERIC__MY_STATIC_VECTOR_HPP
+#define BOOST__DATAFLOW__TEST__GENERIC__MY_STATIC_VECTOR_HPP
+
+
+#include <boost/dataflow/generic/static_vector.hpp>
+#include "my_framework.hpp"
+#include <boost/fusion/include/vector.hpp>
+#include <boost/fusion/include/mpl.hpp>
+#include <boost/fusion/include/value_at.hpp>
+#include <boost/fusion/include/at.hpp>
+
+typedef df::static_vector_traits<boost::fusion::vector2<float, int> > my_traits;
+
+namespace df=boost::dataflow;
+
+struct tuple
+{
+ tuple(float f, int i)
+ : ports(f,i) {}
+
+ typedef my_traits dataflow_traits;
+ boost::fusion::vector2<float, int> ports;
+};
+
+namespace boost { namespace dataflow { namespace extension {
+
+template<>
+struct get_port_impl<my_traits>
+{
+ template<typename FArgs>
+ struct result
+ {};
+
+ template<typename F, typename Entity, typename N>
+ struct result<F(Entity, N)>
+ {
+ typedef typename fusion::result_of::value_at<
+ fusion::vector2<float, int>,
+ N>::type type;
+ };
+
+ template<typename Entity, typename N>
+ typename result<get_port_impl(Entity &, N)>::type
+ operator()(Entity &e, N)
+ {
+ return fusion::at<N>(e.ports);
+ }
+};
+
+}}}
+
+#endif
\ No newline at end of file

Modified: sandbox/dataflow-rewrite/libs/dataflow/test/generic/test_framework.cpp
==============================================================================
--- sandbox/dataflow-rewrite/libs/dataflow/test/generic/test_framework.cpp (original)
+++ sandbox/dataflow-rewrite/libs/dataflow/test/generic/test_framework.cpp 2008-11-10 13:28:46 EST (Mon, 10 Nov 2008)
@@ -8,6 +8,9 @@
 
 
 #include "my_framework.hpp"
+#include "my_framework_with_object.hpp"
+
+#include <boost/type_traits/is_same.hpp>
 
 #define BOOST_TEST_MAIN
 #include <boost/test/unit_test.hpp>
@@ -20,7 +23,13 @@
 BOOST_AUTO_TEST_CASE( test )
 {
     BOOST_CHECK((df::is_framework<my_framework>::value));
+ BOOST_CHECK((!df::has_framework_object<my_framework>::value));
+
     BOOST_CHECK((!df::is_framework<not_framework>::value));
+
+ BOOST_CHECK((df::is_framework<my_framework_with_object>::value));
+ BOOST_CHECK((df::has_framework_object<my_framework_with_object>::value));
+ BOOST_CHECK((boost::is_same<my_framework_with_object::framework_object_type, my_object>::value));
 }
 
 

Added: sandbox/dataflow-rewrite/libs/dataflow/test/generic/test_get_port.cpp
==============================================================================
--- (empty file)
+++ sandbox/dataflow-rewrite/libs/dataflow/test/generic/test_get_port.cpp 2008-11-10 13:28:46 EST (Mon, 10 Nov 2008)
@@ -0,0 +1,35 @@
+/*=================================---------------------------------------------
+ Copyright 2008 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)
+-----------------------------------------------===============================*/
+
+
+#include <boost/dataflow/generic/static_vector/get_port.hpp>
+#include "my_static_vector.hpp"
+
+#include <boost/type_traits/is_same.hpp>
+
+
+#define BOOST_TEST_MAIN
+#include <boost/test/unit_test.hpp>
+
+
+BOOST_AUTO_TEST_CASE( test )
+{
+ tuple x(0.5, 2);
+
+ typedef df::result_of::get_port<tuple, boost::mpl::int_<0> >::type result_of_0;
+ typedef df::result_of::get_port<tuple, boost::mpl::int_<1> >::type result_of_1;
+
+ BOOST_CHECK((boost::is_same<result_of_0, float>::value));
+ BOOST_CHECK((boost::is_same<result_of_1, int>::value));
+
+ BOOST_CHECK_EQUAL((df::get_port(x, boost::mpl::int_<0>())), 0.5);
+ BOOST_CHECK_EQUAL((df::get_port<boost::mpl::int_<0> >(x)), 0.5);
+
+ BOOST_CHECK_EQUAL((df::get_port(x, boost::mpl::int_<1>())), 2);
+ BOOST_CHECK_EQUAL((df::get_port<boost::mpl::int_<1> >(x)), 2);
+}
\ No newline at end of file

Added: sandbox/dataflow-rewrite/libs/dataflow/test/generic/test_static_vector.cpp
==============================================================================
--- (empty file)
+++ sandbox/dataflow-rewrite/libs/dataflow/test/generic/test_static_vector.cpp 2008-11-10 13:28:46 EST (Mon, 10 Nov 2008)
@@ -0,0 +1,20 @@
+/*=================================---------------------------------------------
+ Copyright 2008 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)
+-----------------------------------------------===============================*/
+
+
+#include "my_static_vector.hpp"
+#include <boost/type_traits/is_same.hpp>
+
+
+#define BOOST_TEST_MAIN
+#include <boost/test/unit_test.hpp>
+
+
+BOOST_AUTO_TEST_CASE( test )
+{
+}
\ No newline at end of file

Added: sandbox/dataflow-rewrite/libs/dataflow/test/vivid/Jamfile
==============================================================================
--- (empty file)
+++ sandbox/dataflow-rewrite/libs/dataflow/test/vivid/Jamfile 2008-11-10 13:28:46 EST (Mon, 10 Nov 2008)
@@ -0,0 +1,10 @@
+#==================================---------------------------------------------
+# Copyright 2008 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)
+#----------------------------------------------===============================*/
+
+
+run test_factory_window.cpp /boost_guigl//boost_guigl/<link>static ;

Added: sandbox/dataflow-rewrite/libs/dataflow/test/vivid/test_factory_window.cpp
==============================================================================
--- (empty file)
+++ sandbox/dataflow-rewrite/libs/dataflow/test/vivid/test_factory_window.cpp 2008-11-10 13:28:46 EST (Mon, 10 Nov 2008)
@@ -0,0 +1,27 @@
+/*=================================---------------------------------------------
+ Copyright 2008 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)
+-----------------------------------------------===============================*/
+
+
+#include <boost/dataflow/vivid/factory_window.hpp>
+#include <boost/dataflow/vivid/network_window.hpp>
+#include "../blueprint/my_blueprint_framework.hpp"
+#include "../generic/my_ports.hpp"
+
+#define BOOST_TEST_MAIN
+#include <boost/test/unit_test.hpp>
+
+
+BOOST_AUTO_TEST_CASE( test )
+{
+ df::vivid::factory_window<my_blueprint_framework> window;
+
+ df::blueprint::factory<my_blueprint_framework> factory;
+ factory.add_port<my_port_producer>("my_port_producer");
+
+ window.set_factory(factory);
+}


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