public static final String VERSION = "$Header$";
protected void process(String exepath, String[] args) throws Exception {
BufferObjectReader in = new BufferObjectReader(getStdIn());
BufferOutputStream out = getStdOutStream();
CBZip2OutputStream bout = new CBZip2OutputStream(out);
ObjectOutputStream oout = new ObjectOutputStream(bout);
Object obj;
try {
while( !in.isFinished() ) {
obj = in.readObject();
oout.writeObject(obj);
oout.flush();
bout.flush();
out.flush();
}
in.close();
} catch (Exception e) {
if(canThrowEx()) {
throw e;
} else {
org.jboss.fresh.io.BufferWriter bw = new BufferWriter(getStdOut());
PrintWriter tOut = new PrintWriter(bw);
tOut.write(e.toString());
}
}
oout.close();
bout.close();
out.close();
}