Class StringReadChannelListener

  • All Implemented Interfaces:
    java.util.EventListener, org.xnio.ChannelListener<org.xnio.channels.StreamSourceChannel>

    public abstract class StringReadChannelListener
    extends java.lang.Object
    implements org.xnio.ChannelListener<org.xnio.channels.StreamSourceChannel>
    Simple utility class for reading a string

    todo: handle unicode properly

    Author:
    Stuart Douglas
    • Nested Class Summary

      • Nested classes/interfaces inherited from interface org.xnio.ChannelListener

        org.xnio.ChannelListener.Setter<T extends java.nio.channels.Channel>, org.xnio.ChannelListener.SimpleSetter<T extends java.nio.channels.Channel>
    • Method Summary

      All Methods Instance Methods Abstract Methods Concrete Methods 
      Modifier and Type Method Description
      protected abstract void error​(java.io.IOException e)  
      void handleEvent​(org.xnio.channels.StreamSourceChannel channel)  
      void setup​(org.xnio.channels.StreamSourceChannel channel)  
      protected abstract void stringDone​(java.lang.String string)  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • StringReadChannelListener

        public StringReadChannelListener​(ByteBufferPool bufferPool)
      • StringReadChannelListener

        @Deprecated
        public StringReadChannelListener​(org.xnio.Pool<java.nio.ByteBuffer> bufferPool)
        Deprecated.
    • Method Detail

      • setup

        public void setup​(org.xnio.channels.StreamSourceChannel channel)
      • handleEvent

        public void handleEvent​(org.xnio.channels.StreamSourceChannel channel)
        Specified by:
        handleEvent in interface org.xnio.ChannelListener<org.xnio.channels.StreamSourceChannel>
      • stringDone

        protected abstract void stringDone​(java.lang.String string)
      • error

        protected abstract void error​(java.io.IOException e)