@Override public void setSource(final RandomAccessInputStream stream, final SCIFIOConfig config) throws IOException { super.setSource(ZipUtilities.getRawStream(locationService, stream), config); if (reader != null) reader.close(); final String baseId = ZipUtilities.unzipId(locationService, stream, null); try { reader = formatService.getFormat(baseId, config).createReader(); reader.setSource(baseId, config); } catch (final FormatException e) { log().error("Failed to set delegate Reader's source", e); } }
@Override public Metadata parse( final RandomAccessInputStream stream, final Metadata meta, final SCIFIOConfig config) throws IOException, FormatException { return super.parse(ZipUtilities.getRawStream(locationService, stream), meta, config); }