From e471ca130991ae85b83d68d042f12ef0b525760f Mon Sep 17 00:00:00 2001 From: Marcus Winter Date: Mon, 22 Feb 2016 16:03:46 +0100 Subject: [PATCH] examples: changed dataflow example to show usage of Network::Make --- doc/examples/dataflow/dataflow_linear-fragmented.cc | 1 + doc/examples/dataflow/dataflow_make-snippet.h | 1 + doc/examples/dataflow/dataflow_network-snippet.h | 2 +- doc/examples/dataflow/dataflow_nonlinear-fragmented.cc | 1 + 4 files changed, 4 insertions(+), 1 deletion(-) create mode 100644 doc/examples/dataflow/dataflow_make-snippet.h diff --git a/doc/examples/dataflow/dataflow_linear-fragmented.cc b/doc/examples/dataflow/dataflow_linear-fragmented.cc index 25bdacd..2ce8b93 100644 --- a/doc/examples/dataflow/dataflow_linear-fragmented.cc +++ b/doc/examples/dataflow/dataflow_linear-fragmented.cc @@ -57,5 +57,6 @@ void RunDataflowLinear() { #include "dataflow/dataflow_declare_sink-snippet.h" #include "dataflow/dataflow_connect-snippet.h" #include "dataflow/dataflow_add-snippet.h" +#include "dataflow/dataflow_make-snippet.h" #include "dataflow/dataflow_run-snippet.h" } diff --git a/doc/examples/dataflow/dataflow_make-snippet.h b/doc/examples/dataflow/dataflow_make-snippet.h new file mode 100644 index 0000000..c132ce0 --- /dev/null +++ b/doc/examples/dataflow/dataflow_make-snippet.h @@ -0,0 +1 @@ + nw.Make(2); diff --git a/doc/examples/dataflow/dataflow_network-snippet.h b/doc/examples/dataflow/dataflow_network-snippet.h index c13ebeb..3e36693 100644 --- a/doc/examples/dataflow/dataflow_network-snippet.h +++ b/doc/examples/dataflow/dataflow_network-snippet.h @@ -1,2 +1,2 @@ -typedef embb::dataflow::Network<2> Network; +typedef embb::dataflow::Network Network; static Network nw; diff --git a/doc/examples/dataflow/dataflow_nonlinear-fragmented.cc b/doc/examples/dataflow/dataflow_nonlinear-fragmented.cc index e7f419d..206c54e 100644 --- a/doc/examples/dataflow/dataflow_nonlinear-fragmented.cc +++ b/doc/examples/dataflow/dataflow_nonlinear-fragmented.cc @@ -83,5 +83,6 @@ void RunDataflowNonLinear() { process5.GetOutput<1>() >> sink1.GetInput<2>(); process4.GetOutput<1>() >> sink1.GetInput<3>(); + nw.Make(2); nw(); } -- libgit2 0.26.0