View Javadoc

1   /***
2    * 
3    */
4   package org.apache.mina.protocol;
5   
6   import org.apache.mina.protocol.ProtocolDecoderOutput;
7   import org.apache.mina.util.Queue;
8   
9   /***
10   * A {@link ProtocolDecoderOutput} based on queue.
11   * 
12   * @author The Apache Directory Project (dev@directory.apache.org)
13   * @author Trustin Lee (trustin@apache.org)
14   * @version $Rev: 210062 $, $Date: 2005-07-11 12:52:38 +0900 $
15   *
16   */
17  public class SimpleProtocolDecoderOutput implements ProtocolDecoderOutput
18  {
19      private final Queue messageQueue = new Queue();
20      
21      public SimpleProtocolDecoderOutput()
22      {
23      }
24      
25      public Queue getMessageQueue()
26      {
27          return messageQueue;
28      }
29      
30      public void write( Object message )
31      {
32          messageQueue.push( message );
33      }
34  }