<liclass="toctree-l2"><aclass="reference internal"href="package_README.html#client-server-and-proxy-programs">Client, Server and Proxy programs</a></li>
<p>Do not call <aclass="reference internal"href="#c.nghttp2_session_send"title="nghttp2_session_send"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_send()</span></tt></a>, <aclass="reference internal"href="#c.nghttp2_session_mem_send"title="nghttp2_session_mem_send"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_mem_send()</span></tt></a>,
<aclass="reference internal"href="#c.nghttp2_session_recv"title="nghttp2_session_recv"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_recv()</span></tt></a> or <aclass="reference internal"href="#c.nghttp2_session_mem_recv"title="nghttp2_session_mem_recv"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_mem_recv()</span></tt></a> from the nghttp2
<ttclass="descname">NGHTTP2_PROTO_VERSION_ID_LEN</tt><aclass="headerlink"href="#c.NGHTTP2_PROTO_VERSION_ID_LEN"title="Permalink to this definition">¶</a></dt>
<dd><p>The length of <aclass="reference internal"href="#c.NGHTTP2_PROTO_VERSION_ID"title="NGHTTP2_PROTO_VERSION_ID"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_PROTO_VERSION_ID</span></tt></a>.</p>
<ttclass="descname">NGHTTP2_CLEARTEXT_PROTO_VERSION_ID</tt><aclass="headerlink"href="#c.NGHTTP2_CLEARTEXT_PROTO_VERSION_ID"title="Permalink to this definition">¶</a></dt>
<dd><p>The protocol version identification string of this library
supports. This identifier is used if HTTP/2 is used over cleartext
TCP.</p>
</dd></dl>
<dlclass="macro">
<dtid="c.NGHTTP2_CLEARTEXT_PROTO_VERSION_ID_LEN">
<ttclass="descname">NGHTTP2_CLEARTEXT_PROTO_VERSION_ID_LEN</tt><aclass="headerlink"href="#c.NGHTTP2_CLEARTEXT_PROTO_VERSION_ID_LEN"title="Permalink to this definition">¶</a></dt>
<dd><p>The length of <aclass="reference internal"href="#c.NGHTTP2_CLEARTEXT_PROTO_VERSION_ID"title="NGHTTP2_CLEARTEXT_PROTO_VERSION_ID"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_CLEARTEXT_PROTO_VERSION_ID</span></tt></a>.</p>
<ttclass="descname">NGHTTP2_VERSION_AGE</tt><aclass="headerlink"href="#c.NGHTTP2_VERSION_AGE"title="Permalink to this definition">¶</a></dt>
<dd><p>The age of <aclass="reference internal"href="#c.nghttp2_info"title="nghttp2_info"><ttclass="xref c c-type docutils literal"><spanclass="pre">nghttp2_info</span></tt></a></p>
<ttclass="descname">NGHTTP2_INITIAL_WINDOW_SIZE</tt><aclass="headerlink"href="#c.NGHTTP2_INITIAL_WINDOW_SIZE"title="Permalink to this definition">¶</a></dt>
<ttclass="descname">NGHTTP2_INITIAL_CONNECTION_WINDOW_SIZE</tt><aclass="headerlink"href="#c.NGHTTP2_INITIAL_CONNECTION_WINDOW_SIZE"title="Permalink to this definition">¶</a></dt>
<ttclass="descname">NGHTTP2_MAX_HEADER_TABLE_SIZE</tt><aclass="headerlink"href="#c.NGHTTP2_MAX_HEADER_TABLE_SIZE"title="Permalink to this definition">¶</a></dt>
<ttclass="descname">NGHTTP2_CLIENT_CONNECTION_PREFACE</tt><aclass="headerlink"href="#c.NGHTTP2_CLIENT_CONNECTION_PREFACE"title="Permalink to this definition">¶</a></dt>
<dd><p>The client connection preface.</p>
</dd></dl>
<dlclass="macro">
<dtid="c.NGHTTP2_CLIENT_CONNECTION_PREFACE_LEN">
<ttclass="descname">NGHTTP2_CLIENT_CONNECTION_PREFACE_LEN</tt><aclass="headerlink"href="#c.NGHTTP2_CLIENT_CONNECTION_PREFACE_LEN"title="Permalink to this definition">¶</a></dt>
<dd><p>The length of <aclass="reference internal"href="#c.NGHTTP2_CLIENT_CONNECTION_PREFACE"title="NGHTTP2_CLIENT_CONNECTION_PREFACE"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_CLIENT_CONNECTION_PREFACE</span></tt></a>.</p>
<ttclass="descname">NGHTTP2_CLIENT_CONNECTION_HEADER</tt><aclass="headerlink"href="#c.NGHTTP2_CLIENT_CONNECTION_HEADER"title="Permalink to this definition">¶</a></dt>
<ttclass="descname">NGHTTP2_CLIENT_CONNECTION_HEADER_LEN</tt><aclass="headerlink"href="#c.NGHTTP2_CLIENT_CONNECTION_HEADER_LEN"title="Permalink to this definition">¶</a></dt>
<dd><p>The length of <aclass="reference internal"href="#c.NGHTTP2_CLIENT_CONNECTION_HEADER"title="NGHTTP2_CLIENT_CONNECTION_HEADER"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_CLIENT_CONNECTION_HEADER</span></tt></a>.</p>
<ttclass="descname">NGHTTP2_INITIAL_MAX_CONCURRENT_STREAMS</tt><aclass="headerlink"href="#c.NGHTTP2_INITIAL_MAX_CONCURRENT_STREAMS"title="Permalink to this definition">¶</a></dt>
<ttclass="descname">NGHTTP2_ERR_INVALID_ARGUMENT</tt><aclass="headerlink"href="#c.NGHTTP2_ERR_INVALID_ARGUMENT"title="Permalink to this definition">¶</a></dt>
<ttclass="descname">NGHTTP2_ERR_UNSUPPORTED_VERSION</tt><aclass="headerlink"href="#c.NGHTTP2_ERR_UNSUPPORTED_VERSION"title="Permalink to this definition">¶</a></dt>
Used as a return value from <aclass="reference internal"href="#c.nghttp2_send_callback"title="nghttp2_send_callback"><ttclass="xref c c-type docutils literal"><spanclass="pre">nghttp2_send_callback</span></tt></a> and
<aclass="reference internal"href="#c.nghttp2_recv_callback"title="nghttp2_recv_callback"><ttclass="xref c c-type docutils literal"><spanclass="pre">nghttp2_recv_callback</span></tt></a> to indicate that the operation
<ttclass="descname">NGHTTP2_ERR_INVALID_FRAME</tt><aclass="headerlink"href="#c.NGHTTP2_ERR_INVALID_FRAME"title="Permalink to this definition">¶</a></dt>
<aclass="reference internal"href="#c.nghttp2_data_source_read_callback"title="nghttp2_data_source_read_callback"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_data_source_read_callback()</span></tt></a> to indicate that data
<aclass="reference internal"href="#c.nghttp2_data_source_read_callback"title="nghttp2_data_source_read_callback"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_data_source_read_callback()</span></tt></a> for details.</p>
<ttclass="descname">NGHTTP2_ERR_STREAM_ID_NOT_AVAILABLE</tt><aclass="headerlink"href="#c.NGHTTP2_ERR_STREAM_ID_NOT_AVAILABLE"title="Permalink to this definition">¶</a></dt>
<ttclass="descname">NGHTTP2_ERR_STREAM_CLOSED</tt><aclass="headerlink"href="#c.NGHTTP2_ERR_STREAM_CLOSED"title="Permalink to this definition">¶</a></dt>
<ttclass="descname">NGHTTP2_ERR_STREAM_CLOSING</tt><aclass="headerlink"href="#c.NGHTTP2_ERR_STREAM_CLOSING"title="Permalink to this definition">¶</a></dt>
<ttclass="descname">NGHTTP2_ERR_STREAM_SHUT_WR</tt><aclass="headerlink"href="#c.NGHTTP2_ERR_STREAM_SHUT_WR"title="Permalink to this definition">¶</a></dt>
<ttclass="descname">NGHTTP2_ERR_INVALID_STREAM_ID</tt><aclass="headerlink"href="#c.NGHTTP2_ERR_INVALID_STREAM_ID"title="Permalink to this definition">¶</a></dt>
<ttclass="descname">NGHTTP2_ERR_INVALID_STREAM_STATE</tt><aclass="headerlink"href="#c.NGHTTP2_ERR_INVALID_STREAM_STATE"title="Permalink to this definition">¶</a></dt>
<ttclass="descname">NGHTTP2_ERR_DEFERRED_DATA_EXIST</tt><aclass="headerlink"href="#c.NGHTTP2_ERR_DEFERRED_DATA_EXIST"title="Permalink to this definition">¶</a></dt>
<ttclass="descname">NGHTTP2_ERR_START_STREAM_NOT_ALLOWED</tt><aclass="headerlink"href="#c.NGHTTP2_ERR_START_STREAM_NOT_ALLOWED"title="Permalink to this definition">¶</a></dt>
<ttclass="descname">NGHTTP2_ERR_GOAWAY_ALREADY_SENT</tt><aclass="headerlink"href="#c.NGHTTP2_ERR_GOAWAY_ALREADY_SENT"title="Permalink to this definition">¶</a></dt>
<ttclass="descname">NGHTTP2_ERR_INVALID_HEADER_BLOCK</tt><aclass="headerlink"href="#c.NGHTTP2_ERR_INVALID_HEADER_BLOCK"title="Permalink to this definition">¶</a></dt>
<ttclass="descname">NGHTTP2_ERR_INVALID_STATE</tt><aclass="headerlink"href="#c.NGHTTP2_ERR_INVALID_STATE"title="Permalink to this definition">¶</a></dt>
<ttclass="descname">NGHTTP2_ERR_TEMPORAL_CALLBACK_FAILURE</tt><aclass="headerlink"href="#c.NGHTTP2_ERR_TEMPORAL_CALLBACK_FAILURE"title="Permalink to this definition">¶</a></dt>
<ttclass="descname">NGHTTP2_ERR_FRAME_SIZE_ERROR</tt><aclass="headerlink"href="#c.NGHTTP2_ERR_FRAME_SIZE_ERROR"title="Permalink to this definition">¶</a></dt>
<ttclass="descname">NGHTTP2_ERR_INSUFF_BUFSIZE</tt><aclass="headerlink"href="#c.NGHTTP2_ERR_INSUFF_BUFSIZE"title="Permalink to this definition">¶</a></dt>
<ttclass="descname">NGHTTP2_ERR_TOO_MANY_INFLIGHT_SETTINGS</tt><aclass="headerlink"href="#c.NGHTTP2_ERR_TOO_MANY_INFLIGHT_SETTINGS"title="Permalink to this definition">¶</a></dt>
<ttclass="descname">NGHTTP2_ERR_PUSH_DISABLED</tt><aclass="headerlink"href="#c.NGHTTP2_ERR_PUSH_DISABLED"title="Permalink to this definition">¶</a></dt>
The errors <<aclass="reference internal"href="#c.NGHTTP2_ERR_FATAL"title="NGHTTP2_ERR_FATAL"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_ERR_FATAL</span></tt></a> mean that the library is
<ttclass="descname">NGHTTP2_ERR_CALLBACK_FAILURE</tt><aclass="headerlink"href="#c.NGHTTP2_ERR_CALLBACK_FAILURE"title="Permalink to this definition">¶</a></dt>
<ttclass="descname">NGHTTP2_FLAG_PRIORITY_GROUP</tt><aclass="headerlink"href="#c.NGHTTP2_FLAG_PRIORITY_GROUP"title="Permalink to this definition">¶</a></dt>
<ttclass="descname">NGHTTP2_FLAG_PRIORITY_DEPENDENCY</tt><aclass="headerlink"href="#c.NGHTTP2_FLAG_PRIORITY_DEPENDENCY"title="Permalink to this definition">¶</a></dt>
<ttclass="descname">NGHTTP2_SETTINGS_HEADER_TABLE_SIZE</tt><aclass="headerlink"href="#c.NGHTTP2_SETTINGS_HEADER_TABLE_SIZE"title="Permalink to this definition">¶</a></dt>
<ttclass="descname">NGHTTP2_SETTINGS_ENABLE_PUSH</tt><aclass="headerlink"href="#c.NGHTTP2_SETTINGS_ENABLE_PUSH"title="Permalink to this definition">¶</a></dt>
<ttclass="descname">NGHTTP2_SETTINGS_MAX_CONCURRENT_STREAMS</tt><aclass="headerlink"href="#c.NGHTTP2_SETTINGS_MAX_CONCURRENT_STREAMS"title="Permalink to this definition">¶</a></dt>
<ttclass="descname">NGHTTP2_SETTINGS_INITIAL_WINDOW_SIZE</tt><aclass="headerlink"href="#c.NGHTTP2_SETTINGS_INITIAL_WINDOW_SIZE"title="Permalink to this definition">¶</a></dt>
Maximum ID of <aclass="reference internal"href="#c.nghttp2_settings_id"title="nghttp2_settings_id"><ttclass="xref c c-type docutils literal"><spanclass="pre">nghttp2_settings_id</span></tt></a>.</p>
<ttclass="descname">NGHTTP2_FLOW_CONTROL_ERROR</tt><aclass="headerlink"href="#c.NGHTTP2_FLOW_CONTROL_ERROR"title="Permalink to this definition">¶</a></dt>
<ttclass="descname">NGHTTP2_COMPRESSION_ERROR</tt><aclass="headerlink"href="#c.NGHTTP2_COMPRESSION_ERROR"title="Permalink to this definition">¶</a></dt>
<ttclass="descname">NGHTTP2_ENHANCE_YOUR_CALM</tt><aclass="headerlink"href="#c.NGHTTP2_ENHANCE_YOUR_CALM"title="Permalink to this definition">¶</a></dt>
<ttclass="descname">NGHTTP2_INADEQUATE_SECURITY</tt><aclass="headerlink"href="#c.NGHTTP2_INADEQUATE_SECURITY"title="Permalink to this definition">¶</a></dt>
<ttclass="descname">NGHTTP2_HCAT_PUSH_RESPONSE</tt><aclass="headerlink"href="#c.NGHTTP2_HCAT_PUSH_RESPONSE"title="Permalink to this definition">¶</a></dt>
<ttclass="descname">nghttp2_priority_type</tt><aclass="headerlink"href="#c.nghttp2_priority_type"title="Permalink to this definition">¶</a></dt>
<dd><p>The type of priority specified in <aclass="reference internal"href="#c.nghttp2_priority_spec"title="nghttp2_priority_spec"><ttclass="xref c c-type docutils literal"><spanclass="pre">nghttp2_priority_spec</span></tt></a>.</p>
<ttclass="descname">NGHTTP2_PRIORITY_TYPE_NONE</tt><aclass="headerlink"href="#c.NGHTTP2_PRIORITY_TYPE_NONE"title="Permalink to this definition">¶</a></dt>
<ttclass="descname">NGHTTP2_PRIORITY_TYPE_GROUP</tt><aclass="headerlink"href="#c.NGHTTP2_PRIORITY_TYPE_GROUP"title="Permalink to this definition">¶</a></dt>
<ttclass="descname">NGHTTP2_PRIORITY_TYPE_DEP</tt><aclass="headerlink"href="#c.NGHTTP2_PRIORITY_TYPE_DEP"title="Permalink to this definition">¶</a></dt>
<ttclass="descname">nghttp2_info</tt><aclass="headerlink"href="#c.nghttp2_info"title="Permalink to this definition">¶</a></dt>
<dd><p>This struct is what <aclass="reference internal"href="#c.nghttp2_version"title="nghttp2_version"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_version()</span></tt></a> returns. It holds
<aclass="reference internal"href="#c.NGHTTP2_VERSION_AGE"title="NGHTTP2_VERSION_AGE"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_VERSION_AGE</span></tt></a> but a future version may bump it and
int <ttclass="descname">version_num</tt><aclass="headerlink"href="#c.nghttp2_info.version_num"title="Permalink to this definition">¶</a></dt>
<dd><p>the <aclass="reference internal"href="#c.NGHTTP2_VERSION_NUM"title="NGHTTP2_VERSION_NUM"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_VERSION_NUM</span></tt></a> number (since age ==1)</p>
const char *<ttclass="descname">version_str</tt><aclass="headerlink"href="#c.nghttp2_info.version_str"title="Permalink to this definition">¶</a></dt>
<dd><p>points to the <aclass="reference internal"href="#c.NGHTTP2_VERSION"title="NGHTTP2_VERSION"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_VERSION</span></tt></a> string (since age ==1)</p>
const char *<ttclass="descname">proto_str</tt><aclass="headerlink"href="#c.nghttp2_info.proto_str"title="Permalink to this definition">¶</a></dt>
<dd><p>points to the <aclass="reference internal"href="#c.NGHTTP2_PROTO_VERSION_ID"title="NGHTTP2_PROTO_VERSION_ID"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_PROTO_VERSION_ID</span></tt></a> string this
uint8_t <ttclass="descname">flags</tt><aclass="headerlink"href="#c.nghttp2_nv.flags"title="Permalink to this definition">¶</a></dt>
<dd><p>Bitwise OR of one or more of <aclass="reference internal"href="#c.nghttp2_nv_flag"title="nghttp2_nv_flag"><ttclass="xref c c-type docutils literal"><spanclass="pre">nghttp2_nv_flag</span></tt></a>.</p>
uint8_t <ttclass="descname">type</tt><aclass="headerlink"href="#c.nghttp2_frame_hd.type"title="Permalink to this definition">¶</a></dt>
<dd><p>The type of this frame. See <aclass="reference internal"href="#c.nghttp2_frame"title="nghttp2_frame"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_frame()</span></tt></a>.</p>
set <aclass="reference internal"href="#c.NGHTTP2_DATA_FLAG_EOF"title="NGHTTP2_DATA_FLAG_EOF"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_DATA_FLAG_EOF</span></tt></a> flag in <em>*data_falgs</em>. If the
application wants to postpone DATA frames, (e.g., asynchronous I/O,
or reading data blocks for long time), it is achieved by returning
<aclass="reference internal"href="#c.NGHTTP2_ERR_DEFERRED"title="NGHTTP2_ERR_DEFERRED"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_ERR_DEFERRED</span></tt></a> without reading any data in this
invocation. The library removes DATA frame from the outgoing queue
temporarily. To move back deferred DATA frame to outgoing queue,
call <aclass="reference internal"href="#c.nghttp2_session_resume_data"title="nghttp2_session_resume_data"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_resume_data()</span></tt></a>. In case of error, there are
2 choices. Returning <aclass="reference internal"href="#c.NGHTTP2_ERR_TEMPORAL_CALLBACK_FAILURE"title="NGHTTP2_ERR_TEMPORAL_CALLBACK_FAILURE"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_ERR_TEMPORAL_CALLBACK_FAILURE</span></tt></a>
will close the stream by issuing RST_STREAM with
<aclass="reference internal"href="#c.NGHTTP2_INTERNAL_ERROR"title="NGHTTP2_INTERNAL_ERROR"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_INTERNAL_ERROR</span></tt></a>. Returning
<aclass="reference internal"href="#c.NGHTTP2_ERR_CALLBACK_FAILURE"title="NGHTTP2_ERR_CALLBACK_FAILURE"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_ERR_CALLBACK_FAILURE</span></tt></a> will signal the entire session
<aclass="reference internal"href="#c.nghttp2_data_source"title="nghttp2_data_source">nghttp2_data_source</a><ttclass="descname">source</tt><aclass="headerlink"href="#c.nghttp2_data_provider.source"title="Permalink to this definition">¶</a></dt>
<aclass="reference internal"href="#c.nghttp2_data_source_read_callback"title="nghttp2_data_source_read_callback">nghttp2_data_source_read_callback</a><ttclass="descname">read_callback</tt><aclass="headerlink"href="#c.nghttp2_data_provider.read_callback"title="Permalink to this definition">¶</a></dt>
<ttclass="descname">nghttp2_priority_group</tt><aclass="headerlink"href="#c.nghttp2_priority_group"title="Permalink to this definition">¶</a></dt>
<dd><p>This structure stores priority group ID and its weight.</p>
<dlclass="member">
<dtid="c.nghttp2_priority_group.pri_group_id">
int32_t <ttclass="descname">pri_group_id</tt><aclass="headerlink"href="#c.nghttp2_priority_group.pri_group_id"title="Permalink to this definition">¶</a></dt>
<dd><p>The priority group ID</p>
</dd></dl>
<dlclass="member">
<dtid="c.nghttp2_priority_group.weight">
int32_t <ttclass="descname">weight</tt><aclass="headerlink"href="#c.nghttp2_priority_group.weight"title="Permalink to this definition">¶</a></dt>
<dd><p>The weight of the priority group</p>
</dd></dl>
</dd></dl>
<dlclass="type">
<dtid="c.nghttp2_priority_dep">
<ttclass="descname">nghttp2_priority_dep</tt><aclass="headerlink"href="#c.nghttp2_priority_dep"title="Permalink to this definition">¶</a></dt>
<dd><p>This structure stores stream ID of the stream to depend on and its
dependency is exclusive or not.</p>
<dlclass="member">
<dtid="c.nghttp2_priority_dep.stream_id">
int32_t <ttclass="descname">stream_id</tt><aclass="headerlink"href="#c.nghttp2_priority_dep.stream_id"title="Permalink to this definition">¶</a></dt>
<dd><p>The stream ID of the stream to depend on.</p>
</dd></dl>
<dlclass="member">
<dtid="c.nghttp2_priority_dep.exclusive">
uint8_t <ttclass="descname">exclusive</tt><aclass="headerlink"href="#c.nghttp2_priority_dep.exclusive"title="Permalink to this definition">¶</a></dt>
<dd><p>nonzero means exclusive dependency</p>
</dd></dl>
</dd></dl>
<dlclass="type">
<dtid="c.nghttp2_priority_spec">
<ttclass="descname">nghttp2_priority_spec</tt><aclass="headerlink"href="#c.nghttp2_priority_spec"title="Permalink to this definition">¶</a></dt>
<dd><p>The structure to specify stream dependency. To specify stream
dependency, specify <em>pri_type</em> and fill the <em>group</em> or <em>dep</em> member
according to <em>pri_type</em>.</p>
<dlclass="member">
<dtid="c.nghttp2_priority_spec.pri_type">
<aclass="reference internal"href="#c.nghttp2_priority_type"title="nghttp2_priority_type">nghttp2_priority_type</a><ttclass="descname">pri_type</tt><aclass="headerlink"href="#c.nghttp2_priority_spec.pri_type"title="Permalink to this definition">¶</a></dt>
<dd><p>Type of priority specification. If <em>pri_type</em> is
<aclass="reference internal"href="#c.NGHTTP2_PRIORITY_TYPE_GROUP"title="NGHTTP2_PRIORITY_TYPE_GROUP"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_PRIORITY_TYPE_GROUP</span></tt></a>, fill <em>group</em>. If <em>pri_type</em>
is <aclass="reference internal"href="#c.NGHTTP2_PRIORITY_TYPE_DEP"title="NGHTTP2_PRIORITY_TYPE_DEP"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_PRIORITY_TYPE_DEP</span></tt></a>, fill <em>dep</em>. If <em>pri_type</em>
is <aclass="reference internal"href="#c.NGHTTP2_PRIORITY_TYPE_NONE"title="NGHTTP2_PRIORITY_TYPE_NONE"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_PRIORITY_TYPE_NONE</span></tt></a>, the other data members are
ignored and it means that default priority group ID (which is
same as the stream ID) and default weight
<aclass="reference internal"href="#c.NGHTTP2_DEFAULT_WEIGHT"title="NGHTTP2_DEFAULT_WEIGHT"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_DEFAULT_WEIGHT</span></tt></a> are specified.</p>
</dd></dl>
<dlclass="member">
<dtid="c.nghttp2_priority_spec.group">
<aclass="reference internal"href="#c.nghttp2_priority_group"title="nghttp2_priority_group">nghttp2_priority_group</a><ttclass="descname">group</tt><aclass="headerlink"href="#c.nghttp2_priority_spec.group"title="Permalink to this definition">¶</a></dt>
<dd><p>Specify priority group ID and its weight. This field is
interpreted only when <em>pri_type</em> member is
<aclass="reference internal"href="#c.NGHTTP2_PRIORITY_TYPE_GROUP"title="NGHTTP2_PRIORITY_TYPE_GROUP"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_PRIORITY_TYPE_GROUP</span></tt></a>.</p>
</dd></dl>
<dlclass="member">
<dtid="c.nghttp2_priority_spec.dep">
<aclass="reference internal"href="#c.nghttp2_priority_dep"title="nghttp2_priority_dep">nghttp2_priority_dep</a><ttclass="descname">dep</tt><aclass="headerlink"href="#c.nghttp2_priority_spec.dep"title="Permalink to this definition">¶</a></dt>
<dd><p>Specify stream ID of a stream to depend on and exclusive flag.
This field is interpreted only when <em>pri_type</em> member is
<aclass="reference internal"href="#c.NGHTTP2_PRIORITY_TYPE_DEP"title="NGHTTP2_PRIORITY_TYPE_DEP"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_PRIORITY_TYPE_DEP</span></tt></a>.</p>
<aclass="reference internal"href="#c.nghttp2_frame_hd"title="nghttp2_frame_hd">nghttp2_frame_hd</a><ttclass="descname">hd</tt><aclass="headerlink"href="#c.nghttp2_headers.hd"title="Permalink to this definition">¶</a></dt>
<aclass="reference internal"href="#c.nghttp2_priority_spec"title="nghttp2_priority_spec">nghttp2_priority_spec</a><ttclass="descname">pri_spec</tt><aclass="headerlink"href="#c.nghttp2_headers.pri_spec"title="Permalink to this definition">¶</a></dt>
<aclass="reference internal"href="#c.nghttp2_nv"title="nghttp2_nv">nghttp2_nv</a> *<ttclass="descname">nva</tt><aclass="headerlink"href="#c.nghttp2_headers.nva"title="Permalink to this definition">¶</a></dt>
<aclass="reference internal"href="#c.nghttp2_headers_category"title="nghttp2_headers_category">nghttp2_headers_category</a><ttclass="descname">cat</tt><aclass="headerlink"href="#c.nghttp2_headers.cat"title="Permalink to this definition">¶</a></dt>
<aclass="reference internal"href="#c.nghttp2_frame_hd"title="nghttp2_frame_hd">nghttp2_frame_hd</a><ttclass="descname">hd</tt><aclass="headerlink"href="#c.nghttp2_priority.hd"title="Permalink to this definition">¶</a></dt>
<aclass="reference internal"href="#c.nghttp2_priority_spec"title="nghttp2_priority_spec">nghttp2_priority_spec</a><ttclass="descname">pri_spec</tt><aclass="headerlink"href="#c.nghttp2_priority.pri_spec"title="Permalink to this definition">¶</a></dt>
<aclass="reference internal"href="#c.nghttp2_frame_hd"title="nghttp2_frame_hd">nghttp2_frame_hd</a><ttclass="descname">hd</tt><aclass="headerlink"href="#c.nghttp2_rst_stream.hd"title="Permalink to this definition">¶</a></dt>
<aclass="reference internal"href="#c.nghttp2_error_code"title="nghttp2_error_code">nghttp2_error_code</a><ttclass="descname">error_code</tt><aclass="headerlink"href="#c.nghttp2_rst_stream.error_code"title="Permalink to this definition">¶</a></dt>
<dd><p>The error code. See <aclass="reference internal"href="#c.nghttp2_error_code"title="nghttp2_error_code"><ttclass="xref c c-type docutils literal"><spanclass="pre">nghttp2_error_code</span></tt></a>.</p>
int32_t <ttclass="descname">settings_id</tt><aclass="headerlink"href="#c.nghttp2_settings_entry.settings_id"title="Permalink to this definition">¶</a></dt>
<dd><p>The SETTINGS ID. See <aclass="reference internal"href="#c.nghttp2_settings_id"title="nghttp2_settings_id"><ttclass="xref c c-type docutils literal"><spanclass="pre">nghttp2_settings_id</span></tt></a>.</p>
<aclass="reference internal"href="#c.nghttp2_frame_hd"title="nghttp2_frame_hd">nghttp2_frame_hd</a><ttclass="descname">hd</tt><aclass="headerlink"href="#c.nghttp2_settings.hd"title="Permalink to this definition">¶</a></dt>
<aclass="reference internal"href="#c.nghttp2_settings_entry"title="nghttp2_settings_entry">nghttp2_settings_entry</a> *<ttclass="descname">iv</tt><aclass="headerlink"href="#c.nghttp2_settings.iv"title="Permalink to this definition">¶</a></dt>
<aclass="reference internal"href="#c.nghttp2_frame_hd"title="nghttp2_frame_hd">nghttp2_frame_hd</a><ttclass="descname">hd</tt><aclass="headerlink"href="#c.nghttp2_push_promise.hd"title="Permalink to this definition">¶</a></dt>
<aclass="reference internal"href="#c.nghttp2_nv"title="nghttp2_nv">nghttp2_nv</a> *<ttclass="descname">nva</tt><aclass="headerlink"href="#c.nghttp2_push_promise.nva"title="Permalink to this definition">¶</a></dt>
int32_t <ttclass="descname">promised_stream_id</tt><aclass="headerlink"href="#c.nghttp2_push_promise.promised_stream_id"title="Permalink to this definition">¶</a></dt>
<aclass="reference internal"href="#c.nghttp2_frame_hd"title="nghttp2_frame_hd">nghttp2_frame_hd</a><ttclass="descname">hd</tt><aclass="headerlink"href="#c.nghttp2_ping.hd"title="Permalink to this definition">¶</a></dt>
<aclass="reference internal"href="#c.nghttp2_frame_hd"title="nghttp2_frame_hd">nghttp2_frame_hd</a><ttclass="descname">hd</tt><aclass="headerlink"href="#c.nghttp2_goaway.hd"title="Permalink to this definition">¶</a></dt>
int32_t <ttclass="descname">last_stream_id</tt><aclass="headerlink"href="#c.nghttp2_goaway.last_stream_id"title="Permalink to this definition">¶</a></dt>
<aclass="reference internal"href="#c.nghttp2_error_code"title="nghttp2_error_code">nghttp2_error_code</a><ttclass="descname">error_code</tt><aclass="headerlink"href="#c.nghttp2_goaway.error_code"title="Permalink to this definition">¶</a></dt>
<dd><p>The error code. See <aclass="reference internal"href="#c.nghttp2_error_code"title="nghttp2_error_code"><ttclass="xref c c-type docutils literal"><spanclass="pre">nghttp2_error_code</span></tt></a>.</p>
size_t <ttclass="descname">opaque_data_len</tt><aclass="headerlink"href="#c.nghttp2_goaway.opaque_data_len"title="Permalink to this definition">¶</a></dt>
<aclass="reference internal"href="#c.nghttp2_frame_hd"title="nghttp2_frame_hd">nghttp2_frame_hd</a><ttclass="descname">hd</tt><aclass="headerlink"href="#c.nghttp2_window_update.hd"title="Permalink to this definition">¶</a></dt>
int32_t <ttclass="descname">window_size_increment</tt><aclass="headerlink"href="#c.nghttp2_window_update.window_size_increment"title="Permalink to this definition">¶</a></dt>
<ttclass="descname">nghttp2_altsvc</tt><aclass="headerlink"href="#c.nghttp2_altsvc"title="Permalink to this definition">¶</a></dt>
<dd><p>The ALTSVC frame. It has following members:</p>
<dlclass="member">
<dtid="c.nghttp2_altsvc.hd">
<aclass="reference internal"href="#c.nghttp2_frame_hd"title="nghttp2_frame_hd">nghttp2_frame_hd</a><ttclass="descname">hd</tt><aclass="headerlink"href="#c.nghttp2_altsvc.hd"title="Permalink to this definition">¶</a></dt>
<dd><p>The frame header.</p>
</dd></dl>
<dlclass="member">
<dtid="c.nghttp2_altsvc.protocol_id">
uint8_t *<ttclass="descname">protocol_id</tt><aclass="headerlink"href="#c.nghttp2_altsvc.protocol_id"title="Permalink to this definition">¶</a></dt>
<dd><p>Protocol ID</p>
</dd></dl>
<dlclass="member">
<dtid="c.nghttp2_altsvc.host">
uint8_t *<ttclass="descname">host</tt><aclass="headerlink"href="#c.nghttp2_altsvc.host"title="Permalink to this definition">¶</a></dt>
<dd><p>Host</p>
</dd></dl>
<dlclass="member">
<dtid="c.nghttp2_altsvc.origin">
uint8_t *<ttclass="descname">origin</tt><aclass="headerlink"href="#c.nghttp2_altsvc.origin"title="Permalink to this definition">¶</a></dt>
<dd><p>Origin</p>
</dd></dl>
<dlclass="member">
<dtid="c.nghttp2_altsvc.protocol_id_len">
size_t <ttclass="descname">protocol_id_len</tt><aclass="headerlink"href="#c.nghttp2_altsvc.protocol_id_len"title="Permalink to this definition">¶</a></dt>
<dd><p>The length of <em>protocol_id</em></p>
</dd></dl>
<dlclass="member">
<dtid="c.nghttp2_altsvc.host_len">
size_t <ttclass="descname">host_len</tt><aclass="headerlink"href="#c.nghttp2_altsvc.host_len"title="Permalink to this definition">¶</a></dt>
<dd><p>The length of <em>host</em></p>
</dd></dl>
<dlclass="member">
<dtid="c.nghttp2_altsvc.origin_len">
size_t <ttclass="descname">origin_len</tt><aclass="headerlink"href="#c.nghttp2_altsvc.origin_len"title="Permalink to this definition">¶</a></dt>
<dd><p>The length of <em>origin</em></p>
</dd></dl>
<dlclass="member">
<dtid="c.nghttp2_altsvc.max_age">
uint32_t <ttclass="descname">max_age</tt><aclass="headerlink"href="#c.nghttp2_altsvc.max_age"title="Permalink to this definition">¶</a></dt>
<dd><p>Max-Age</p>
</dd></dl>
<dlclass="member">
<dtid="c.nghttp2_altsvc.port">
uint16_t <ttclass="descname">port</tt><aclass="headerlink"href="#c.nghttp2_altsvc.port"title="Permalink to this definition">¶</a></dt>
<aclass="reference internal"href="#c.nghttp2_frame_hd"title="nghttp2_frame_hd">nghttp2_frame_hd</a><ttclass="descname">hd</tt><aclass="headerlink"href="#c.nghttp2_frame.hd"title="Permalink to this definition">¶</a></dt>
<aclass="reference internal"href="#c.nghttp2_data"title="nghttp2_data">nghttp2_data</a><ttclass="descname">data</tt><aclass="headerlink"href="#c.nghttp2_frame.data"title="Permalink to this definition">¶</a></dt>
<aclass="reference internal"href="#c.nghttp2_headers"title="nghttp2_headers">nghttp2_headers</a><ttclass="descname">headers</tt><aclass="headerlink"href="#c.nghttp2_frame.headers"title="Permalink to this definition">¶</a></dt>
<aclass="reference internal"href="#c.nghttp2_priority"title="nghttp2_priority">nghttp2_priority</a><ttclass="descname">priority</tt><aclass="headerlink"href="#c.nghttp2_frame.priority"title="Permalink to this definition">¶</a></dt>
<aclass="reference internal"href="#c.nghttp2_rst_stream"title="nghttp2_rst_stream">nghttp2_rst_stream</a><ttclass="descname">rst_stream</tt><aclass="headerlink"href="#c.nghttp2_frame.rst_stream"title="Permalink to this definition">¶</a></dt>
<aclass="reference internal"href="#c.nghttp2_settings"title="nghttp2_settings">nghttp2_settings</a><ttclass="descname">settings</tt><aclass="headerlink"href="#c.nghttp2_frame.settings"title="Permalink to this definition">¶</a></dt>
<aclass="reference internal"href="#c.nghttp2_push_promise"title="nghttp2_push_promise">nghttp2_push_promise</a><ttclass="descname">push_promise</tt><aclass="headerlink"href="#c.nghttp2_frame.push_promise"title="Permalink to this definition">¶</a></dt>
<aclass="reference internal"href="#c.nghttp2_ping"title="nghttp2_ping">nghttp2_ping</a><ttclass="descname">ping</tt><aclass="headerlink"href="#c.nghttp2_frame.ping"title="Permalink to this definition">¶</a></dt>
<aclass="reference internal"href="#c.nghttp2_goaway"title="nghttp2_goaway">nghttp2_goaway</a><ttclass="descname">goaway</tt><aclass="headerlink"href="#c.nghttp2_frame.goaway"title="Permalink to this definition">¶</a></dt>
<aclass="reference internal"href="#c.nghttp2_window_update"title="nghttp2_window_update">nghttp2_window_update</a><ttclass="descname">window_update</tt><aclass="headerlink"href="#c.nghttp2_frame.window_update"title="Permalink to this definition">¶</a></dt>
<aclass="reference internal"href="#c.nghttp2_altsvc"title="nghttp2_altsvc">nghttp2_altsvc</a><ttclass="descname">altsvc</tt><aclass="headerlink"href="#c.nghttp2_frame.altsvc"title="Permalink to this definition">¶</a></dt>
it must return <aclass="reference internal"href="#c.NGHTTP2_ERR_WOULDBLOCK"title="NGHTTP2_ERR_WOULDBLOCK"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_ERR_WOULDBLOCK</span></tt></a>. For other errors, it
must return <aclass="reference internal"href="#c.NGHTTP2_ERR_CALLBACK_FAILURE"title="NGHTTP2_ERR_CALLBACK_FAILURE"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_ERR_CALLBACK_FAILURE</span></tt></a>. The <em>user_data</em>
<aclass="reference internal"href="#c.nghttp2_session_client_new"title="nghttp2_session_client_new"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_client_new()</span></tt></a> or <aclass="reference internal"href="#c.nghttp2_session_server_new"title="nghttp2_session_server_new"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_server_new()</span></tt></a>.</p>
<aclass="reference internal"href="#c.nghttp2_session_send"title="nghttp2_session_send"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_send()</span></tt></a> to send data to the remote endpoint. If
the application uses <aclass="reference internal"href="#c.nghttp2_session_mem_send"title="nghttp2_session_mem_send"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_mem_send()</span></tt></a> instead, this
without blocking, it must return <aclass="reference internal"href="#c.NGHTTP2_ERR_WOULDBLOCK"title="NGHTTP2_ERR_WOULDBLOCK"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_ERR_WOULDBLOCK</span></tt></a>. If
<aclass="reference internal"href="#c.NGHTTP2_ERR_EOF"title="NGHTTP2_ERR_EOF"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_ERR_EOF</span></tt></a>. For other errors, it must return
<aclass="reference internal"href="#c.NGHTTP2_ERR_CALLBACK_FAILURE"title="NGHTTP2_ERR_CALLBACK_FAILURE"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_ERR_CALLBACK_FAILURE</span></tt></a>. Returning 0 is treated as
<aclass="reference internal"href="#c.NGHTTP2_ERR_WOULDBLOCK"title="NGHTTP2_ERR_WOULDBLOCK"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_ERR_WOULDBLOCK</span></tt></a>. The <em>user_data</em> pointer is the
<aclass="reference internal"href="#c.nghttp2_session_client_new"title="nghttp2_session_client_new"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_client_new()</span></tt></a> or <aclass="reference internal"href="#c.nghttp2_session_server_new"title="nghttp2_session_server_new"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_server_new()</span></tt></a>.</p>
<aclass="reference internal"href="#c.nghttp2_session_recv"title="nghttp2_session_recv"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_recv()</span></tt></a> to receive data from the remote
endpoint. If the application uses <aclass="reference internal"href="#c.nghttp2_session_mem_recv"title="nghttp2_session_mem_recv"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_mem_recv()</span></tt></a>
typedef int <ttclass="descname">(*nghttp2_on_frame_recv_callback)</tt><big>(</big><aclass="reference internal"href="#c.nghttp2_session"title="nghttp2_session">nghttp2_session</a><em> *session</em>, const <aclass="reference internal"href="#c.nghttp2_frame"title="nghttp2_frame">nghttp2_frame</a><em> *frame</em>, void<em> *user_data</em><big>)</big><aclass="headerlink"href="#c.nghttp2_on_frame_recv_callback"title="Permalink to this definition">¶</a></dt>
<dd><p>Callback function invoked by <aclass="reference internal"href="#c.nghttp2_session_recv"title="nghttp2_session_recv"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_recv()</span></tt></a> when a aframe
in to the call to <aclass="reference internal"href="#c.nghttp2_session_client_new"title="nghttp2_session_client_new"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_client_new()</span></tt></a> or
<aclass="reference internal"href="#c.nghttp2_session_server_new"title="nghttp2_session_server_new"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_server_new()</span></tt></a>.</p>
<p>If frame is HEADERS or PUSH_PROMISE, the <ttclass="docutils literal"><spanclass="pre">nva</span></tt> and <ttclass="docutils literal"><spanclass="pre">nvlen</span></tt>
member of their data structure are always <ttclass="docutils literal"><spanclass="pre">NULL</span></tt> and 0
respectively. The header name/value pairs are emitted via
<aclass="reference internal"href="#c.nghttp2_on_stream_close_callback"title="nghttp2_on_stream_close_callback"><ttclass="xref c c-type docutils literal"><spanclass="pre">nghttp2_on_stream_close_callback</span></tt></a>). The application should
<p>Only HEADERS and DATA frame can signal the end of incoming data. If
<ttclass="docutils literal"><spanclass="pre">frame->hd.flags</span><spanclass="pre">&</span><spanclass="pre">NGHTTP2_FLAG_END_STREAM</span></tt> is nonzero, the
<em>frame</em> is the last frame from the remote peer in this stream.</p>
error and <aclass="reference internal"href="#c.nghttp2_session_recv"title="nghttp2_session_recv"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_recv()</span></tt></a> and <aclass="reference internal"href="#c.nghttp2_session_mem_recv"title="nghttp2_session_mem_recv"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_mem_recv()</span></tt></a>
functions immediately return <aclass="reference internal"href="#c.NGHTTP2_ERR_CALLBACK_FAILURE"title="NGHTTP2_ERR_CALLBACK_FAILURE"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_ERR_CALLBACK_FAILURE</span></tt></a>.</p>
typedef int <ttclass="descname">(*nghttp2_on_invalid_frame_recv_callback)</tt><big>(</big><aclass="reference internal"href="#c.nghttp2_session"title="nghttp2_session">nghttp2_session</a><em> *session</em>, const <aclass="reference internal"href="#c.nghttp2_frame"title="nghttp2_frame">nghttp2_frame</a><em> *frame</em>, <aclass="reference internal"href="#c.nghttp2_error_code"title="nghttp2_error_code">nghttp2_error_code</a><em> error_code</em>, void<em> *user_data</em><big>)</big><aclass="headerlink"href="#c.nghttp2_on_invalid_frame_recv_callback"title="Permalink to this definition">¶</a></dt>
<dd><p>Callback function invoked by <aclass="reference internal"href="#c.nghttp2_session_recv"title="nghttp2_session_recv"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_recv()</span></tt></a> when an
<aclass="reference internal"href="#c.nghttp2_error_code"title="nghttp2_error_code"><ttclass="xref c c-macro docutils literal"><spanclass="pre">nghttp2_error_code</span></tt></a> and indicates the error. When this
<aclass="reference internal"href="#c.nghttp2_session_client_new"title="nghttp2_session_client_new"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_client_new()</span></tt></a> or <aclass="reference internal"href="#c.nghttp2_session_server_new"title="nghttp2_session_server_new"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_server_new()</span></tt></a>.</p>
<p>If frame is HEADERS or PUSH_PROMISE, the <ttclass="docutils literal"><spanclass="pre">nva</span></tt> and <ttclass="docutils literal"><spanclass="pre">nvlen</span></tt>
member of their data structure are always <ttclass="docutils literal"><spanclass="pre">NULL</span></tt> and 0
<aclass="reference internal"href="#c.nghttp2_session_recv"title="nghttp2_session_recv"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_recv()</span></tt></a> and <aclass="reference internal"href="#c.nghttp2_session_send"title="nghttp2_session_send"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_send()</span></tt></a> functions
immediately return <aclass="reference internal"href="#c.NGHTTP2_ERR_CALLBACK_FAILURE"title="NGHTTP2_ERR_CALLBACK_FAILURE"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_ERR_CALLBACK_FAILURE</span></tt></a>.</p>
typedef int <ttclass="descname">(*nghttp2_on_data_chunk_recv_callback)</tt><big>(</big><aclass="reference internal"href="#c.nghttp2_session"title="nghttp2_session">nghttp2_session</a><em> *session</em>, uint8_t<em> flags</em>, int32_t<em> stream_id</em>, const uint8_t<em> *data</em>, size_t<em> len</em>, void<em> *user_data</em><big>)</big><aclass="headerlink"href="#c.nghttp2_on_data_chunk_recv_callback"title="Permalink to this definition">¶</a></dt>
<dd><p>Callback function invoked when a chunk of data in DATA frame is
received. The <em>stream_id</em> is the stream ID this DATA frame belongs
to. The <em>flags</em> is the flags of DATA frame which this data chunk is
contained. <ttclass="docutils literal"><spanclass="pre">(flags</span><spanclass="pre">&</span><spanclass="pre">NGHTTP2_FLAG_END_STREAM)</span><spanclass="pre">!=</span><spanclass="pre">0</span></tt> does not
necessarily mean this chunk of data is the last one in the
stream. You should use <aclass="reference internal"href="#c.nghttp2_on_frame_recv_callback"title="nghttp2_on_frame_recv_callback"><ttclass="xref c c-type docutils literal"><spanclass="pre">nghttp2_on_frame_recv_callback</span></tt></a> to
<aclass="reference internal"href="#c.nghttp2_session_client_new"title="nghttp2_session_client_new"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_client_new()</span></tt></a> or <aclass="reference internal"href="#c.nghttp2_session_server_new"title="nghttp2_session_server_new"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_server_new()</span></tt></a>.</p>
<p>If the application uses <aclass="reference internal"href="#c.nghttp2_session_mem_recv"title="nghttp2_session_mem_recv"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_mem_recv()</span></tt></a>, it can return
<aclass="reference internal"href="#c.NGHTTP2_ERR_PAUSE"title="NGHTTP2_ERR_PAUSE"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_ERR_PAUSE</span></tt></a> to make <aclass="reference internal"href="#c.nghttp2_session_mem_recv"title="nghttp2_session_mem_recv"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_mem_recv()</span></tt></a>
<aclass="reference internal"href="#c.nghttp2_session_mem_recv"title="nghttp2_session_mem_recv"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_mem_recv()</span></tt></a> or <aclass="reference internal"href="#c.nghttp2_session_recv"title="nghttp2_session_recv"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_recv()</span></tt></a> is
<aclass="reference internal"href="#c.nghttp2_session_recv"title="nghttp2_session_recv"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_recv()</span></tt></a> and <aclass="reference internal"href="#c.nghttp2_session_mem_recv"title="nghttp2_session_mem_recv"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_mem_recv()</span></tt></a> functions
immediately return <aclass="reference internal"href="#c.NGHTTP2_ERR_CALLBACK_FAILURE"title="NGHTTP2_ERR_CALLBACK_FAILURE"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_ERR_CALLBACK_FAILURE</span></tt></a>.</p>
typedef int <ttclass="descname">(*nghttp2_before_frame_send_callback)</tt><big>(</big><aclass="reference internal"href="#c.nghttp2_session"title="nghttp2_session">nghttp2_session</a><em> *session</em>, const <aclass="reference internal"href="#c.nghttp2_frame"title="nghttp2_frame">nghttp2_frame</a><em> *frame</em>, void<em> *user_data</em><big>)</big><aclass="headerlink"href="#c.nghttp2_before_frame_send_callback"title="Permalink to this definition">¶</a></dt>
<aclass="reference internal"href="#c.nghttp2_session_get_stream_user_data"title="nghttp2_session_get_stream_user_data"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_get_stream_user_data()</span></tt></a>), which is not assigned
passed in to the call to <aclass="reference internal"href="#c.nghttp2_session_client_new"title="nghttp2_session_client_new"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_client_new()</span></tt></a> or
<aclass="reference internal"href="#c.nghttp2_session_server_new"title="nghttp2_session_server_new"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_server_new()</span></tt></a>.</p>
<aclass="reference internal"href="#c.nghttp2_session_recv"title="nghttp2_session_recv"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_recv()</span></tt></a> and <aclass="reference internal"href="#c.nghttp2_session_send"title="nghttp2_session_send"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_send()</span></tt></a> functions
immediately return <aclass="reference internal"href="#c.NGHTTP2_ERR_CALLBACK_FAILURE"title="NGHTTP2_ERR_CALLBACK_FAILURE"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_ERR_CALLBACK_FAILURE</span></tt></a>.</p>
typedef int <ttclass="descname">(*nghttp2_on_frame_send_callback)</tt><big>(</big><aclass="reference internal"href="#c.nghttp2_session"title="nghttp2_session">nghttp2_session</a><em> *session</em>, const <aclass="reference internal"href="#c.nghttp2_frame"title="nghttp2_frame">nghttp2_frame</a><em> *frame</em>, void<em> *user_data</em><big>)</big><aclass="headerlink"href="#c.nghttp2_on_frame_send_callback"title="Permalink to this definition">¶</a></dt>
<aclass="reference internal"href="#c.nghttp2_session_client_new"title="nghttp2_session_client_new"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_client_new()</span></tt></a> or <aclass="reference internal"href="#c.nghttp2_session_server_new"title="nghttp2_session_server_new"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_server_new()</span></tt></a>.</p>
<aclass="reference internal"href="#c.nghttp2_session_recv"title="nghttp2_session_recv"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_recv()</span></tt></a> and <aclass="reference internal"href="#c.nghttp2_session_send"title="nghttp2_session_send"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_send()</span></tt></a> functions
immediately return <aclass="reference internal"href="#c.NGHTTP2_ERR_CALLBACK_FAILURE"title="NGHTTP2_ERR_CALLBACK_FAILURE"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_ERR_CALLBACK_FAILURE</span></tt></a>.</p>
typedef int <ttclass="descname">(*nghttp2_on_frame_not_send_callback)</tt><big>(</big><aclass="reference internal"href="#c.nghttp2_session"title="nghttp2_session">nghttp2_session</a><em> *session</em>, const <aclass="reference internal"href="#c.nghttp2_frame"title="nghttp2_frame">nghttp2_frame</a><em> *frame</em>, int<em> lib_error_code</em>, void<em> *user_data</em><big>)</big><aclass="headerlink"href="#c.nghttp2_on_frame_not_send_callback"title="Permalink to this definition">¶</a></dt>
<aclass="reference internal"href="#c.nghttp2_error"title="nghttp2_error"><ttclass="xref c c-type docutils literal"><spanclass="pre">nghttp2_error</span></tt></a>. The <em>user_data</em> pointer is the third
argument passed in to the call to <aclass="reference internal"href="#c.nghttp2_session_client_new"title="nghttp2_session_client_new"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_client_new()</span></tt></a> or
<aclass="reference internal"href="#c.nghttp2_session_server_new"title="nghttp2_session_server_new"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_server_new()</span></tt></a>.</p>
<aclass="reference internal"href="#c.nghttp2_session_recv"title="nghttp2_session_recv"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_recv()</span></tt></a> and <aclass="reference internal"href="#c.nghttp2_session_send"title="nghttp2_session_send"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_send()</span></tt></a> functions
immediately return <aclass="reference internal"href="#c.NGHTTP2_ERR_CALLBACK_FAILURE"title="NGHTTP2_ERR_CALLBACK_FAILURE"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_ERR_CALLBACK_FAILURE</span></tt></a>.</p>
typedef int <ttclass="descname">(*nghttp2_on_stream_close_callback)</tt><big>(</big><aclass="reference internal"href="#c.nghttp2_session"title="nghttp2_session">nghttp2_session</a><em> *session</em>, int32_t<em> stream_id</em>, <aclass="reference internal"href="#c.nghttp2_error_code"title="nghttp2_error_code">nghttp2_error_code</a><em> error_code</em>, void<em> *user_data</em><big>)</big><aclass="headerlink"href="#c.nghttp2_on_stream_close_callback"title="Permalink to this definition">¶</a></dt>
stream_user_data, which was specified in <aclass="reference internal"href="#c.nghttp2_submit_request"title="nghttp2_submit_request"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_submit_request()</span></tt></a>
or <aclass="reference internal"href="#c.nghttp2_submit_headers"title="nghttp2_submit_headers"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_submit_headers()</span></tt></a>, is still available in this
to the call to <aclass="reference internal"href="#c.nghttp2_session_client_new"title="nghttp2_session_client_new"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_client_new()</span></tt></a> or
<aclass="reference internal"href="#c.nghttp2_session_server_new"title="nghttp2_session_server_new"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_server_new()</span></tt></a>.</p>
<aclass="reference internal"href="#c.nghttp2_session_recv"title="nghttp2_session_recv"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_recv()</span></tt></a> and <aclass="reference internal"href="#c.nghttp2_session_send"title="nghttp2_session_send"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_send()</span></tt></a> functions
immediately return <aclass="reference internal"href="#c.NGHTTP2_ERR_CALLBACK_FAILURE"title="NGHTTP2_ERR_CALLBACK_FAILURE"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_ERR_CALLBACK_FAILURE</span></tt></a>.</p>
typedef int <ttclass="descname">(*nghttp2_on_unknown_frame_recv_callback)</tt><big>(</big><aclass="reference internal"href="#c.nghttp2_session"title="nghttp2_session">nghttp2_session</a><em> *session</em>, const uint8_t<em> *head</em>, size_t<em> headlen</em>, const uint8_t<em> *payload</em>, size_t<em> payloadlen</em>, void<em> *user_data</em><big>)</big><aclass="headerlink"href="#c.nghttp2_on_unknown_frame_recv_callback"title="Permalink to this definition">¶</a></dt>
the call to <aclass="reference internal"href="#c.nghttp2_session_client_new"title="nghttp2_session_client_new"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_client_new()</span></tt></a> or
<aclass="reference internal"href="#c.nghttp2_session_server_new"title="nghttp2_session_server_new"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_server_new()</span></tt></a>.</p>
<aclass="reference internal"href="#c.nghttp2_session_recv"title="nghttp2_session_recv"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_recv()</span></tt></a> and <aclass="reference internal"href="#c.nghttp2_session_send"title="nghttp2_session_send"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_send()</span></tt></a> functions
immediately return <aclass="reference internal"href="#c.NGHTTP2_ERR_CALLBACK_FAILURE"title="NGHTTP2_ERR_CALLBACK_FAILURE"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_ERR_CALLBACK_FAILURE</span></tt></a>.</p>
typedef int <ttclass="descname">(*nghttp2_on_begin_headers_callback)</tt><big>(</big><aclass="reference internal"href="#c.nghttp2_session"title="nghttp2_session">nghttp2_session</a><em> *session</em>, const <aclass="reference internal"href="#c.nghttp2_frame"title="nghttp2_frame">nghttp2_frame</a><em> *frame</em>, void<em> *user_data</em><big>)</big><aclass="headerlink"href="#c.nghttp2_on_begin_headers_callback"title="Permalink to this definition">¶</a></dt>
will be emitted by <aclass="reference internal"href="#c.nghttp2_on_header_callback"title="nghttp2_on_header_callback"><ttclass="xref c c-type docutils literal"><spanclass="pre">nghttp2_on_header_callback</span></tt></a>.</p>
<aclass="reference internal"href="#c.NGHTTP2_FLAG_END_HEADERS"title="NGHTTP2_FLAG_END_HEADERS"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_FLAG_END_HEADERS</span></tt></a> flag set, which indicates that one
<aclass="reference internal"href="#c.NGHTTP2_ERR_CALLBACK_FAILURE"title="NGHTTP2_ERR_CALLBACK_FAILURE"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_ERR_CALLBACK_FAILURE</span></tt></a>. If nonzero value other than
<aclass="reference internal"href="#c.NGHTTP2_ERR_CALLBACK_FAILURE"title="NGHTTP2_ERR_CALLBACK_FAILURE"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_ERR_CALLBACK_FAILURE</span></tt></a> is returned, it is treated as
if <aclass="reference internal"href="#c.NGHTTP2_ERR_CALLBACK_FAILURE"title="NGHTTP2_ERR_CALLBACK_FAILURE"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_ERR_CALLBACK_FAILURE</span></tt></a> is returned. If
<aclass="reference internal"href="#c.NGHTTP2_ERR_CALLBACK_FAILURE"title="NGHTTP2_ERR_CALLBACK_FAILURE"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_ERR_CALLBACK_FAILURE</span></tt></a> is returned,
<aclass="reference internal"href="#c.nghttp2_session_mem_recv"title="nghttp2_session_mem_recv"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_mem_recv()</span></tt></a> function will immediately return
<aclass="reference internal"href="#c.NGHTTP2_ERR_CALLBACK_FAILURE"title="NGHTTP2_ERR_CALLBACK_FAILURE"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_ERR_CALLBACK_FAILURE</span></tt></a>.</p>
for the <em>frame</em>. The <em>name</em> of length <em>namelen</em> is header name.
The <em>value</em> of length <em>valuelen</em> is header value. The <em>flags</em> is
bitwise OR of one or more of <aclass="reference internal"href="#c.nghttp2_nv_flag"title="nghttp2_nv_flag"><ttclass="xref c c-type docutils literal"><spanclass="pre">nghttp2_nv_flag</span></tt></a>.</p>
<p>If <aclass="reference internal"href="#c.NGHTTP2_NV_FLAG_NO_INDEX"title="NGHTTP2_NV_FLAG_NO_INDEX"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_NV_FLAG_NO_INDEX</span></tt></a> is set in <em>flags</em>, the receiver
must not index this name/value pair when forwarding it to the next
hop.</p>
<p>When this callback is invoked, <ttclass="docutils literal"><spanclass="pre">frame->hd.type</span></tt> is either
<aclass="reference internal"href="#c.NGHTTP2_HEADERS"title="NGHTTP2_HEADERS"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_HEADERS</span></tt></a> or <aclass="reference internal"href="#c.NGHTTP2_PUSH_PROMISE"title="NGHTTP2_PUSH_PROMISE"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_PUSH_PROMISE</span></tt></a>. After all
header name/value pairs are processed with this callback, and no
error has been detected, <aclass="reference internal"href="#c.nghttp2_on_frame_recv_callback"title="nghttp2_on_frame_recv_callback"><ttclass="xref c c-type docutils literal"><spanclass="pre">nghttp2_on_frame_recv_callback</span></tt></a>
will be invoked. If there is an error in decompression,
<aclass="reference internal"href="#c.nghttp2_on_frame_recv_callback"title="nghttp2_on_frame_recv_callback"><ttclass="xref c c-type docutils literal"><spanclass="pre">nghttp2_on_frame_recv_callback</span></tt></a> for the <em>frame</em> will not be
helper function <aclass="reference internal"href="#c.nghttp2_check_header_name"title="nghttp2_check_header_name"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_check_header_name()</span></tt></a> and
<aclass="reference internal"href="#c.nghttp2_check_header_value"title="nghttp2_check_header_value"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_check_header_value()</span></tt></a> provide simple validation against
<p>If the application uses <aclass="reference internal"href="#c.nghttp2_session_mem_recv"title="nghttp2_session_mem_recv"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_mem_recv()</span></tt></a>, it can return
<aclass="reference internal"href="#c.NGHTTP2_ERR_PAUSE"title="NGHTTP2_ERR_PAUSE"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_ERR_PAUSE</span></tt></a> to make <aclass="reference internal"href="#c.nghttp2_session_mem_recv"title="nghttp2_session_mem_recv"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_mem_recv()</span></tt></a>
<aclass="reference internal"href="#c.nghttp2_session_mem_recv"title="nghttp2_session_mem_recv"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_mem_recv()</span></tt></a> or <aclass="reference internal"href="#c.nghttp2_session_recv"title="nghttp2_session_recv"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_recv()</span></tt></a> is
<p>Returning <aclass="reference internal"href="#c.NGHTTP2_ERR_TEMPORAL_CALLBACK_FAILURE"title="NGHTTP2_ERR_TEMPORAL_CALLBACK_FAILURE"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_ERR_TEMPORAL_CALLBACK_FAILURE</span></tt></a> will close
<aclass="reference internal"href="#c.NGHTTP2_INTERNAL_ERROR"title="NGHTTP2_INTERNAL_ERROR"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_INTERNAL_ERROR</span></tt></a>. In this case,
<aclass="reference internal"href="#c.nghttp2_on_frame_recv_callback"title="nghttp2_on_frame_recv_callback"><ttclass="xref c c-type docutils literal"><spanclass="pre">nghttp2_on_frame_recv_callback</span></tt></a> will not be invoked.</p>
succeeds. It may return <aclass="reference internal"href="#c.NGHTTP2_ERR_PAUSE"title="NGHTTP2_ERR_PAUSE"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_ERR_PAUSE</span></tt></a> or
<aclass="reference internal"href="#c.NGHTTP2_ERR_TEMPORAL_CALLBACK_FAILURE"title="NGHTTP2_ERR_TEMPORAL_CALLBACK_FAILURE"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_ERR_TEMPORAL_CALLBACK_FAILURE</span></tt></a>. For other critical
failures, it must return <aclass="reference internal"href="#c.NGHTTP2_ERR_CALLBACK_FAILURE"title="NGHTTP2_ERR_CALLBACK_FAILURE"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_ERR_CALLBACK_FAILURE</span></tt></a>. If
<aclass="reference internal"href="#c.NGHTTP2_ERR_CALLBACK_FAILURE"title="NGHTTP2_ERR_CALLBACK_FAILURE"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_ERR_CALLBACK_FAILURE</span></tt></a>. If
<aclass="reference internal"href="#c.NGHTTP2_ERR_CALLBACK_FAILURE"title="NGHTTP2_ERR_CALLBACK_FAILURE"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_ERR_CALLBACK_FAILURE</span></tt></a> is returned,
<aclass="reference internal"href="#c.nghttp2_session_recv"title="nghttp2_session_recv"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_recv()</span></tt></a> and <aclass="reference internal"href="#c.nghttp2_session_mem_recv"title="nghttp2_session_mem_recv"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_mem_recv()</span></tt></a> functions
immediately return <aclass="reference internal"href="#c.NGHTTP2_ERR_CALLBACK_FAILURE"title="NGHTTP2_ERR_CALLBACK_FAILURE"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_ERR_CALLBACK_FAILURE</span></tt></a>.</p>
<aclass="reference internal"href="#c.NGHTTP2_ERR_CALLBACK_FAILURE"title="NGHTTP2_ERR_CALLBACK_FAILURE"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_ERR_CALLBACK_FAILURE</span></tt></a> will make
<aclass="reference internal"href="#c.nghttp2_session_send"title="nghttp2_session_send"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_send()</span></tt></a> function immediately return
<aclass="reference internal"href="#c.NGHTTP2_ERR_CALLBACK_FAILURE"title="NGHTTP2_ERR_CALLBACK_FAILURE"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_ERR_CALLBACK_FAILURE</span></tt></a>.</p>
<ttclass="descname">nghttp2_session_callbacks</tt><aclass="headerlink"href="#c.nghttp2_session_callbacks"title="Permalink to this definition">¶</a></dt>
<aclass="reference internal"href="#c.nghttp2_send_callback"title="nghttp2_send_callback">nghttp2_send_callback</a><ttclass="descname">send_callback</tt><aclass="headerlink"href="#c.nghttp2_session_callbacks.send_callback"title="Permalink to this definition">¶</a></dt>
application uses <aclass="reference internal"href="#c.nghttp2_session_mem_send"title="nghttp2_session_mem_send"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_mem_send()</span></tt></a> to serialize data
<aclass="reference internal"href="#c.nghttp2_recv_callback"title="nghttp2_recv_callback">nghttp2_recv_callback</a><ttclass="descname">recv_callback</tt><aclass="headerlink"href="#c.nghttp2_session_callbacks.recv_callback"title="Permalink to this definition">¶</a></dt>
application uses <aclass="reference internal"href="#c.nghttp2_session_mem_recv"title="nghttp2_session_mem_recv"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_mem_recv()</span></tt></a> to process received
<aclass="reference internal"href="#c.nghttp2_on_frame_recv_callback"title="nghttp2_on_frame_recv_callback">nghttp2_on_frame_recv_callback</a><ttclass="descname">on_frame_recv_callback</tt><aclass="headerlink"href="#c.nghttp2_session_callbacks.on_frame_recv_callback"title="Permalink to this definition">¶</a></dt>
<dd><p>Callback function invoked by <aclass="reference internal"href="#c.nghttp2_session_recv"title="nghttp2_session_recv"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_recv()</span></tt></a> when a
<aclass="reference internal"href="#c.nghttp2_on_invalid_frame_recv_callback"title="nghttp2_on_invalid_frame_recv_callback">nghttp2_on_invalid_frame_recv_callback</a><ttclass="descname">on_invalid_frame_recv_callback</tt><aclass="headerlink"href="#c.nghttp2_session_callbacks.on_invalid_frame_recv_callback"title="Permalink to this definition">¶</a></dt>
<dd><p>Callback function invoked by <aclass="reference internal"href="#c.nghttp2_session_recv"title="nghttp2_session_recv"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_recv()</span></tt></a> when an
<aclass="reference internal"href="#c.nghttp2_on_data_chunk_recv_callback"title="nghttp2_on_data_chunk_recv_callback">nghttp2_on_data_chunk_recv_callback</a><ttclass="descname">on_data_chunk_recv_callback</tt><aclass="headerlink"href="#c.nghttp2_session_callbacks.on_data_chunk_recv_callback"title="Permalink to this definition">¶</a></dt>
<aclass="reference internal"href="#c.nghttp2_before_frame_send_callback"title="nghttp2_before_frame_send_callback">nghttp2_before_frame_send_callback</a><ttclass="descname">before_frame_send_callback</tt><aclass="headerlink"href="#c.nghttp2_session_callbacks.before_frame_send_callback"title="Permalink to this definition">¶</a></dt>
<aclass="reference internal"href="#c.nghttp2_on_frame_send_callback"title="nghttp2_on_frame_send_callback">nghttp2_on_frame_send_callback</a><ttclass="descname">on_frame_send_callback</tt><aclass="headerlink"href="#c.nghttp2_session_callbacks.on_frame_send_callback"title="Permalink to this definition">¶</a></dt>
<aclass="reference internal"href="#c.nghttp2_on_frame_not_send_callback"title="nghttp2_on_frame_not_send_callback">nghttp2_on_frame_not_send_callback</a><ttclass="descname">on_frame_not_send_callback</tt><aclass="headerlink"href="#c.nghttp2_session_callbacks.on_frame_not_send_callback"title="Permalink to this definition">¶</a></dt>
<aclass="reference internal"href="#c.nghttp2_on_stream_close_callback"title="nghttp2_on_stream_close_callback">nghttp2_on_stream_close_callback</a><ttclass="descname">on_stream_close_callback</tt><aclass="headerlink"href="#c.nghttp2_session_callbacks.on_stream_close_callback"title="Permalink to this definition">¶</a></dt>
<aclass="reference internal"href="#c.nghttp2_on_unknown_frame_recv_callback"title="nghttp2_on_unknown_frame_recv_callback">nghttp2_on_unknown_frame_recv_callback</a><ttclass="descname">on_unknown_frame_recv_callback</tt><aclass="headerlink"href="#c.nghttp2_session_callbacks.on_unknown_frame_recv_callback"title="Permalink to this definition">¶</a></dt>
<aclass="reference internal"href="#c.nghttp2_on_begin_headers_callback"title="nghttp2_on_begin_headers_callback">nghttp2_on_begin_headers_callback</a><ttclass="descname">on_begin_headers_callback</tt><aclass="headerlink"href="#c.nghttp2_session_callbacks.on_begin_headers_callback"title="Permalink to this definition">¶</a></dt>
<aclass="reference internal"href="#c.nghttp2_on_header_callback"title="nghttp2_on_header_callback">nghttp2_on_header_callback</a><ttclass="descname">on_header_callback</tt><aclass="headerlink"href="#c.nghttp2_session_callbacks.on_header_callback"title="Permalink to this definition">¶</a></dt>
<aclass="reference internal"href="#c.nghttp2_select_padding_callback"title="nghttp2_select_padding_callback">nghttp2_select_padding_callback</a><ttclass="descname">select_padding_callback</tt><aclass="headerlink"href="#c.nghttp2_session_callbacks.select_padding_callback"title="Permalink to this definition">¶</a></dt>
<ttclass="descname">nghttp2_option</tt><aclass="headerlink"href="#c.nghttp2_option"title="Permalink to this definition">¶</a></dt>
<dd><p>Configuration options for <aclass="reference internal"href="#c.nghttp2_session"title="nghttp2_session"><ttclass="xref c c-type docutils literal"><spanclass="pre">nghttp2_session</span></tt></a>. The details of
this structure are intentionally hidden from the public API.</p>
int <ttclass="descname">nghttp2_option_new</tt><big>(</big><aclass="reference internal"href="#c.nghttp2_option"title="nghttp2_option">nghttp2_option</a><em> **option_ptr</em><big>)</big><aclass="headerlink"href="#c.nghttp2_option_new"title="Permalink to this definition">¶</a></dt>
<dd><p>Initializes <em>*option_ptr</em> with default values.</p>
<p>When the application finished using this object, it can use
<aclass="reference internal"href="#c.nghttp2_option_del"title="nghttp2_option_del"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_option_del()</span></tt></a> to free its memory.</p>
<p>This function returns 0 if it succeeds, or one of the following
negative error codes:</p>
<dlclass="docutils">
<dt><aclass="reference internal"href="#c.NGHTTP2_ERR_NOMEM"title="NGHTTP2_ERR_NOMEM"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_ERR_NOMEM</span></tt></a></dt>
<dd>Out of memory.</dd>
</dl>
</dd></dl>
<dlclass="function">
<dtid="c.nghttp2_option_del">
void <ttclass="descname">nghttp2_option_del</tt><big>(</big><aclass="reference internal"href="#c.nghttp2_option"title="nghttp2_option">nghttp2_option</a><em> *option</em><big>)</big><aclass="headerlink"href="#c.nghttp2_option_del"title="Permalink to this definition">¶</a></dt>
<dd><p>Frees any resources allocated for <em>option</em>. If <em>option</em> is
<ttclass="docutils literal"><spanclass="pre">NULL</span></tt>, this function does nothing.</p>
void <ttclass="descname">nghttp2_option_set_no_auto_stream_window_update</tt><big>(</big><aclass="reference internal"href="#c.nghttp2_option"title="nghttp2_option">nghttp2_option</a><em> *option</em>, int<em> val</em><big>)</big><aclass="headerlink"href="#c.nghttp2_option_set_no_auto_stream_window_update"title="Permalink to this definition">¶</a></dt>
<dd><p>This option prevents the library from sending WINDOW_UPDATE for a
stream automatically. If this option is set to nonzero, the
library won’t send WINDOW_UPDATE for a stream and the application
is responsible for sending WINDOW_UPDATE using
<aclass="reference internal"href="#c.nghttp2_submit_window_update"title="nghttp2_submit_window_update"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_submit_window_update()</span></tt></a>. By default, this option is set to
void <ttclass="descname">nghttp2_option_set_no_auto_connection_window_update</tt><big>(</big><aclass="reference internal"href="#c.nghttp2_option"title="nghttp2_option">nghttp2_option</a><em> *option</em>, int<em> val</em><big>)</big><aclass="headerlink"href="#c.nghttp2_option_set_no_auto_connection_window_update"title="Permalink to this definition">¶</a></dt>
<dd><p>This option prevents the library from sending WINDOW_UPDATE for a
connection automatically. If this option is set to nonzero, the
library won’t send WINDOW_UPDATE for a connection and the
application is responsible for sending WINDOW_UPDATE with stream
ID 0 using <aclass="reference internal"href="#c.nghttp2_submit_window_update"title="nghttp2_submit_window_update"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_submit_window_update()</span></tt></a>. By default, this
void <ttclass="descname">nghttp2_option_set_peer_max_concurrent_streams</tt><big>(</big><aclass="reference internal"href="#c.nghttp2_option"title="nghttp2_option">nghttp2_option</a><em> *option</em>, uint32_t<em> val</em><big>)</big><aclass="headerlink"href="#c.nghttp2_option_set_peer_max_concurrent_streams"title="Permalink to this definition">¶</a></dt>
<dd><p>This option sets the SETTINGS_MAX_CONCURRENT_STREAMS value of
remote endpoint as if it is received in SETTINGS frame. Without
specifying this option, before the local endpoint receives
SETTINGS_MAX_CONCURRENT_STREAMS in SETTINGS frame from remote
endpoint, SETTINGS_MAX_CONCURRENT_STREAMS is unlimited. This may
cause problem if local endpoint submits lots of requests
initially and sending them at once to the remote peer may lead to
the rejection of some requests. Specifying this option to the
sensible value, say 100, may avoid this kind of issue. This value
will be overwritten if the local endpoint receives
SETTINGS_MAX_CONCURRENT_STREAMS from the remote endpoint.</p>
int <ttclass="descname">nghttp2_session_client_new</tt><big>(</big><aclass="reference internal"href="#c.nghttp2_session"title="nghttp2_session">nghttp2_session</a><em> **session_ptr</em>, const <aclass="reference internal"href="#c.nghttp2_session_callbacks"title="nghttp2_session_callbacks">nghttp2_session_callbacks</a><em> *callbacks</em>, void<em> *user_data</em><big>)</big><aclass="headerlink"href="#c.nghttp2_session_client_new"title="Permalink to this definition">¶</a></dt>
<p>The <aclass="reference internal"href="#c.nghttp2_session_callbacks.send_callback"title="nghttp2_session_callbacks.send_callback"><ttclass="xref c c-member docutils literal"><spanclass="pre">nghttp2_session_callbacks.send_callback</span></tt></a> must be
specified. If the application code uses <aclass="reference internal"href="#c.nghttp2_session_recv"title="nghttp2_session_recv"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_recv()</span></tt></a>,
the <aclass="reference internal"href="#c.nghttp2_session_callbacks.recv_callback"title="nghttp2_session_callbacks.recv_callback"><ttclass="xref c c-member docutils literal"><spanclass="pre">nghttp2_session_callbacks.recv_callback</span></tt></a> must be
int <ttclass="descname">nghttp2_session_server_new</tt><big>(</big><aclass="reference internal"href="#c.nghttp2_session"title="nghttp2_session">nghttp2_session</a><em> **session_ptr</em>, const <aclass="reference internal"href="#c.nghttp2_session_callbacks"title="nghttp2_session_callbacks">nghttp2_session_callbacks</a><em> *callbacks</em>, void<em> *user_data</em><big>)</big><aclass="headerlink"href="#c.nghttp2_session_server_new"title="Permalink to this definition">¶</a></dt>
<p>The <aclass="reference internal"href="#c.nghttp2_session_callbacks.send_callback"title="nghttp2_session_callbacks.send_callback"><ttclass="xref c c-member docutils literal"><spanclass="pre">nghttp2_session_callbacks.send_callback</span></tt></a> must be
specified. If the application code uses <aclass="reference internal"href="#c.nghttp2_session_recv"title="nghttp2_session_recv"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_recv()</span></tt></a>,
the <aclass="reference internal"href="#c.nghttp2_session_callbacks.recv_callback"title="nghttp2_session_callbacks.recv_callback"><ttclass="xref c c-member docutils literal"><spanclass="pre">nghttp2_session_callbacks.recv_callback</span></tt></a> must be
int <ttclass="descname">nghttp2_session_client_new2</tt><big>(</big><aclass="reference internal"href="#c.nghttp2_session"title="nghttp2_session">nghttp2_session</a><em> **session_ptr</em>, const <aclass="reference internal"href="#c.nghttp2_session_callbacks"title="nghttp2_session_callbacks">nghttp2_session_callbacks</a><em> *callbacks</em>, void<em> *user_data</em>, const <aclass="reference internal"href="#c.nghttp2_option"title="nghttp2_option">nghttp2_option</a><em> *option</em><big>)</big><aclass="headerlink"href="#c.nghttp2_session_client_new2"title="Permalink to this definition">¶</a></dt>
<dd><p>Like <aclass="reference internal"href="#c.nghttp2_session_client_new"title="nghttp2_session_client_new"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_client_new()</span></tt></a>, but with additional options
int <ttclass="descname">nghttp2_session_server_new2</tt><big>(</big><aclass="reference internal"href="#c.nghttp2_session"title="nghttp2_session">nghttp2_session</a><em> **session_ptr</em>, const <aclass="reference internal"href="#c.nghttp2_session_callbacks"title="nghttp2_session_callbacks">nghttp2_session_callbacks</a><em> *callbacks</em>, void<em> *user_data</em>, const <aclass="reference internal"href="#c.nghttp2_option"title="nghttp2_option">nghttp2_option</a><em> *option</em><big>)</big><aclass="headerlink"href="#c.nghttp2_session_server_new2"title="Permalink to this definition">¶</a></dt>
<dd><p>Like <aclass="reference internal"href="#c.nghttp2_session_server_new"title="nghttp2_session_server_new"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_server_new()</span></tt></a>, but with additional options
void <ttclass="descname">nghttp2_session_del</tt><big>(</big><aclass="reference internal"href="#c.nghttp2_session"title="nghttp2_session">nghttp2_session</a><em> *session</em><big>)</big><aclass="headerlink"href="#c.nghttp2_session_del"title="Permalink to this definition">¶</a></dt>
int <ttclass="descname">nghttp2_session_send</tt><big>(</big><aclass="reference internal"href="#c.nghttp2_session"title="nghttp2_session">nghttp2_session</a><em> *session</em><big>)</big><aclass="headerlink"href="#c.nghttp2_session_send"title="Permalink to this definition">¶</a></dt>
<aclass="reference internal"href="#c.nghttp2_session_callbacks.send_callback"title="nghttp2_session_callbacks.send_callback"><ttclass="xref c c-member docutils literal"><spanclass="pre">nghttp2_session_callbacks.send_callback</span></tt></a> returns
<aclass="reference internal"href="#c.NGHTTP2_ERR_WOULDBLOCK"title="NGHTTP2_ERR_WOULDBLOCK"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_ERR_WOULDBLOCK</span></tt></a> or the outbound queue becomes empty.
<aclass="reference internal"href="#c.nghttp2_session_callbacks.on_frame_not_send_callback"title="nghttp2_session_callbacks.on_frame_not_send_callback"><ttclass="xref c c-member docutils literal"><spanclass="pre">nghttp2_session_callbacks.on_frame_not_send_callback</span></tt></a> is
<li><aclass="reference internal"href="#c.nghttp2_session_callbacks.before_frame_send_callback"title="nghttp2_session_callbacks.before_frame_send_callback"><ttclass="xref c c-member docutils literal"><spanclass="pre">nghttp2_session_callbacks.before_frame_send_callback</span></tt></a> is
<li><aclass="reference internal"href="#c.nghttp2_session_callbacks.send_callback"title="nghttp2_session_callbacks.send_callback"><ttclass="xref c c-member docutils literal"><spanclass="pre">nghttp2_session_callbacks.send_callback</span></tt></a> is invoked one
<li><aclass="reference internal"href="#c.nghttp2_session_callbacks.on_frame_send_callback"title="nghttp2_session_callbacks.on_frame_send_callback"><ttclass="xref c c-member docutils literal"><spanclass="pre">nghttp2_session_callbacks.on_frame_send_callback</span></tt></a> is
<aclass="reference internal"href="#c.nghttp2_session_callbacks.on_stream_close_callback"title="nghttp2_session_callbacks.on_stream_close_callback"><ttclass="xref c c-member docutils literal"><spanclass="pre">nghttp2_session_callbacks.on_stream_close_callback</span></tt></a> is
ssize_t <ttclass="descname">nghttp2_session_mem_send</tt><big>(</big><aclass="reference internal"href="#c.nghttp2_session"title="nghttp2_session">nghttp2_session</a><em> *session</em>, const uint8_t<em> **data_ptr</em><big>)</big><aclass="headerlink"href="#c.nghttp2_session_mem_send"title="Permalink to this definition">¶</a></dt>
<p>This function behaves like <aclass="reference internal"href="#c.nghttp2_session_send"title="nghttp2_session_send"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_send()</span></tt></a> except that
it does not use <aclass="reference internal"href="#c.nghttp2_session_callbacks.send_callback"title="nghttp2_session_callbacks.send_callback"><ttclass="xref c c-member docutils literal"><spanclass="pre">nghttp2_session_callbacks.send_callback</span></tt></a>
are called in the same way as they are in <aclass="reference internal"href="#c.nghttp2_session_send"title="nghttp2_session_send"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_send()</span></tt></a>.</p>
<aclass="reference internal"href="#c.nghttp2_session_mem_send"title="nghttp2_session_mem_send"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_mem_send()</span></tt></a> or <aclass="reference internal"href="#c.nghttp2_session_send"title="nghttp2_session_send"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_send()</span></tt></a>.</p>
int <ttclass="descname">nghttp2_session_recv</tt><big>(</big><aclass="reference internal"href="#c.nghttp2_session"title="nghttp2_session">nghttp2_session</a><em> *session</em><big>)</big><aclass="headerlink"href="#c.nghttp2_session_recv"title="Permalink to this definition">¶</a></dt>
callback <aclass="reference internal"href="#c.nghttp2_session_callbacks.recv_callback"title="nghttp2_session_callbacks.recv_callback"><ttclass="xref c c-member docutils literal"><spanclass="pre">nghttp2_session_callbacks.recv_callback</span></tt></a> returns
<aclass="reference internal"href="#c.NGHTTP2_ERR_WOULDBLOCK"title="NGHTTP2_ERR_WOULDBLOCK"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_ERR_WOULDBLOCK</span></tt></a>. This function calls several
<li><aclass="reference internal"href="#c.nghttp2_session_callbacks.recv_callback"title="nghttp2_session_callbacks.recv_callback"><ttclass="xref c c-member docutils literal"><spanclass="pre">nghttp2_session_callbacks.recv_callback</span></tt></a> is invoked one
<li><aclass="reference internal"href="#c.nghttp2_session_callbacks.recv_callback"title="nghttp2_session_callbacks.recv_callback"><ttclass="xref c c-member docutils literal"><spanclass="pre">nghttp2_session_callbacks.recv_callback</span></tt></a> is invoked
<aclass="reference internal"href="#c.nghttp2_session_callbacks.on_frame_recv_callback"title="nghttp2_session_callbacks.on_frame_recv_callback"><ttclass="xref c c-member docutils literal"><spanclass="pre">nghttp2_session_callbacks.on_frame_recv_callback</span></tt></a> is
<li><aclass="reference internal"href="#c.nghttp2_session_callbacks.recv_callback"title="nghttp2_session_callbacks.recv_callback"><ttclass="xref c c-member docutils literal"><spanclass="pre">nghttp2_session_callbacks.recv_callback</span></tt></a> is invoked
<aclass="reference internal"href="#c.nghttp2_session_callbacks.on_header_callback"title="nghttp2_session_callbacks.on_header_callback"><ttclass="xref c c-member docutils literal"><spanclass="pre">nghttp2_session_callbacks.on_header_callback</span></tt></a> is
<aclass="reference internal"href="#c.nghttp2_session_callbacks.on_frame_recv_callback"title="nghttp2_session_callbacks.on_frame_recv_callback"><ttclass="xref c c-member docutils literal"><spanclass="pre">nghttp2_session_callbacks.on_frame_recv_callback</span></tt></a> is
<aclass="reference internal"href="#c.nghttp2_session_callbacks.on_frame_recv_callback"title="nghttp2_session_callbacks.on_frame_recv_callback"><ttclass="xref c c-member docutils literal"><spanclass="pre">nghttp2_session_callbacks.on_frame_recv_callback</span></tt></a> is
ssize_t <ttclass="descname">nghttp2_session_mem_recv</tt><big>(</big><aclass="reference internal"href="#c.nghttp2_session"title="nghttp2_session">nghttp2_session</a><em> *session</em>, const uint8_t<em> *in</em>, size_t<em> inlen</em><big>)</big><aclass="headerlink"href="#c.nghttp2_session_mem_recv"title="Permalink to this definition">¶</a></dt>
<p>This function behaves like <aclass="reference internal"href="#c.nghttp2_session_recv"title="nghttp2_session_recv"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_recv()</span></tt></a> except that it
does not use <aclass="reference internal"href="#c.nghttp2_session_callbacks.recv_callback"title="nghttp2_session_callbacks.recv_callback"><ttclass="xref c c-member docutils literal"><spanclass="pre">nghttp2_session_callbacks.recv_callback</span></tt></a> to
<aclass="reference internal"href="#c.NGHTTP2_ERR_PAUSE"title="NGHTTP2_ERR_PAUSE"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_ERR_PAUSE</span></tt></a> is returned from
<aclass="reference internal"href="#c.nghttp2_session_callbacks.on_header_callback"title="nghttp2_session_callbacks.on_header_callback"><ttclass="xref c c-member docutils literal"><spanclass="pre">nghttp2_session_callbacks.on_header_callback</span></tt></a> or
<aclass="reference internal"href="#c.nghttp2_session_callbacks.on_data_chunk_recv_callback"title="nghttp2_session_callbacks.on_data_chunk_recv_callback"><ttclass="xref c c-member docutils literal"><spanclass="pre">nghttp2_session_callbacks.on_data_chunk_recv_callback</span></tt></a>.
If <aclass="reference internal"href="#c.NGHTTP2_ERR_PAUSE"title="NGHTTP2_ERR_PAUSE"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_ERR_PAUSE</span></tt></a> is used, the return value includes the
int <ttclass="descname">nghttp2_session_resume_data</tt><big>(</big><aclass="reference internal"href="#c.nghttp2_session"title="nghttp2_session">nghttp2_session</a><em> *session</em>, int32_t<em> stream_id</em><big>)</big><aclass="headerlink"href="#c.nghttp2_session_resume_data"title="Permalink to this definition">¶</a></dt>
int <ttclass="descname">nghttp2_session_want_read</tt><big>(</big><aclass="reference internal"href="#c.nghttp2_session"title="nghttp2_session">nghttp2_session</a><em> *session</em><big>)</big><aclass="headerlink"href="#c.nghttp2_session_want_read"title="Permalink to this definition">¶</a></dt>
<p>If both <aclass="reference internal"href="#c.nghttp2_session_want_read"title="nghttp2_session_want_read"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_want_read()</span></tt></a> and
<aclass="reference internal"href="#c.nghttp2_session_want_write"title="nghttp2_session_want_write"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_want_write()</span></tt></a> return 0, the application should
int <ttclass="descname">nghttp2_session_want_write</tt><big>(</big><aclass="reference internal"href="#c.nghttp2_session"title="nghttp2_session">nghttp2_session</a><em> *session</em><big>)</big><aclass="headerlink"href="#c.nghttp2_session_want_write"title="Permalink to this definition">¶</a></dt>
<p>If both <aclass="reference internal"href="#c.nghttp2_session_want_read"title="nghttp2_session_want_read"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_want_read()</span></tt></a> and
<aclass="reference internal"href="#c.nghttp2_session_want_write"title="nghttp2_session_want_write"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_want_write()</span></tt></a> return 0, the application should
void* <ttclass="descname">nghttp2_session_get_stream_user_data</tt><big>(</big><aclass="reference internal"href="#c.nghttp2_session"title="nghttp2_session">nghttp2_session</a><em> *session</em>, int32_t<em> stream_id</em><big>)</big><aclass="headerlink"href="#c.nghttp2_session_get_stream_user_data"title="Permalink to this definition">¶</a></dt>
stream_user_data is provided by <aclass="reference internal"href="#c.nghttp2_submit_request"title="nghttp2_submit_request"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_submit_request()</span></tt></a>,
<aclass="reference internal"href="#c.nghttp2_submit_headers"title="nghttp2_submit_headers"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_submit_headers()</span></tt></a> or
<aclass="reference internal"href="#c.nghttp2_session_set_stream_user_data"title="nghttp2_session_set_stream_user_data"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_set_stream_user_data()</span></tt></a>. Unless it is set using
<aclass="reference internal"href="#c.nghttp2_session_set_stream_user_data"title="nghttp2_session_set_stream_user_data"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_set_stream_user_data()</span></tt></a>, if the stream is
int <ttclass="descname">nghttp2_session_set_stream_user_data</tt><big>(</big><aclass="reference internal"href="#c.nghttp2_session"title="nghttp2_session">nghttp2_session</a><em> *session</em>, int32_t<em> stream_id</em>, void<em> *stream_user_data</em><big>)</big><aclass="headerlink"href="#c.nghttp2_session_set_stream_user_data"title="Permalink to this definition">¶</a></dt>
size_t <ttclass="descname">nghttp2_session_get_outbound_queue_size</tt><big>(</big><aclass="reference internal"href="#c.nghttp2_session"title="nghttp2_session">nghttp2_session</a><em> *session</em><big>)</big><aclass="headerlink"href="#c.nghttp2_session_get_outbound_queue_size"title="Permalink to this definition">¶</a></dt>
int32_t <ttclass="descname">nghttp2_session_get_stream_effective_recv_data_length</tt><big>(</big><aclass="reference internal"href="#c.nghttp2_session"title="nghttp2_session">nghttp2_session</a><em> *session</em>, int32_t<em> stream_id</em><big>)</big><aclass="headerlink"href="#c.nghttp2_session_get_stream_effective_recv_data_length"title="Permalink to this definition">¶</a></dt>
<aclass="reference internal"href="#c.nghttp2_submit_window_update"title="nghttp2_submit_window_update"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_submit_window_update()</span></tt></a>. This function takes into account
window_size_increment with <aclass="reference internal"href="#c.nghttp2_submit_window_update"title="nghttp2_submit_window_update"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_submit_window_update()</span></tt></a>, this
int32_t <ttclass="descname">nghttp2_session_get_stream_effective_local_window_size</tt><big>(</big><aclass="reference internal"href="#c.nghttp2_session"title="nghttp2_session">nghttp2_session</a><em> *session</em>, int32_t<em> stream_id</em><big>)</big><aclass="headerlink"href="#c.nghttp2_session_get_stream_effective_local_window_size"title="Permalink to this definition">¶</a></dt>
<aclass="reference internal"href="#c.nghttp2_submit_window_update"title="nghttp2_submit_window_update"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_submit_window_update()</span></tt></a>. This function takes into account
int32_t <ttclass="descname">nghttp2_session_get_effective_recv_data_length</tt><big>(</big><aclass="reference internal"href="#c.nghttp2_session"title="nghttp2_session">nghttp2_session</a><em> *session</em><big>)</big><aclass="headerlink"href="#c.nghttp2_session_get_effective_recv_data_length"title="Permalink to this definition">¶</a></dt>
<aclass="reference internal"href="#c.nghttp2_submit_window_update"title="nghttp2_submit_window_update"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_submit_window_update()</span></tt></a>. This function takes into account
with <aclass="reference internal"href="#c.nghttp2_submit_window_update"title="nghttp2_submit_window_update"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_submit_window_update()</span></tt></a>, this function returns the
int32_t <ttclass="descname">nghttp2_session_get_effective_local_window_size</tt><big>(</big><aclass="reference internal"href="#c.nghttp2_session"title="nghttp2_session">nghttp2_session</a><em> *session</em><big>)</big><aclass="headerlink"href="#c.nghttp2_session_get_effective_local_window_size"title="Permalink to this definition">¶</a></dt>
<aclass="reference internal"href="#c.nghttp2_submit_window_update"title="nghttp2_submit_window_update"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_submit_window_update()</span></tt></a>. This function takes into account
int32_t <ttclass="descname">nghttp2_session_get_stream_remote_window_size</tt><big>(</big><aclass="reference internal"href="#c.nghttp2_session"title="nghttp2_session">nghttp2_session</a>*<em> session</em>, int32_t<em> stream_id</em><big>)</big><aclass="headerlink"href="#c.nghttp2_session_get_stream_remote_window_size"title="Permalink to this definition">¶</a></dt>
<dd><p>Returns the remote window size for a given stream <em>stream_id</em>.
This is the amount of flow-controlled payload (e.g., DATA) that the
local endpoint can send without WINDOW_UPDATE.</p>
int <ttclass="descname">nghttp2_session_terminate_session</tt><big>(</big><aclass="reference internal"href="#c.nghttp2_session"title="nghttp2_session">nghttp2_session</a><em> *session</em>, <aclass="reference internal"href="#c.nghttp2_error_code"title="nghttp2_error_code">nghttp2_error_code</a><em> error_code</em><big>)</big><aclass="headerlink"href="#c.nghttp2_session_terminate_session"title="Permalink to this definition">¶</a></dt>
<aclass="reference internal"href="#c.nghttp2_session_want_read"title="nghttp2_session_want_read"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_want_read()</span></tt></a> and <aclass="reference internal"href="#c.nghttp2_session_want_write"title="nghttp2_session_want_write"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_want_write()</span></tt></a>
this function is invoked, <aclass="reference internal"href="#c.nghttp2_session_want_read"title="nghttp2_session_want_read"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_want_read()</span></tt></a> and
<aclass="reference internal"href="#c.nghttp2_session_want_write"title="nghttp2_session_want_write"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_want_write()</span></tt></a> returns 0 immediately after this
processed after GOAWAY, use <aclass="reference internal"href="#c.nghttp2_submit_goaway"title="nghttp2_submit_goaway"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_submit_goaway()</span></tt></a> instead.</p>
int <ttclass="descname">nghttp2_session_upgrade</tt><big>(</big><aclass="reference internal"href="#c.nghttp2_session"title="nghttp2_session">nghttp2_session</a><em> *session</em>, const uint8_t<em> *settings_payload</em>, size_t<em> settings_payloadlen</em>, void<em> *stream_user_data</em><big>)</big><aclass="headerlink"href="#c.nghttp2_session_upgrade"title="Permalink to this definition">¶</a></dt>
<aclass="reference internal"href="#c.nghttp2_submit_settings"title="nghttp2_submit_settings"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_submit_settings()</span></tt></a>. This means that the client application
ssize_t <ttclass="descname">nghttp2_pack_settings_payload</tt><big>(</big>uint8_t<em> *buf</em>, size_t<em> buflen</em>, const <aclass="reference internal"href="#c.nghttp2_settings_entry"title="nghttp2_settings_entry">nghttp2_settings_entry</a><em> *iv</em>, size_t<em> niv</em><big>)</big><aclass="headerlink"href="#c.nghttp2_pack_settings_payload"title="Permalink to this definition">¶</a></dt>
const char* <ttclass="descname">nghttp2_strerror</tt><big>(</big>int<em> lib_error_code</em><big>)</big><aclass="headerlink"href="#c.nghttp2_strerror"title="Permalink to this definition">¶</a></dt>
<em>lib_error_code</em> must be one of the <aclass="reference internal"href="#c.nghttp2_error"title="nghttp2_error"><ttclass="xref c c-macro docutils literal"><spanclass="pre">nghttp2_error</span></tt></a>.</p>
void <ttclass="descname">nghttp2_priority_spec_group_init</tt><big>(</big><aclass="reference internal"href="#c.nghttp2_priority_spec"title="nghttp2_priority_spec">nghttp2_priority_spec</a><em> *pri_spec</em>, int32_t<em> pri_group_id</em>, int32_t<em> weight</em><big>)</big><aclass="headerlink"href="#c.nghttp2_priority_spec_group_init"title="Permalink to this definition">¶</a></dt>
<dd><p>Initializes <em>pri_spec</em> with priority group ID <em>pri_group_id</em> and
its weight <em>weight</em>.</p>
<p>The <em>weight</em> must be in [<aclass="reference internal"href="#c.NGHTTP2_MIN_WEIGHT"title="NGHTTP2_MIN_WEIGHT"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_MIN_WEIGHT</span></tt></a>,
<aclass="reference internal"href="#c.NGHTTP2_MAX_WEIGHT"title="NGHTTP2_MAX_WEIGHT"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_MAX_WEIGHT</span></tt></a>], inclusive. If <em>weight</em> is strictly
less than <aclass="reference internal"href="#c.NGHTTP2_MIN_WEIGHT"title="NGHTTP2_MIN_WEIGHT"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_MIN_WEIGHT</span></tt></a>, it becomes
<aclass="reference internal"href="#c.NGHTTP2_MIN_WEIGHT"title="NGHTTP2_MIN_WEIGHT"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_MIN_WEIGHT</span></tt></a>. If it is strictly greater than
<aclass="reference internal"href="#c.NGHTTP2_MAX_WEIGHT"title="NGHTTP2_MAX_WEIGHT"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_MAX_WEIGHT</span></tt></a>, it becomes <aclass="reference internal"href="#c.NGHTTP2_MAX_WEIGHT"title="NGHTTP2_MAX_WEIGHT"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_MAX_WEIGHT</span></tt></a>.</p>
<p>To specify weight for the default priority group (which is the same
as the stream ID of the stream) in <aclass="reference internal"href="#c.nghttp2_submit_request"title="nghttp2_submit_request"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_submit_request()</span></tt></a> and
<aclass="reference internal"href="#c.nghttp2_submit_headers"title="nghttp2_submit_headers"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_submit_headers()</span></tt></a> and its stream ID is not known in
advance, specify -1 to <em>pri_group_id</em>.</p>
</dd></dl>
<dlclass="function">
<dtid="c.nghttp2_priority_spec_dep_init">
void <ttclass="descname">nghttp2_priority_spec_dep_init</tt><big>(</big><aclass="reference internal"href="#c.nghttp2_priority_spec"title="nghttp2_priority_spec">nghttp2_priority_spec</a><em> *pri_spec</em>, int32_t<em> stream_id</em>, int<em> exclusive</em><big>)</big><aclass="headerlink"href="#c.nghttp2_priority_spec_dep_init"title="Permalink to this definition">¶</a></dt>
<dd><p>Initializes <em>pri_spec</em> with the <em>stream_id</em> of the stream to depend
on and its exclusive flag. If <em>exclusive</em> is nonzero, exclusive
<p>The <em>pri_spec</em> is priority specification of this request. <ttclass="docutils literal"><spanclass="pre">NULL</span></tt>
means the default priority (priority group ID becomes its stream ID
and weight is <aclass="reference internal"href="#c.NGHTTP2_DEFAULT_WEIGHT"title="NGHTTP2_DEFAULT_WEIGHT"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_DEFAULT_WEIGHT</span></tt></a>). To specify the
priority, use either <aclass="reference internal"href="#c.nghttp2_priority_spec_group_init"title="nghttp2_priority_spec_group_init"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_priority_spec_group_init()</span></tt></a> or
<aclass="reference internal"href="#c.nghttp2_priority_spec_dep_init"title="nghttp2_priority_spec_dep_init"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_priority_spec_dep_init()</span></tt></a>. If <em>pri_spec</em> is not <ttclass="docutils literal"><spanclass="pre">NULL</span></tt>,
<p>The <em>nva</em> is an array of name/value pair <aclass="reference internal"href="#c.nghttp2_nv"title="nghttp2_nv"><ttclass="xref c c-type docutils literal"><spanclass="pre">nghttp2_nv</span></tt></a> with
<p>If <em>data_prd</em> is not <ttclass="docutils literal"><spanclass="pre">NULL</span></tt>, it provides data which will be sent
in subsequent DATA frames. In this case, a method that allows
request message bodies
(<aclass="reference external"href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec9.html#sec9">http://www.w3.org/Protocols/rfc2616/rfc2616-sec9.html#sec9</a>) must
be specified with <ttclass="docutils literal"><spanclass="pre">:method</span></tt> key in <em>nva</em> (e.g. <ttclass="docutils literal"><spanclass="pre">POST</span></tt>). This
<aclass="reference internal"href="#c.nghttp2_session_callbacks.before_frame_send_callback"title="nghttp2_session_callbacks.before_frame_send_callback"><ttclass="xref c c-member docutils literal"><spanclass="pre">nghttp2_session_callbacks.before_frame_send_callback</span></tt></a>. This
<aclass="reference internal"href="#c.nghttp2_session_get_stream_user_data"title="nghttp2_session_get_stream_user_data"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_get_stream_user_data()</span></tt></a> can be used to get
int <ttclass="descname">nghttp2_submit_response</tt><big>(</big><aclass="reference internal"href="#c.nghttp2_session"title="nghttp2_session">nghttp2_session</a><em> *session</em>, int32_t<em> stream_id</em>, const <aclass="reference internal"href="#c.nghttp2_nv"title="nghttp2_nv">nghttp2_nv</a><em> *nva</em>, size_t<em> nvlen</em>, const <aclass="reference internal"href="#c.nghttp2_data_provider"title="nghttp2_data_provider">nghttp2_data_provider</a><em> *data_prd</em><big>)</big><aclass="headerlink"href="#c.nghttp2_submit_response"title="Permalink to this definition">¶</a></dt>
<p>The <em>nva</em> is an array of name/value pair <aclass="reference internal"href="#c.nghttp2_nv"title="nghttp2_nv"><ttclass="xref c c-type docutils literal"><spanclass="pre">nghttp2_nv</span></tt></a> with
<em>session</em> must be configured using <aclass="reference internal"href="#c.nghttp2_session_server_new"title="nghttp2_session_server_new"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_server_new()</span></tt></a>
must be reserved using <aclass="reference internal"href="#c.nghttp2_submit_push_promise"title="nghttp2_submit_push_promise"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_submit_push_promise()</span></tt></a>.</p>
<p>If <em>flags</em> includes <aclass="reference internal"href="#c.NGHTTP2_FLAG_END_STREAM"title="NGHTTP2_FLAG_END_STREAM"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_FLAG_END_STREAM</span></tt></a>, this frame has
<p>The <em>pri_spec</em> is priority specification of this request. <ttclass="docutils literal"><spanclass="pre">NULL</span></tt>
means the default priority (priority group ID becomes its stream ID
and weight is <aclass="reference internal"href="#c.NGHTTP2_DEFAULT_WEIGHT"title="NGHTTP2_DEFAULT_WEIGHT"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_DEFAULT_WEIGHT</span></tt></a>). To specify the
priority, use either <aclass="reference internal"href="#c.nghttp2_priority_spec_group_init"title="nghttp2_priority_spec_group_init"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_priority_spec_group_init()</span></tt></a> or
<aclass="reference internal"href="#c.nghttp2_priority_spec_dep_init"title="nghttp2_priority_spec_dep_init"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_priority_spec_dep_init()</span></tt></a>. If <em>pri_spec</em> is not <ttclass="docutils literal"><spanclass="pre">NULL</span></tt>,
<p>The <em>nva</em> is an array of name/value pair <aclass="reference internal"href="#c.nghttp2_nv"title="nghttp2_nv"><ttclass="xref c c-type docutils literal"><spanclass="pre">nghttp2_nv</span></tt></a> with
<aclass="reference internal"href="#c.nghttp2_submit_request"title="nghttp2_submit_request"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_submit_request()</span></tt></a> is useful.</p>
int <ttclass="descname">nghttp2_submit_data</tt><big>(</big><aclass="reference internal"href="#c.nghttp2_session"title="nghttp2_session">nghttp2_session</a><em> *session</em>, uint8_t<em> flags</em>, int32_t<em> stream_id</em>, const <aclass="reference internal"href="#c.nghttp2_data_provider"title="nghttp2_data_provider">nghttp2_data_provider</a><em> *data_prd</em><big>)</big><aclass="headerlink"href="#c.nghttp2_submit_data"title="Permalink to this definition">¶</a></dt>
<aclass="reference internal"href="#c.NGHTTP2_FLAG_END_STREAM"title="NGHTTP2_FLAG_END_STREAM"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_FLAG_END_STREAM</span></tt></a>, the last DATA frame has END_STREAM
flag set. If <em>flags</em> contains <aclass="reference internal"href="#c.NGHTTP2_FLAG_END_SEGMENT"title="NGHTTP2_FLAG_END_SEGMENT"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_FLAG_END_SEGMENT</span></tt></a>, the
int <ttclass="descname">nghttp2_submit_priority</tt><big>(</big><aclass="reference internal"href="#c.nghttp2_session"title="nghttp2_session">nghttp2_session</a><em> *session</em>, uint8_t<em> flags</em>, int32_t<em> stream_id</em>, const <aclass="reference internal"href="#c.nghttp2_priority_spec"title="nghttp2_priority_spec">nghttp2_priority_spec</a><em> *pri_spec</em><big>)</big><aclass="headerlink"href="#c.nghttp2_submit_priority"title="Permalink to this definition">¶</a></dt>
<p>The <em>pri_spec</em> is priority specification of this request. <ttclass="docutils literal"><spanclass="pre">NULL</span></tt>
is not allowed for this function. To specify the priority, use
either <aclass="reference internal"href="#c.nghttp2_priority_spec_group_init"title="nghttp2_priority_spec_group_init"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_priority_spec_group_init()</span></tt></a> or
<aclass="reference internal"href="#c.nghttp2_priority_spec_dep_init"title="nghttp2_priority_spec_dep_init"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_priority_spec_dep_init()</span></tt></a>. This function will copy its
int <ttclass="descname">nghttp2_submit_rst_stream</tt><big>(</big><aclass="reference internal"href="#c.nghttp2_session"title="nghttp2_session">nghttp2_session</a><em> *session</em>, uint8_t<em> flags</em>, int32_t<em> stream_id</em>, <aclass="reference internal"href="#c.nghttp2_error_code"title="nghttp2_error_code">nghttp2_error_code</a><em> error_code</em><big>)</big><aclass="headerlink"href="#c.nghttp2_submit_rst_stream"title="Permalink to this definition">¶</a></dt>
int <ttclass="descname">nghttp2_submit_settings</tt><big>(</big><aclass="reference internal"href="#c.nghttp2_session"title="nghttp2_session">nghttp2_session</a><em> *session</em>, uint8_t<em> flags</em>, const <aclass="reference internal"href="#c.nghttp2_settings_entry"title="nghttp2_settings_entry">nghttp2_settings_entry</a><em> *iv</em>, size_t<em> niv</em><big>)</big><aclass="headerlink"href="#c.nghttp2_submit_settings"title="Permalink to this definition">¶</a></dt>
pointer to the array of <aclass="reference internal"href="#c.nghttp2_settings_entry"title="nghttp2_settings_entry"><ttclass="xref c c-type docutils literal"><spanclass="pre">nghttp2_settings_entry</span></tt></a>. The <em>niv</em>
indicates the number of <aclass="reference internal"href="#c.nghttp2_settings_entry"title="nghttp2_settings_entry"><ttclass="xref c c-type docutils literal"><spanclass="pre">nghttp2_settings_entry</span></tt></a>.</p>
<p>SETTINGS with <aclass="reference internal"href="#c.NGHTTP2_FLAG_ACK"title="NGHTTP2_FLAG_ACK"><ttclass="xref c c-macro docutils literal"><spanclass="pre">NGHTTP2_FLAG_ACK</span></tt></a> is automatically submitted
int <ttclass="descname">nghttp2_submit_push_promise</tt><big>(</big><aclass="reference internal"href="#c.nghttp2_session"title="nghttp2_session">nghttp2_session</a><em> *session</em>, uint8_t<em> flags</em>, int32_t<em> stream_id</em>, const <aclass="reference internal"href="#c.nghttp2_nv"title="nghttp2_nv">nghttp2_nv</a><em> *nva</em>, size_t<em> nvlen</em>, void<em> *promised_stream_user_data</em><big>)</big><aclass="headerlink"href="#c.nghttp2_submit_push_promise"title="Permalink to this definition">¶</a></dt>
<p>The <em>nva</em> is an array of name/value pair <aclass="reference internal"href="#c.nghttp2_nv"title="nghttp2_nv"><ttclass="xref c c-type docutils literal"><spanclass="pre">nghttp2_nv</span></tt></a> with
<p>The <em>promised_stream_user_data</em> is a pointer to an arbitrary data
which is associated to the promised stream this frame will open and
make it in reserved state. It is available using
<aclass="reference internal"href="#c.nghttp2_session_get_stream_user_data"title="nghttp2_session_get_stream_user_data"><ttclass="xref c c-func docutils literal"><spanclass="pre">nghttp2_session_get_stream_user_data()</span></tt></a>. The application can
access it in <aclass="reference internal"href="#c.nghttp2_before_frame_send_callback"title="nghttp2_before_frame_send_callback"><ttclass="xref c c-type docutils literal"><spanclass="pre">nghttp2_before_frame_send_callback</span></tt></a> and
<aclass="reference internal"href="#c.nghttp2_on_frame_send_callback"title="nghttp2_on_frame_send_callback"><ttclass="xref c c-type docutils literal"><spanclass="pre">nghttp2_on_frame_send_callback</span></tt></a> of this frame.</p>
<aclass="reference internal"href="#c.nghttp2_session_callbacks.before_frame_send_callback"title="nghttp2_session_callbacks.before_frame_send_callback"><ttclass="xref c c-member docutils literal"><spanclass="pre">nghttp2_session_callbacks.before_frame_send_callback</span></tt></a>. This
int <ttclass="descname">nghttp2_submit_ping</tt><big>(</big><aclass="reference internal"href="#c.nghttp2_session"title="nghttp2_session">nghttp2_session</a><em> *session</em>, uint8_t<em> flags</em>, uint8_t<em> *opaque_data</em><big>)</big><aclass="headerlink"href="#c.nghttp2_submit_ping"title="Permalink to this definition">¶</a></dt>
int <ttclass="descname">nghttp2_submit_goaway</tt><big>(</big><aclass="reference internal"href="#c.nghttp2_session"title="nghttp2_session">nghttp2_session</a><em> *session</em>, uint8_t<em> flags</em>, <aclass="reference internal"href="#c.nghttp2_error_code"title="nghttp2_error_code">nghttp2_error_code</a><em> error_code</em>, const uint8_t<em> *opaque_data</em>, size_t<em> opaque_data_len</em><big>)</big><aclass="headerlink"href="#c.nghttp2_submit_goaway"title="Permalink to this definition">¶</a></dt>
int <ttclass="descname">nghttp2_submit_window_update</tt><big>(</big><aclass="reference internal"href="#c.nghttp2_session"title="nghttp2_session">nghttp2_session</a><em> *session</em>, uint8_t<em> flags</em>, int32_t<em> stream_id</em>, int32_t<em> window_size_increment</em><big>)</big><aclass="headerlink"href="#c.nghttp2_submit_window_update"title="Permalink to this definition">¶</a></dt>
int <ttclass="descname">nghttp2_nv_compare_name</tt><big>(</big>const <aclass="reference internal"href="#c.nghttp2_nv"title="nghttp2_nv">nghttp2_nv</a><em> *lhs</em>, const <aclass="reference internal"href="#c.nghttp2_nv"title="nghttp2_nv">nghttp2_nv</a><em> *rhs</em><big>)</big><aclass="headerlink"href="#c.nghttp2_nv_compare_name"title="Permalink to this definition">¶</a></dt>
int <ttclass="descname">nghttp2_select_next_protocol</tt><big>(</big>unsigned char<em> **out</em>, unsigned char<em> *outlen</em>, const unsigned char<em> *in</em>, unsigned int<em> inlen</em><big>)</big><aclass="headerlink"href="#c.nghttp2_select_next_protocol"title="Permalink to this definition">¶</a></dt>
<ttclass="docutils literal"><spanclass="pre">http/1.1</span></tt> and returns 0. The following step is not taken.</li>
<li>This function selects nothing and returns -1. (So called
non-overlap case). In this case, <em>out</em> and <em>outlen</em> are left
untouched.</li>
</ol>
<p>Selecting <ttclass="docutils literal"><spanclass="pre">HTTP-draft-04/2.0</span></tt> means that <ttclass="docutils literal"><spanclass="pre">HTTP-draft-04/2.0</span></tt> is
written into <em>*out</em> and its length (which is 17) is
<p>See <aclass="reference external"href="http://technotes.googlecode.com/git/nextprotoneg.html">http://technotes.googlecode.com/git/nextprotoneg.html</a> for more
int <ttclass="descname">nghttp2_gzip_inflate_new</tt><big>(</big><aclass="reference internal"href="#c.nghttp2_gzip"title="nghttp2_gzip">nghttp2_gzip</a><em> **inflater_ptr</em><big>)</big><aclass="headerlink"href="#c.nghttp2_gzip_inflate_new"title="Permalink to this definition">¶</a></dt>
void <ttclass="descname">nghttp2_gzip_inflate_del</tt><big>(</big><aclass="reference internal"href="#c.nghttp2_gzip"title="nghttp2_gzip">nghttp2_gzip</a><em> *inflater</em><big>)</big><aclass="headerlink"href="#c.nghttp2_gzip_inflate_del"title="Permalink to this definition">¶</a></dt>
int <ttclass="descname">nghttp2_gzip_inflate</tt><big>(</big><aclass="reference internal"href="#c.nghttp2_gzip"title="nghttp2_gzip">nghttp2_gzip</a><em> *inflater</em>, uint8_t<em> *out</em>, size_t<em> *outlen_ptr</em>, const uint8_t<em> *in</em>, size_t<em> *inlen_ptr</em><big>)</big><aclass="headerlink"href="#c.nghttp2_gzip_inflate"title="Permalink to this definition">¶</a></dt>
<aclass="reference internal"href="#c.nghttp2_info"title="nghttp2_info">nghttp2_info</a> *<ttclass="descname">nghttp2_version</tt><big>(</big>int<em> least_version</em><big>)</big><aclass="headerlink"href="#c.nghttp2_version"title="Permalink to this definition">¶</a></dt>
int <ttclass="descname">nghttp2_is_fatal</tt><big>(</big>int<em> lib_error</em><big>)</big><aclass="headerlink"href="#c.nghttp2_is_fatal"title="Permalink to this definition">¶</a></dt>
<dd><p>Returns nonzero if the <aclass="reference internal"href="#c.nghttp2_error"title="nghttp2_error"><ttclass="xref c c-type docutils literal"><spanclass="pre">nghttp2_error</span></tt></a> library error code
int <ttclass="descname">nghttp2_check_header_name</tt><big>(</big>const uint8_t<em> *name</em>, size_t<em> len</em><big>)</big><aclass="headerlink"href="#c.nghttp2_check_header_name"title="Permalink to this definition">¶</a></dt>
int <ttclass="descname">nghttp2_check_header_value</tt><big>(</big>const uint8_t<em> *value</em>, size_t<em> len</em><big>)</big><aclass="headerlink"href="#c.nghttp2_check_header_value"title="Permalink to this definition">¶</a></dt>