Class ImmediatePooled<T>

  • All Implemented Interfaces:
    java.lang.AutoCloseable, org.xnio.Pooled<T>

    public class ImmediatePooled<T>
    extends java.lang.Object
    implements org.xnio.Pooled<T>
    Wrapper that allows you to use a non-pooed item as a pooled value
    Author:
    Stuart Douglas
    • Constructor Summary

      Constructors 
      Constructor Description
      ImmediatePooled​(T value)  
    • Constructor Detail

      • ImmediatePooled

        public ImmediatePooled​(T value)
    • Method Detail

      • discard

        public void discard()
        Specified by:
        discard in interface org.xnio.Pooled<T>
      • free

        public void free()
        Specified by:
        free in interface org.xnio.Pooled<T>
      • getResource

        public T getResource()
                      throws java.lang.IllegalStateException
        Specified by:
        getResource in interface org.xnio.Pooled<T>
        Throws:
        java.lang.IllegalStateException
      • close

        public void close()
        Specified by:
        close in interface java.lang.AutoCloseable
        Specified by:
        close in interface org.xnio.Pooled<T>