Ok got it,
Thanks alot.
Regards
Manohar Kokkula
Mailto: manohar.kokkula(a)tcs.com
From:
Tan Hui Onn <huionn(a)gmail.com>
To:
Rules Users List <rules-users(a)lists.jboss.org>
Date:
09/23/2011 04:39 PM
Subject:
Re: [rules-users] Exception in Banking Tutorial in Drools expert guide...
Sent by:
rules-users-bounces(a)lists.jboss.org
Obviously, it should be for (int i=0; i < facts.length;i++), right?
2011/9/23 Manohar Kokkula <manohar.kokkula(a)tcs.com>
Hi,
I am trying to execute Banking Tutorial Example given in Drools expert(
http://downloads.jboss.com/drools/docs/5.0.1.26597.FINAL/drools-expert/ht...
),but im getting following error,
Exception in thread "main" java.lang.ClassCastException:
java.util.ArrayList cannot be cast to org.hibernate.mapping.Collection
at com.sample.RuleRunner.runRules(RuleRunner.java:32)
at com.sample.Example1.main(Example1.java:5)
And when i try to resolve this i am getting another error:
java.lang.ArrayIndexOutOfBoundsException: 0
at com.code.RuleRunner.runRules(RuleRunner.java:45)
at com.code.Example1.main(Example1.java:5)
Code snippet :
for (int i=0; i <=facts.length;i++)
{
System.out.println("222");
Object fact = facts[i]; //The error is for this line of
code
System.out.println( "Inserting fact: " + fact );
ksession.insert(fact);
System.out.println("333");
}
could any body help me on this.
Manohar Kokkula
Mailto: manohar.kokkula(a)tcs.com
=====-----=====-----=====
Notice: The information contained in this e-mail
message and/or attachments to it may contain
confidential or privileged information. If you are
not the intended recipient, any dissemination, use,
review, distribution, printing or copying of the
information contained in this e-mail message
and/or attachments to it are strictly prohibited. If
you have received this communication in error,
please notify us by reply e-mail or telephone and
immediately and permanently delete the message
and any attachments. Thank you
_______________________________________________
rules-users mailing list
rules-users(a)lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-users
_______________________________________________
rules-users mailing list
rules-users(a)lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-users