[rules-users] Guvnor and drools implementation - questions

ioda100 eddyhautot at gmail.com
Tue Mar 1 07:27:09 EST 2011


Hi,

i have a few questions :

1) my facts are in fact java Maps, is there an easy way to deal with them in
guvnor? it's not like in the example where facts are objects and we give
guvnor the Pojo model to know what we can do with it

for example i have :
$m  : Map((this["attribute1_of_the_map"] == "test1"))

How to deal with the map and have a prepopulated list of properties of the
map? And to store it in the variable $m. Without using the "free from drl"
where we have to write it by hand.

2) how to deal with global constant with guvnor?

i have something like :
WorkingMemory wm = drools.getWorkingMemory();
wm.setGlobal("resultValue", "OK");

Is it a direct way to play with global constant in Guvnor? Without using the
"free from drl" where we have to write it by hand.

3) for stopping firing rules after one rule fire successfully, do you know
if there is an option to do that?
For now i insert a boolean in the session and the first condition in all my
rules is that this boolean is there. When a rule fires successfully, i
retract it. I suppose there is a bettre way to do it?

Thanks in advance for your help 

-- 
View this message in context: http://drools-java-rules-engine.46999.n3.nabble.com/Guvnor-and-drools-implementation-questions-tp2602641p2602641.html
Sent from the Drools - User mailing list archive at Nabble.com.



More information about the rules-users mailing list