com.alibaba.dubbo.remoting.transport.codec
Class TransportCodec

java.lang.Object
  extended by com.alibaba.dubbo.remoting.transport.AbstractCodec
      extended by com.alibaba.dubbo.remoting.transport.codec.TransportCodec
All Implemented Interfaces:
Codec
Direct Known Subclasses:
TelnetCodec

public class TransportCodec
extends AbstractCodec

TransportCodec

Author:
william.liangf

Field Summary
 
Fields inherited from interface com.alibaba.dubbo.remoting.Codec
NEED_MORE_INPUT
 
Constructor Summary
TransportCodec()
           
 
Method Summary
 Object decode(Channel channel, InputStream input)
          Decode message.
 void encode(Channel channel, OutputStream output, Object message)
          Encode message.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TransportCodec

public TransportCodec()
Method Detail

encode

public void encode(Channel channel,
                   OutputStream output,
                   Object message)
            throws IOException
Description copied from interface: Codec
Encode message.

Parameters:
channel - channel.
output - output stream.
message - message.
Throws:
IOException

decode

public Object decode(Channel channel,
                     InputStream input)
              throws IOException
Description copied from interface: Codec
Decode message.

Parameters:
channel - channel.
input - input stream.
Returns:
message or NEED_MORE_INPUT poison.
Throws:
IOException
See Also:
Codec.NEED_MORE_INPUT


Copyright © 2012 Alibaba. All Rights Reserved.