<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type">
<title></title>
</head>
<body bgcolor="#ffffff" text="#000000">
Eric Miles wrote:
<blockquote cite="mid:1197572064.6440.24.camel@localhost" type="cite">
<pre wrap="">I found the issue, I was missing an import for the java.util.Iterator.
Not that good of an error message, but oh well :)
</pre>
</blockquote>
Log a JIRA with the bad error message, and what the error message
should be - and eventually we'll get round to fixing it. Better yet
submit a patch with a better error message :)<br>
<blockquote cite="mid:1197572064.6440.24.camel@localhost" type="cite">
<pre wrap="">
On Thu, 2007-12-13 at 13:50 -0500, Eric Miles wrote:
</pre>
<blockquote type="cite">
<pre wrap="">I'm having a problem with a function I'm trying to call, can someone
lend some advice? I've put together a sample rule (I know the rule
doesn't make much sense, but humor me).
When trying to compile, I get the following error:
* (1,54) unable to resolve method using strict-mode:
java.lang.Object.calculateTotal(...)
Here is the rule and accompanying function
package test;
import java.util.ArrayList;
rule "Find Marker"
        dialect "java"
        when
                $list: ArrayList()
                Integer() from calculateTotal($list, new Integer(6), new Integer(10))
        then
                logIt();
                
end
function void logIt() {
        System.out.println("FOUND!");
}
function int calculateTotal(ArrayList numbers, Integer val1, Integer
val2) {
        int total = 0;
        Iterator it = numbers.iterator();
        while(it.hasNext()) {
                Integer i = (Integer)it.next();
                total += i.intValue();
        }
        return total;
}
Thanks in advance,
Eric
</pre>
</blockquote>
<pre wrap=""><!---->_______________________________________________
rules-users mailing list
<a class="moz-txt-link-abbreviated" href="mailto:rules-users@lists.jboss.org">rules-users@lists.jboss.org</a>
<a class="moz-txt-link-freetext" href="https://lists.jboss.org/mailman/listinfo/rules-users">https://lists.jboss.org/mailman/listinfo/rules-users</a>
</pre>
</blockquote>
<br>
</body>
</html>