Polymod.NET is an non-intrusive framework written in C# that gives you excel-like ability to add 'Formulas' to existing domain objects. Polymod.NET will wrap POCO into self-updating and self-validating models so you don't have to wire up INotifyPropertyChanged or IDataErrorInfo manually.How does it work?
Polymod.NET creates a dynamic wrapper for a given type. The wrapper exposes all properties of the wrapped object and can also contain formulas that interrogate the wrapped object's properties. The formulas are self-notifying, so that defining formula C = A + B means that C will change if either A or B changes. You do not have to wire up INotifyPropertyChanged and fire up PropertyChanged, the wrapper handles that for you very elegantly.Validation
Polymod.NET uses RulesEngine
project to add validation to the wrappers. The wrapper implements IDataErrorInfo, which interrogates the rules for validity.SamplesSample 1
: Shows how you can have POCO Order, OrderItem domain objects, use Polymod.NET to add metadata, and result in a self-updating, self-validating WPF UI.