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   * @version $Rev: 327113 $, $Date: 2005-10-21 15:59:15 +0900 $
14   *
15   */
16  public class SimpleProtocolDecoderOutput implements ProtocolDecoderOutput
17  {
18      private final Queue messageQueue = new Queue();
19      
20      public SimpleProtocolDecoderOutput()
21      {
22      }
23      
24      public Queue getMessageQueue()
25      {
26          return messageQueue;
27      }
28      
29      public void write( Object message )
30      {
31          messageQueue.push( message );
32      }
33  }