Search the web
Sign In
New User? Sign Up
xrules · XRules & DynamicDOM
? Already a member? Sign in to Yahoo!

Yahoo! Groups Tips

Did you know...
Show off your group to the world. Share a photo of your group with us.

Best of Y! Groups

   Check them out and nominate your group.
Having problems with message search? Fill out this form to ensure your group is one of the first to be migrated to the new message search system.

Messages

  Messages Help
Advanced
Rule Categories   Message List  
Reply | Forward Message #38 of 74 |
RE: [xrules] Re: Rule Categories

Opps, sorry for that.CategoriesList.cs” is checked in now.

 

Waleed

 

 

-----Original Message-----
From: xrules@yahoogroups.com [mailto:xrules@yahoogroups.com] On Behalf Of mike61079
Sent: Monday, July 03, 2006 9:30 AM
To: xrules@yahoogroups.com
Subject: [xrules] Re: Rule Categories

 

This is great news! As you know I have been wanting this and will put
it to good use. I will let you know how it works out.

Right now though I am unable to compile because I think
"CategoriesList.cs" is not checked in. Could you check this?

--- In xrules@yahoogroups.com, "Waleed K.
Abdulla" <waleed_abdulla@...> wrote:
>
> Hi everyone,
> This is to announce the latest new feature: Rule Categories. The
> updated source code is available at http://dynamicdom.tigris.org/
>
> Rule categories address the requirement for categorizing failed
> rules into errors vs. warnings, but it also allows for a much more
> flexible categorization such as "catastrophic, critical,
recoverable" or
> "user, system" or "General, Financial, UserDetails". etc.
Basically, you
> choose your own categorization system. Here is an example:
>
>
> <xr:ruleset context="/PurchaseOrder">
> <xr:validate test="..." categories="error" />
> <xr:validate test="..." categories="warning" />
> </xr:ruleset>
>
> If the first rule fails, for example, the error report will show the
> error as follows (notice the categories attribute):
>
> <xrr:error context="/PurchaseOrder" categories="error">
> <xrr:message>...</xrr:message>
> <xrr:node path="..." />
> </xrr:error>
>
>
>
>
> You can also categorize a rule under several categories by using a
> space-separated list of categories:
>
> <xr:validate test="..." categories="error financial" />
>
>
>
> Categories are also inherited from parent rulesets. For example:
>
> <xr:ruleset context="/PurchaseOrder" categories="header">
> <xr:validate test="..." categories="error" />
> <xr:validate test="..." categories="warning" />
> </xr:ruleset>
>
>
> Or inherited from several up levels of rulesets:
>
> <xr:ruleset context="/PurchaseOrder/Item" categories="item">
>
> <xr:ruleset context="ItemDetails"
categories="financial">
> <xr:validate test="..." />
> </xr:ruleset>
>
> </xr:ruleset>
>
>
> In this example, although the rule does not have the 'categories'
> attribute, it inherits the "item" and "financial" categories. If
this
> rule fails, the error report will show the error as:
>
> <xrr:error context="ItemDetails" categories="financial item">
> <xrr:message>...</xrr:message>
> <xrr:node path="..." />
> </xrr:error>
>
>
>
> And, in the XRules Object Model you can access the categories using
the
> "Catagories" property of rule classes. Or, use the
"EffectiveCategories"
> property to get the rule categories including all categories
inherited
> from parent rulesets.
>
> // Iterate though the categories of a rule.
> CategoriesList cat = myRule.EffectiveCategories;
> if (cat.Count > 0)
> {
> foreach(string category in cat)
> {
> // Iterate through the categories.
> }
> }
>
>
> Hope you find this feature useful.
>
> Regards,
> Waleed
>



Mon Jul 3, 2006 10:36 pm

waleed_ka
Offline Offline
Send Email Send Email

Forward
Message #38 of 74 |
Expand Messages Author Sort by Date

Hi everyone, This is to announce the latest new feature: Rule Categories. The updated source code is available at http://dynamicdom.tigris.org/ Rule categories...
Waleed K. Abdulla
waleed_ka
Offline Send Email
Jul 2, 2006
9:42 am

This is great news! As you know I have been wanting this and will put it to good use. I will let you know how it works out. Right now though I am unable to...
mike61079
Offline Send Email
Jul 3, 2006
4:50 pm

Opps, sorry for that. "CategoriesList.cs" is checked in now. Waleed ... From: xrules@yahoogroups.com [mailto:xrules@yahoogroups.com] On Behalf Of mike61079 ...
Waleed K. Abdulla
waleed_ka
Offline Send Email
Jul 3, 2006
10:37 pm
Advanced

Copyright © 2009 Yahoo! Inc. All rights reserved.
Privacy Policy - Terms of Service - Guidelines - Help