try {
final File temp = File.createTempFile("enhancer", ".class");
out = new BufferedOutputStream(new FileOutputStream(temp));
//enhance
final OutputStreamWrapper wrapper = new OutputStreamWrapper(out);
final boolean enhanced = enhancer.enhanceClassFile(in, wrapper);
closeOutputStream(out);
out = null;
createOutputFile(enhanced,
getClassFileName(wrapper.getClassName()), temp);
} finally {
closeInputStream(in);
closeOutputStream(out);
}
}