<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
</head>
<body bgcolor="#FFFFFF" text="#000000">
<div class="moz-cite-prefix">Ok, thanks Christian and Michael.<br>
<br>
I will have to think in a workaround to be able to use
drools-decisiontables at OSGi.<br>
<br>
regards,<br>
<br>
Cristiano<br>
<br>
On 25/03/13 19:17, Michael Anstis wrote:<br>
</div>
<blockquote
cite="mid:CAAG9P0tzejHRmkeCJfQ5w-FefvSx5uoWtY2oyOjYuRJ7c+t-tw@mail.gmail.com"
type="cite">Hello,<br>
<br>
org.apache.poi.openxml4j.exceptions.InvalidFormatException is a
checked exception from WorkbookFactory.create(inStream).<br>
<br>
I don't see how we can remove it without removing use of the
checked exception... which I guess would mean forking POI.<br>
<br>
With kind regards,<br>
<br>
Mike<br>
<br>
<div class="gmail_quote">On 23 March 2013 13:19, Cristiano Gavião
<span dir="ltr"><<a moz-do-not-send="true"
href="mailto:cvgaviao@gmail.com" target="_blank">cvgaviao@gmail.com</a>></span>
wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0
.8ex;border-left:1px #ccc solid;padding-left:1ex">
<div bgcolor="#FFFFFF" text="#000000"> Hi,<br>
<br>
I'm getting a problem with the
org.apache.poi.openxml4j.exceptions package in my osgi
things. I could not find a bundle that exports such package.<br>
<br>
Investigating a bit, the unique class that I could find
using this api is
org.drools.decisiontable.parser.xls.ExcelParser, but only
org.apache.poi.openxml4j.exceptions.InvalidFormatException
class.<br>
<br>
is this api really needed?<br>
<br>
<blockquote type="cite"> public void
parseFile(InputStream inStream) {<br>
try {<br>
Workbook workbook =
WorkbookFactory.create(inStream);<br>
<br>
if ( _useFirstSheet ) {<br>
Sheet sheet = workbook.getSheetAt( 0 );<br>
processSheet( sheet, _listeners.get(
DEFAULT_RULESHEET_NAME ) );<br>
} else {<br>
for ( String sheetName :
_listeners.keySet() ) {<br>
Sheet sheet = workbook.getSheet(
sheetName );<br>
if (sheet == null) {<br>
throw new
IllegalStateException("Could not find the sheetName (" +
sheetName<br>
+
") in the workbook sheetNames.");<br>
}<br>
processSheet( sheet,<br>
_listeners.get(
sheetName ) );<br>
<br>
}<br>
}<br>
} catch ( <b>InvalidFormatException</b> e ) {<br>
throw new DecisionTableParseException( "An
error occurred opening the workbook. It is possible that
the encoding of the document did not match the encoding of
the reader.",<br>
e );<br>
<br>
} catch ( IOException e ) {<br>
throw new DecisionTableParseException( "Failed
to open Excel stream, " + "please check that the content
is xls97 format.",<br>
e );<br>
}<br>
<br>
}</blockquote>
<br>
<br>
all other behavior is being supported by
org/apache/poi/poi/3.9/poi-3.9.jar<br>
<br>
<br>
regards,<br>
<br>
Cristiano<br>
</div>
<br>
_______________________________________________<br>
rules-dev mailing list<br>
<a moz-do-not-send="true"
href="mailto:rules-dev@lists.jboss.org">rules-dev@lists.jboss.org</a><br>
<a moz-do-not-send="true"
href="https://lists.jboss.org/mailman/listinfo/rules-dev"
target="_blank">https://lists.jboss.org/mailman/listinfo/rules-dev</a><br>
</blockquote>
</div>
<br>
<br>
<fieldset class="mimeAttachmentHeader"></fieldset>
<br>
<pre wrap="">_______________________________________________
rules-dev mailing list
<a class="moz-txt-link-abbreviated" href="mailto:rules-dev@lists.jboss.org">rules-dev@lists.jboss.org</a>
<a class="moz-txt-link-freetext" href="https://lists.jboss.org/mailman/listinfo/rules-dev">https://lists.jboss.org/mailman/listinfo/rules-dev</a></pre>
</blockquote>
<br>
</body>
</html>