Regretfully, no: import static is not implemented.
Consider using a DRL function to wrap the call of the static method,
to achieve a shorter call.
-W
2010/7/18 Meeraj Kunnumpurath <mkunnumpurath(a)googlemail.com>:
Hi,
Are static imports as shown below allowed in rule files? It is giving me a
parse exception.
package mypackage;
dialect "mvel"
import mypackage.CreditTransferTransactionInformation10;
import static mypackage.ValidationHelper.invalidate;
global java.util.Set accountNumbers;
rule "Check debtor account number is not null"
salience -1
when
$c : CreditTransferTransactionInformation10 ( eval(
dbtrAcct.?id.?othr.?id == null ) )
then
invalidate($c, "PG003", "Account number is absent");
drools.halt();
end
Ta
Meeraj
_______________________________________________
rules-users mailing list
rules-users(a)lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-users