I want to store the details of college courses in a (MySql) database but I\'m not sure how to maintain the relationship between modules and selections.
Basically, a cour
A production quality system using and/or's (like your system) that you can review for free is entlib 5.0 Security block. http://entlib.codeplex.com/
Each rule is retrieved by name to get the full expression. the patterns & practice team created their own short DSL for the expression to avoid complicating the xml structure/db structure.
this is inside the hands on labs exercise ex02 app.config. To store rules inside the database you would need to implement a custom AuthorizationRuleProvider.
R: = rolename; U: = username
dev usage
public static AssignBug Create()
{
// TODO: Check Authorization
if (!SecurityHelper.Authorized(AuthRule.Assign))
{
throw new SecurityException();
}
return new AssignBug();
}
While not an immediate answer I think this provides a good example of how to implement rule-expression based systems.