I found an interesting implementation to do that. If anyone is interested I
could share my solution.
Regards,
CG
Mark Proctor wrote:
>
> There is no supported way to do this. You could use an inline-eval
> against a global, but that is very clunkey. However it does seem like a
> good featur
Any suggestions / guidance for the below question ?
pns77 wrote:
>
> Hi,
>
> The following is the block of code that i tried
>
> RuleBase ruleBase = readRule();
> WorkingMemory workingMemory =
> ruleBase.newStatefulSession(false); // to keep reference
> //
Hi Eric, after some tests I noticed that in java language you can't
import the same class name twice even if the class is defined in
different packages, ie try creating a java file and import both
java.awt.List and java.util.List, it won't work, you will get a
similar error from javac compi
Hi,
My understanding is that time window rule is not supported yet in 4.0 after
checking the manual and followed some blogs regarding SEP/CEP. I wonder if
some workaround can be done for simple case such as collect some similar events
over 1 minute. Will time window feature be included soon?
btw you don't need janino if you have jdt core. This is standard java,
there is no reason for this not to work, must be the way you are setting
up your classpath. Btw there is the 4.0.1 SNAPSHOT available now. Did
you rememer to add mvel?
http://cruisecontrol.jboss.com/cc/artifacts/jboss-rules
I had exactly the same problem when I was evaluating the submissions
from last round. Here is a fragment from my .bashrc:
export DROOLS_HOME=/home//drools-4.0.0.SNAPSHOT-bin.zip_FILES/
export
CLASSPATH=$CLASSPATH:$DROOLS_HOME/drools-compiler-4.0.0.SNAPSHOT.jar:$DROOLS_HOME/drools-core-4.0.0.S
I've tried that. I copied all the drools jars (14 of them) into a directory
and then used that on the classpath - didn't work.
I also searched for every jar file on my Mac, put them all in there and
tried again - failed.
It's only Drools I have a problem with, anything else I create works fine.
I assume you also insert s1 and m1 to working memory?
What if you re-write the rule as two patterns (there is an implicit AND
between patterns)
Rule:
$student : Student()
Module( student == $student && score > 40 ) )
With kind regards,
Mike
-Original Message-
From: [EMAIL PROTECTED]
[
Given:
Student.java
public class Student {
private String name;
private ArrayList modules = new ArrayList();
...
}
Module.java
public class Module {
private String name;
private Student student;
private int score;
...
}
Rule:
exists( $student : Student() && Module( student
Basically the classes you are using are not present in your applications
classpath.
Put all the drools jar files and the dependent jar files in the class path
and run.
java -classpath drools.jar;drools-compiler.jar;;SonsAgesPuzzle.jar
<<(optionally classname here)>>
Hope this works.
Thanks
Hi,
I downloaded the two examples. If I try to run the jar one I get the
classdefnotfound error:
java -jar SonsAgesPuzzle.jar
Exception in thread "main" java.lang.NoClassDefFoundError:
org/drools/WorkingMemory
Any ideas? I get this whenever I try to run my own Drools stuff outside
ecl
11 matches
Mail list logo