For this particular cases, if I modify the safeEquals method to be something
like this, the test case would success, what is the disadvantage to add
converters like this, any hint? 

    private static Boolean safeEquals(final Object val1, final Object val2)
{
        if (val1 != null) {
            if (DataConversion.canConvert(val2.getClass(), val1.getClass()))
{
                return val2.equals(DataConversion.convert(val1,
val2.getClass()));
            }
            return val1.equals(val2) ? Boolean.TRUE : Boolean.FALSE;
        }
        else return val2 == null || (val2.equals(val1) ? Boolean.TRUE :
Boolean.FALSE);
    }

-----
Ivan, your Panda, forever
--
View this message in context: 
http://drools.46999.n3.nabble.com/MVEL-the-data-converter-does-not-work-tp3581797p3581928.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