org.lastbamboo.common.tcp.frame
Class TcpFrameIoSessionOutputStream

java.lang.Object
  extended by java.io.OutputStream
      extended by org.littleshoot.util.mina.AbstractIoSessionOutputStream<TcpFrame>
          extended by org.lastbamboo.common.tcp.frame.TcpFrameIoSessionOutputStream
All Implemented Interfaces:
Closeable, Flushable

public final class TcpFrameIoSessionOutputStream
extends org.littleshoot.util.mina.AbstractIoSessionOutputStream<TcpFrame>

OutputStream for IoSessions that also wraps all data in TcpFrame messages.


Field Summary
 
Fields inherited from class org.littleshoot.util.mina.AbstractIoSessionOutputStream
m_ioSession, m_lastWriteFuture
 
Constructor Summary
TcpFrameIoSessionOutputStream(org.littleshoot.mina.common.IoSession session)
          Creates a new OutputStream for TcpFrames.
 
Method Summary
 void write(byte[] b, int off, int len)
           
 void write(int b)
           
 
Methods inherited from class org.littleshoot.util.mina.AbstractIoSessionOutputStream
close, flush, write
 
Methods inherited from class java.io.OutputStream
write
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TcpFrameIoSessionOutputStream

public TcpFrameIoSessionOutputStream(org.littleshoot.mina.common.IoSession session)
Creates a new OutputStream for TcpFrames.

Parameters:
session - The MINA IoSession to write to.
Method Detail

write

public void write(byte[] b,
                  int off,
                  int len)
           throws IOException
Overrides:
write in class OutputStream
Throws:
IOException

write

public void write(int b)
           throws IOException
Specified by:
write in class OutputStream
Throws:
IOException


Copyright © 2013 LittleShoot. All Rights Reserved.