[jboss-svn-commits] JBL Code SVN: r26279 - labs/jbossrules/trunk/drools-docs/drools-docs-expert/src/main/docbook/en-US/Chapter-Quick_Start.

jboss-svn-commits at lists.jboss.org jboss-svn-commits at lists.jboss.org
Mon Apr 27 09:21:06 EDT 2009


Author: laune
Date: 2009-04-27 09:21:05 -0400 (Mon, 27 Apr 2009)
New Revision: 26279

Modified:
   labs/jbossrules/trunk/drools-docs/drools-docs-expert/src/main/docbook/en-US/Chapter-Quick_Start/Section-The_Basics.xml
Log:
add missing addKnowledgePackages call

Modified: labs/jbossrules/trunk/drools-docs/drools-docs-expert/src/main/docbook/en-US/Chapter-Quick_Start/Section-The_Basics.xml
===================================================================
--- labs/jbossrules/trunk/drools-docs/drools-docs-expert/src/main/docbook/en-US/Chapter-Quick_Start/Section-The_Basics.xml	2009-04-27 13:19:00 UTC (rev 26278)
+++ labs/jbossrules/trunk/drools-docs/drools-docs-expert/src/main/docbook/en-US/Chapter-Quick_Start/Section-The_Basics.xml	2009-04-27 13:21:05 UTC (rev 26279)
@@ -112,14 +112,16 @@
               ResourceType.DRL );
 if ( kbuilder.hasErrors() ) {
     System.err.println( builder.getErrors().toString() );
-}  </programlisting>
+}
+kbase.addKnowledgePackages( kbuilder.getKnowledgePackages() );</programlisting>
 
       <para>The above code snippet looks on the classpath for the 
       <filename>licenseApplication.drl</filename>
       file, using the method <code>newClassPathResource()</code>. The resource type
       is DRL, short for "Drools Rule Language". Once the DRL file has been added
       we can check the Knowledge Builder object for any errors. If there are no
-      errors, we are now ready to build our session and execute against some
+      errors, we can add the resulting packages to our Knowledge Base.
+      Now we are ready to build our session and execute against some
       data:</para>
 
       <programlisting>StatelessKnowledgeSession ksession = kbase.newStatelessKnowledgeSession();
@@ -405,7 +407,8 @@
               ResourceType.DRL );
 if ( kbuilder.hasErrors() ) {
     System.err.println( builder.getErrors().toString() );
-}  
+}
+kbase.addKnowledgePackages( kbuilder.getKnowledgePackages() );
 StatefulKnowledgeSession ksession = kbase.newStatefulKnowledgeSession();</programlisting>
 
       <para>With the session created it is now possible to iteratvely work




More information about the jboss-svn-commits mailing list