[rules-users] Packages using, drools-ant vs. brms?

Małecki krokodylowy3 at wp.pl
Thu Feb 21 07:51:24 EST 2008


Hi

How to correct load packages generated by drools-ant?
I got no problem with importing packages from brms.

I try method below. Rules are loaded but not all are executed as in
classic java test.

File pkgFile = new File("c:/(...)/drools_test.rules.pkg");
ObjectInputStream in = new
DroolsObjectInputStream(newFileInputStream(pkgFile));
RuleBase p1_ = (RuleBase) in.readObject();


Second test (below) give me error
"org.drools.compiler.PackageBuilder$MissingPackageNameException:
Missing package name for rule package."

ObjectInputStream is = new DroolsObjectInputStream(new
FileInputStream(pkgFile));
RuleBaseLoader loader = RuleBaseLoader.getInstance();
RuleBase ruleBase = loader.loadFromReader(new InputStreamReader(is));
		
Any solution?

----------------------------------------------------
Mucha zaręczyła się z Wojewódzkim?
http://klik.wp.pl/?adr=http%3A%2F%2Fcorto.www.wp.pl%2Fas%2Fzareczyny.html&sid=230





More information about the rules-users mailing list