"resources/summerland.xml");
ByteArrayOutputStream out = new ByteArrayOutputStream();
MarcStreamWriter writer = new MarcStreamWriter(out);
MarcXmlReader reader = new MarcXmlReader(input);
while (reader.hasNext()) {
Record record = reader.next();
writer.write(record);
}
input.close();
writer.close();
ByteArrayInputStream in = new ByteArrayInputStream(out.toByteArray());
MarcStreamReader marcReader = new MarcStreamReader(in);
MarcStreamWriter marcWriter = new MarcStreamWriter(System.out);
while (marcReader.hasNext()) {
Record record = marcReader.next();
marcWriter.write(record);
}
in.close();
marcWriter.close();