pub type nghttp2_on_extension_chunk_recv_callback = Option<unsafe extern "C" fn(session: *mut nghttp2_session, hd: *const nghttp2_frame_hd, data: *const u8, len: usize, user_data: *mut c_void) -> c_int>;
Expand description

@functypedef

Callback function invoked when chunk of extension frame payload is received. The |hd| points to frame header. The received chunk is |data| of length |len|.

The implementation of this function must return 0 if it succeeds.

To abort processing this extension frame, return :enum:NGHTTP2_ERR_CANCEL.

If fatal error occurred, application should return :enum:NGHTTP2_ERR_CALLBACK_FAILURE. In this case, nghttp2_session_recv() and nghttp2_session_mem_recv() functions immediately return :enum:NGHTTP2_ERR_CALLBACK_FAILURE. If the other values are returned, currently they are treated as :enum:NGHTTP2_ERR_CALLBACK_FAILURE.

Aliased Type§

enum nghttp2_on_extension_chunk_recv_callback {
    None,
    Some(unsafe extern "C" fn(_: *mut nghttp2_session, _: *const nghttp2_frame_hd, _: *const u8, _: usize, _: *mut c_void) -> i32),
}

Variants§

§1.0.0

None

No value.

§1.0.0

Some(unsafe extern "C" fn(_: *mut nghttp2_session, _: *const nghttp2_frame_hd, _: *const u8, _: usize, _: *mut c_void) -> i32)

Some value of type T.