@Override
    protected void intercept(@NonNull HttpResponseChain chain, @NonNull ByteBuffer buffer,
                             int index) throws IOException {
        if (index > 0) {
            chain.process(buffer);
            return;
        }
        if (mLog == null) {
            mLog = new NetBareXLog(Protocol.TCP, chain.response().ip(), chain.response().port());
        }
        parseResponseHeader(chain.response().session(), buffer);
        chain.process(buffer);
    }
Parse HTTP request header part and response header part from HTTP packets. The parse result will
 be set to {@link HttpSession}.

@author Megatron King
@since 2018-12-09 12:19
netbare-core/src/main/java/com/github/megatronking/netbare/http/HttpHeaderParseInterceptor.java