Package org.wildfly.httpclient.common
Class NoFlushByteOutput
- java.lang.Object
-
- org.wildfly.httpclient.common.NoFlushByteOutput
-
- All Implemented Interfaces:
Closeable,Flushable,AutoCloseable,org.jboss.marshalling.ByteOutput
public class NoFlushByteOutput extends Object implements org.jboss.marshalling.ByteOutput
An output stream that ignores flushes. The marshsaller will flush when it is done, which results in two frames on the wire. By ignoring the flush only one frame is sent for each message.- Author:
- Stuart Douglas
-
-
Constructor Summary
Constructors Constructor Description NoFlushByteOutput(org.jboss.marshalling.ByteOutput delegate)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidclose()voidflush()voidwrite(byte[] b)voidwrite(byte[] b, int off, int len)voidwrite(int b)
-
-
-
Method Detail
-
write
public void write(int b) throws IOException- Specified by:
writein interfaceorg.jboss.marshalling.ByteOutput- Throws:
IOException
-
write
public void write(byte[] b) throws IOException- Specified by:
writein interfaceorg.jboss.marshalling.ByteOutput- Throws:
IOException
-
write
public void write(byte[] b, int off, int len) throws IOException- Specified by:
writein interfaceorg.jboss.marshalling.ByteOutput- Throws:
IOException
-
close
public void close() throws IOException- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable- Throws:
IOException
-
flush
public void flush() throws IOException- Specified by:
flushin interfaceFlushable- Throws:
IOException
-
-