[rules-users] equals not working properly
Sikkandar Nawabjan
Sikkandar.Nawabjan at ust-global.com
Mon Nov 19 05:00:55 EST 2007
Hi,
i have a strange problem.i have the rule like this
package com.sample
import com.sample.Message;
rule "Hello World"
dialect "mvel"
when
$m : Message( $message1 : message,$id1 : id )
$mdup : Message(id != $id1, this != $m)
then
System.out.println("Rule Fired_------>>>>>"+$id1+"::::");
end
I override equals method in my Message Class.
In the above rule if i put this==$m the equals method is not called by engine
But if i put this!=$m it is called by Engine. In both the cases i have id=1 and id1=2.
why it is behaving strange way
Thanks and Regs
Basha
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/ms-tnef
Size: 4314 bytes
Desc: not available
Url : http://lists.jboss.org/pipermail/rules-users/attachments/20071119/71360da9/attachment.bin
More information about the rules-users
mailing list