use of org.apache.camel.component.flatpack.DataSetList in project camel by apache.
the class FlatpackDataFormat method unmarshal.
public Object unmarshal(Exchange exchange, InputStream stream) throws Exception {
InputStreamReader reader = new InputStreamReader(stream, IOHelper.getCharsetName(exchange));
try {
Parser parser = createParser(exchange, reader);
DataSet dataSet = parser.parse();
return new DataSetList(dataSet);
} finally {
reader.close();
}
}
Aggregations