=================== The Pattern in .NET =================== .. code-block:: c# using E2c; Configuration via DSL --------------------- The configuration determines the data flow. .. code-block:: c# var config = new string[] { ".run -- action", " action.render -- render", " render.output -- .out", " action.log -- log", " log.store -- .out" }; Actors ------ Each function represents an actor. .. code-block:: c# public class Actors { public void Action( string data, Output render, Output store) { render.Invoke(data); Console.WriteLine( string.Format("{0} in Action', data)); log.Invoke("render done"); } public void Render(string data) { Console.WriteLine( string.Format("{0} in Render', data)); } public void Store(int id, string data) { Console.WriteLine( string.Format("{0} and {1} in Store', id, data)); } } Graph ------ .. code-block:: c# var actors = new Actors(); var graph = new Graph(config); graph.Actor("action", actors.Action); graph.Actor("render", actors.Render); graph.Actor("store", actors.Store); Visualize --------- .. code-block:: python graph.Visualize(); .. image:: /_static/quickstart2.png :align: center Run the flow ------------ .. code-block:: python graph.Run("Hello"); .. code-block:: bash $ Hello in Render $ Hello in Action $ Hello and 1 in Store