Josh Lane on .NET RSS 2.0
 Friday, February 29, 2008

My little side project is finally ready for others to poke around with:

TextFlow - www.codeplex.com/TextFlow

The main idea behind TextFlow is to allowing authoring of WF programs (workflows) via a language syntax, as opposed to (or, eventually, in addition to) using the drag-and-drop designer. The designer is great for many users, but there are times when a terse language syntax would be useful too.

Here's a (mostly) simple Hello World in TextFlow syntax:

SET x = 10

INPARALLEL

START IF x > 100 THEN [HelloWorld] ENDIF END

START IF x < 100 THEN [GoodbyeWorld] ENDIF END

ENDPARALLEL

This is a slightly gratuitous example that executes a WF ParallelActivity with two IfElseActivity children; the square bracket syntax allows execution of configured external activities (in this case, ones that simply display messages of some sort). You get the idea. The actual generated workflow looks like this:

image

The project includes an authoring tool that let's you toggle between syntax view and workflow view; workflow view is read-only at this point, but I hope to enable bi-directional updating eventually.

The code is a definite work in progress... it's not much more than prototype quality at this point. So don't expect to launch the space shuttle with it anytime soon, but if you have an interest in any of the following, you might find something worth your trouble:

- using ANTLR-generated lexers and parsers in C# (if you've only ever used lex and yacc, you need to see ANTLRWorks)

- hosting the WF designer in a WinForms app (not sure my code should be reference material for this :-) )

- a real-world use for .NET 3.5 expression trees (very cool stuff)

I'll be blogging more on this in the coming weeks, as I continue to work on the code. For further details, visit www.codeplex.com/TextFlow.

Feedback is welcome and appreciated!

Friday, February 29, 2008 11:03:02 PM (Eastern Standard Time, UTC-05:00)  #    Comments [0] -

Comments are closed.
Disclaimer

Don't blame my employer(s)... all of this is my fault.

© Copyright 2008 Josh Lane
Sign In
Locations of visitors to this page
DasBlog theme 'Business' created by Christoph De Baene (delarou)