pub fn new() -> Http {
        let mut h2_builder = h2::server::Builder::default();
        h2_builder
            .initial_window_size(DEFAULT_HTTP2_STREAM_WINDOW)
            .initial_connection_window_size(DEFAULT_HTTP2_CONN_WINDOW);

        Http {
            exec: Exec::Default,
            h1_half_close: false,
            h1_writev: true,
            h2_builder,
            mode: ConnectionMode::Fallback,
            keep_alive: true,
            max_buf_size: None,
            pipeline_flush: false,
        }
    }
/// Creates a new instance of the HTTP protocol, ready to spawn a server or
/// start accepting connections.
Creates a new instance of the HTTP protocol, ready to spawn a server or
start accepting connections.
Creates a new instance of the HTTP protocol ready to spawn a server or start accepting connections .
pub fn new() -> Http {
        let mut h2_builder = h2::server::Builder::default();
        h2_builder
            .initial_window_size(DEFAULT_HTTP2_STREAM_WINDOW)
            .initial_connection_window_size(DEFAULT_HTTP2_CONN_WINDOW);
        Http {
            exec: Exec::Default,
            h1_half_close: false,
            h1_writev: true,
            h2_builder,
            mode: ConnectionMode::Fallback,
            keep_alive: true,
            max_buf_size: None,
            pipeline_flush: false,
        }
    }
pub fn new ( ) -> Http { let mut h2_builder = h2 :: server :: Builder :: default ( ) ; h2_builder . initial_window_size ( DEFAULT_HTTP2_STREAM_WINDOW ) . initial_connection_window_size ( DEFAULT_HTTP2_CONN_WINDOW ) ; Http { exec : Exec :: Default , h1_half_close : false , h1_writev : true , h2_builder , mode : ConnectionMode :: Fallback , keep_alive : true , max_buf_size : None , pipeline_flush : false , } }
Creates a new instance of the HTTP protocol, ready to spawn a server or
start accepting connections.
Creates a new instance of the HTTP protocol ready to spawn a server or start accepting connections .