Well, in the end it's all Java, so why should there be a better method? ;-)
I find that writing the constructors of fact objects so that they avoid
null values by setting fields to appropriate "Null" objects improves
things somewhat. In your case perhaps
CitatioDTO(){
charge = Charge.NO_CHARGE;
...
}
and class Charge contains
public static final NO_CHARGE = Charge( "",... );
-W
Hello,
Is there an easy way to test if a String value is empty? I've been doing this (Drools 4.0.7):
when CitationDTO
(
charge != null &&
charge.drivingIncidentLegalSpeedRate != null &&
charge.drivingIncidentLegalSpeedRate != ""
)
then ......
It seems like there has to be a better method.
Thanks,
Jason
_______________________________________________
rules-users mailing list
rules-users@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-users