Hi,
I've been using drools 4.07 for a while. I have found a weird case. It
seems that when evaluating the LHS some fact is true but the RHS probes
it wasn't actually true.
The example code is at the end. It is very weird to me I have no clue
about how to solve this or what could be happening!
rule "A-Rule"
no-loop true
ruleflow-group "validate-task"
salience -9999999
when
$task : Task( type == "Creacio_Profile_Radius" )
eval($task.getParameter("PRIMARYDNS")==null)
then
System.out.println(">>>DBGPar0:
"+$task.getTechnicalParams().get(0).getName());
System.out.println(">>>DBGPar1:
"+$task.getTechnicalParams().get(1).getName());
System.out.println("Getparam PRIMARYDNS:
"+$task.getParameter("PRIMARYDNS"));
end
further explanation:
The Task class has a List<Parameter> technicalParams, originally the
eval part was:
not(Parameter (name=="PRIMARYDNS") from $task.technicalParams())
it didn't work and I coded this "getParameter" method just to make some
tests. So, it seems the collection appears "empty" to the LHS but in
fact it isnt!
any clue?
thanks a lot,
Javier