@@ -0,0 +1,1404 @@
+package com.wizzardo.http;%0A%0Aimport com.wizzardo.epoll.readable.ReadableByteArray;%0Aimport com.wizzardo.tools.misc.pool.*;%0A%0Aimport java.io.IOException;%0A%0A/**%0A * Created by wizzardo on 26/05/16.%0A */%0Apublic class ReadableByteArrayPool %7B%0A    private static Pool%3CPooledReadableByteArray%3E pool = new ThreadLocalPool%3CPooledReadableByteArray%3E() %7B%0A        @Override%0A        public PooledReadableByteArray create() %7B%0A            return new PooledReadableByteArray(new byte%5B10240%5D, this);%0A        %7D%0A%0A        @Override%0A        protected Holder%3CPooledReadableByteArray%3E createHolder(PooledReadableByteArray value) %7B%0A            return value.holder;%0A        %7D%0A    %7D;%0A%0A    public static class PooledReadableByteArray extends ReadableByteArray %7B%0A        final Holder%3CPooledReadableByteArray%3E holder;%0A%0A        PooledReadableByteArray(byte%5B%5D bytes, Pool%3CPooledReadableByteArray%3E pool) %7B%0A            super(bytes);%0A            holder = new SoftHolder%3C%3E(pool, this);%0A        %7D%0A%0A        public byte%5B%5D bytes() %7B%0A            return bytes;%0A        %7D%0A%0A        public void length(int length) %7B%0A            this.length = length;%0A        %7D%0A%0A        @Override%0A        public void close() throws IOException %7B%0A            holder.close();%0A        %7D%0A    %7D%0A%0A    public static PooledReadableByteArray get() %7B%0A        PooledReadableByteArray buffer = pool.get();%0A        buffer.unread((int) buffer.complete());%0A        return buffer;%0A    %7D%0A%7D%0A

add ReadableByteArrayPool