Hi,

the following code traverses rules and their conditions. However, I did not
find a method to find conditions, that match over a certain field of a
declared class. I know, that the rule API should be hidden for good reasons
(Mark Proctor).

for(Rule ruleDef : kb.getKnowledgePackages().iterator().next().getRules()) {
    for(RuleConditionElement rce :
((RuleImpl)ruleDef).getRule().getLhs().getChildren()) {
        for(Map.Entry<String, Declaration> entry :
rce.getInnerDeclarations().entrySet()) {
            ??

Thanks, Marc







--
View this message in context: 
http://drools.46999.n3.nabble.com/How-to-find-rules-that-use-special-fields-in-their-Condition-tp4023673.html
Sent from the Drools: User forum mailing list archive at Nabble.com.
_______________________________________________
rules-users mailing list
rules-users@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-users

Reply via email to