private void doOutput(String functionName, Object[] arguments, boolean byRef, OutputStream ostream) throws IOException {
if (filter != null) ostream = filter.outputFilter(ostream);
HproseWriter hproseWriter = new HproseWriter(ostream, mode);
ostream.write(HproseTags.TagCall);
hproseWriter.writeString(functionName, false);
if ((arguments != null) && (arguments.length > 0 || byRef)) {
hproseWriter.reset();
hproseWriter.writeArray(arguments, false);
if (byRef) {
hproseWriter.writeBoolean(true);