WF4.0 provides a lightweight process for invoking workflows. One of the limitations of WF3.x was the overhead that was inherited when executing workflows. "WorkflowInvoker.Invoke" opens the door for inherited benefits and functionality for building business logic through Windows Workflow Foundation. WorkflowInvoker makes it as simple as calling a method for processing workflows synchronous. Take the below flowchart workflow. Flowchart workflows is a new style of workflows introduced in WF4.0, however the concept of flowchart workflows in general match the way we design software, making the learning curve of building them trivial.
This workflow determines of someone is old enough to do "x", by determining if someone is older than 21.
We can process this workflow very easily by calling the below code and taking advantage of WorkflowInvoker.
Now we can write business logic visually instead of plain old code and calling it just like any other method!