This project is read-only.
Project Description
We may want to allow user to add some dynamic logic in a business application. One of the solutions is to use script codes. Of course, the script code should be simple and small and it also can use data and function out of the script self.

The componet is implemented with C#. And the core script parser is implemented with regular expression, which is different from many other script engines. Though the regular expression parser may meet problems to parse complex script code, it's fast and enough in most of times.

Key Features
The component consider every element in the script as an "expression", such an integer value, a function call.

Expression is the basic class in this script engine. Other script language elements extend Expression class. Like the IntegerExpression, is the expression to present a "integer" constant value in script runtime.

A script snippet is compliled to an expression tree. The whole script snippet is also considered as an expression object, which is the root node of the grammar tree. The compiled expression object will be evaluated to output result.

External data provider and function
The script engine may plug in data proivders and function pools. External data provider acts the list of runtime context with data or available values. And it also can be the script's input and output cache. External functions provide more computation processes to script at runtime. Plug different data providers or functions to a compiled script will no change the script's logic but the runtime context.

Why a new script engine
Yes, there are many many script engines around the world. So why do I need this new script engine?
1 It's lightweight. We may just need the simple functions but we don't need a lot of complex but useless functions from a huge script engine.
2 Self define the script language grammar.
3 Easy to extend. Just write a new expression class to do something new.

More information about it at

Last edited Jun 13, 2010 at 7:52 AM by changwang23, version 3