This page contains the list of features that we plan to implement in the future versions of Web Rule control.
The latest build of Web Rule will be available on Test.CodeEffects.com
as soon as we finish internal testing of new rule engine. The next major version of Web Rule control (version 2.0) is expected to be released sometime in December.
- MVC support (in the works) Yep, it's coming. See our comment below.
- Brand new rules engine (in the works) Even though the average performance of the current version of Web Rule is already better than most of modern systems, version 2.0 will include our brand new rule engine that shows even better speed. We will post test numbers on Twitter @CodeEffects as soon as the formal testing of this engine is finished.
- New rule XML format (in the works) To take full advantage of the new engine, Web Rule will need to store rules in a new XML format. This format is much less verbose, smaller in size and structured in a more traditional way. The old XML format will still be fully supported, though. Web Rule will automatically detect which format is used when loading a rule in the rule area for editing or in the Evaluator class for execution. Developers will have to specify which format the Web Rule control should use when rule authors save new or modified rules. We will also provide (and document) an easy way to convert the rules written in old format into the new one.
- Nested rules (in the works) Among many other things, the new engine will allow rule authors to include (or "nest") previously saved rules of evaluation type into any other rule. For example, imagine if you have previously stored the following rule named "Correct Age": Check if Person.Age is greater than 21. Now, if you create a rule to validate a Person object, you'll be able to reuse that Correct Age rule as if it would be a simple field: If Employed is True and Correct Age is True then Accept else Reject. Saving, modifying and injecting existing rules into the new ones will be implemented in a very "natural" and almost transparent to rule authors way.
- Data filtering (in the works) Initially we planned to introduce a new data filtering ASP.NET control that would use the new engine to create and execute complex filtering clauses. But at the last moment we decided to implement it as a new feature of Web Rule by providing an extension method. For example, with Web Rule embedded in a web form in "filter" mode (i.e. advanced search form, ad hoc reporting page, etc.), users of the form would be able to create a common "where" clauses using Web Rule's familiar UI: Select all employees where Salary is more than 100,000 or (Dept is Sales and Years with company is greater than 10). The form would receive this clause the same way it receives business rules now. Data can be retrieved by invoking the Filter extension method: var ems = dataSource.Filter(this.ruleControl.GetRuleXml()); Obviously, that "ems" variable could be used as a data source for some grid control or anything of that nature to display the result on the screen. We can already see that the speed of filtering will be amazing. Really powerful feature.
- Default values for rule fields (in the works) Sometimes you'd want to set the default value for a field if there is a possibility that this field's value wasn't set in the incoming instance of your source object and you'd like to avoid comparing .NET default values to rule values. The FieldAttribute and ReturnAttribute classes will have a new property of System.Object type called "DefaultValue" that developers will be able to use to set the default value for that field or return type.
- Support for Static Actions and In-Rule Methods (in the works) In current version of Web Rule only instance public methods can be used as rule actions or in-rule methods. Static public methods will be supported in version 2.0 as well, both internal and external.
- Copy and paste rule elements (will be included in version 2.1 which is due sometime in January of 2012) Rule authors will be able to move cursor anywhere inside the rule (or click there), use a combination of Ctrl-Arrow keys to select (highlight) one or more rule elements, press Ctrl-C to copy selected elements, move cursor to a different position (or click there) and Ctrl-V to insert (paste) copied elements in the new position. It's going to be tough to support this thing in all browsers but we are determined to make it happened. Having this feature in place will also allow us to implement several "dependent" features such as deletion of selected elements with Delete key, or may be even drag'n'drop selected elements into new position. More to come...
- Dynamic source for parameters (planned to be a part of version 2.1) In the current version, in-rule methods and actions allow only rule fields or user input as parameters. Those params can be of any enum type but enums are static by definition. So, if you have a list of, say, statuses somewhere in database, currently you cannot reuse that list as a source for an action's parameter. Instead, you would have to create a static Statuses enum or come up with a really complicated solution to give rule authors ability to input statuses. The proposed new feature will allow developers to set a source for any parameter. For example, if you have a method GetStatusList that returns a list of KeyValue pairs, you'll be able to set the name of this method in ParameterAttribute class. Rule authors will see a menu of statuses when they add the correspondent method or action to the rule. This feature was suggested through our Support page. Thank you, Raphael!
- Collection type fields and operators For now, please use in-rule methods to process source object's collection types during rule evaluation. The native support for IEnumerable will be implemented in one of the next versions. No details yet.
- The "between" operator This new operator will be implemented for date, time and numeric field values. No implementation details yet.
- Undo/Redo We only plan to discuss this feature. There are no details yet.
- Multiple actions per flow section We received a number of requests for multiple actions per one flow section. We agree that this can be useful for OOPing rules a little bit. So, we will implement this new feature in one of future versions. Rule example: If Name is 'John' then ActionOne and ActionTwo
- Passing in-rule methods as parameters of parent in-rule methods and actions Technically speaking, the current engine already supports this. We just need to implement it in control's UI.
Rule example: If GetZipByPhone( GetPhoneByCity( City ) ) is '30040' then ActionOne()
- Highlighting of the current rule element (implemented in version 220.127.116.11) As the rule author navigates through the rule with arrow keys, each current rule element will be highlighted with customizable background color. This will improve visibility of the current position in the rule.
- Filtering of menu items (implemented in version 18.104.22.168) All context menus in Web Rule will be "filterable" (is this a real English word at all??). Rule author will be able to press any char key to bring up the current menu already filtered by that char or filter the currently visible menu.