<html><head><meta http-equiv="Content-Type" content="text/html charset=us-ascii"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><div>Hi,</div><div><br></div><div>I am looking at the new Kie API and I am trying to work out how I tell it / Drools that I have a RuleMatrixSheet .. </div><div><br></div><div><!--?xml version="1.0" encoding="UTF-8" standalone="no"?-->
<a href="https://github.com/droolsjbpm/drools/blob/master/drools-decisiontables/src/main/java/org/drools/decisiontable/parser/RuleMatrixSheetListener.java" style="font-family: Arial; ">https://github.com/droolsjbpm/drools/blob/master/drools-decisiontables/src/main/java/org/drools/decisiontable/parser/RuleMatrixSheetListener.java</a></div><div><br></div><div>This was the old way (a bit manual) </div><div><br></div><div><!--?xml version="1.0" encoding="UTF-8" standalone="no"?-->
<div style="margin: 0px; font-size: 11px; font-family: Monaco; "> <span style="color: rgb(147, 26, 104);">final</span> SpreadsheetCompiler converter = <span style="color: rgb(147, 26, 104);">new</span> SpreadsheetCompiler();
</div><div style="margin: 0px; font-size: 11px; font-family: Monaco; "> <span style="color: rgb(147, 26, 104);">final</span> InputStream stream = <span style="color: rgb(147, 26, 104);">this</span>.getClass().getResourceAsStream( <span style="color: rgb(57, 51, 255);">"/path/to/spreadsheet.xls"</span> );
</div><div style="margin: 0px; font-size: 11px; font-family: Monaco; "> <span style="color: rgb(147, 26, 104);">final</span> String drl = converter.compile( stream,
</div><div style="margin: 0px; font-size: 11px; font-family: Monaco; "> InputType.<span style="color: rgb(3, 38, 204);">XLS</span>,
</div><div style="font-family: Arial; "><span style="font-family: Monaco; font-size: 11px;"> </span><span style="font-family: Monaco; font-size: 11px; color: rgb(147, 26, 104);">new</span><span style="font-family: Monaco; font-size: 11px;"> RuleMatrixSheetListener() );</span></div></div><div style="font-family: Arial; "><span style="font-family: Monaco; font-size: 11px;"><br></span></div><div>Is there an example of a matrix style Spreadsheet being used to generate the rules, with the new Kie APIs ? </div><div><br></div><div>I can't seem to find similar concepts on the <span style="font-family: Monaco; font-size: 11px; ">ResourceFactory </span>API, or on "<span style="font-family: Monaco; font-size: 11px; ">Resource" </span></div><div><br></div><div>Version 5 and version 6 don't really "support" the Configuration object understanding the Matrix Style Rules table.</div><div><br></div><div>If it were to be implemented, it looks like :</div><div><br></div><div><div style="margin: 0px; font-size: 11px; font-family: 'Lucida Grande'; "> org.kie.api.builder.KieFileSystem</div></div><div style="margin: 0px; font-size: 11px; font-family: 'Lucida Grande'; "><br></div><div style="margin: 0px; font-size: 11px; font-family: 'Lucida Grande'; ">needs some changes, to support the compilation of a Rule Matrix where write* is taking a Resource, </div><div><br></div><div>If there is not an Example, what do I need to "wire" together for this.</div><div><br></div><div>Any pointers are much appreciated.</div><div><br></div><div>Kind regards</div><div>Ramon</div><div><br></div><br><div apple-content-edited="true">
<span class="Apple-style-span" style="border-collapse: separate; border-spacing: 0px; "><div>Ramon Buckland</div><div><a href="mailto:ramon@thebuckland.com">ramon@thebuckland.com</a></div><div><br></div></span><br class="Apple-interchange-newline">
</div>
<br></body></html>