func importHttp2() {.importjs: "import * as http2 from \'http2\'@".}
-
Alias for import * as module_name from 'module_name';. Must be called once before using the module
func requireHttp2() {.importjs: "const http2 = require(\'http2\')@".}
-
Alias for const module_name = require('module_name');. Must be called once before using the module
func createSecureServer[T](options: JsObject; requestListener: T): Http2SecureServer {.
importjs: "http2.$1(#, #)".}
-
https://nodejs.org/api/http2.html#http2_http2_createsecureserver_options_onrequesthandler
func createSecureServer(options: JsObject): Http2SecureServer {.
importjs: "http2.$1(#)".}
-
https://nodejs.org/api/http2.html#http2_http2_createsecureserver_options_onrequesthandler
func createSecureServer[T](requestListener: T): Http2SecureServer {.
importjs: "http2.$1(#)".}
-
https://nodejs.org/api/http2.html#http2_http2_createsecureserver_options_onrequesthandler
func destroy(self: Http2Session or Http2ServerRequest or Http2Stream): auto {.
importjs: "#.$1()", discardable.}
-
https://nodejs.org/api/http2.html#http2_http2session_destroy_error_code
func ends(self: Http2ServerResponse; data: cstring or Buffer;
encoding = "utf-8".cstring): auto {.importjs: "#.end(#, #)",
discardable.}
-
https://nodejs.org/api/http2.html#http2_response_end_data_encoding_callback
func ends[T](self: Http2ServerResponse; callback: T): auto {.
importjs: "#.end(#)", discardable.}
-
https://nodejs.org/api/http2.html#http2_response_end_data_encoding_callback
func ends(self: Http2ServerResponse): auto {.importjs: "#.end()", discardable.}
-
https://nodejs.org/api/http2.html#http2_response_end_data_encoding_callback
func getHeader(self: Http2ServerResponse; name: cstring): auto {.
importjs: "#.$1(#)".}
-
https://nodejs.org/api/http2.html#http2_response_getheader_name
func removeHeader(self: Http2ServerResponse; name: cstring): bool {.
importjs: "#.$1(#)".}
-
https://nodejs.org/api/http2.html#http2_response_removeheader_name
func setHeader(self: Http2ServerResponse; name: cstring; value: auto): auto {.
importjs: "#.$1(#, #)".}
-
https://nodejs.org/api/http2.html#http2_response_setheader_name_value
func setTimeout[T](self: Http2Server or Http2SecureServer or Http2Stream or
Http2ServerRequest or
Http2ServerResponse; timeout: cint; callback: T): Http2SecureServer {.
importjs: "#.$1(#, #)", discardable.}
-
https://nodejs.org/api/http2.html#http2_http2session_settimeout_msecs_callback
func write[T](self: Http2ServerResponse; callback: T): bool {.
importjs: "#.$1(#)", discardable.}
-
https://nodejs.org/api/http2.html#http2_response_write_chunk_encoding_callback
func write(self: Http2ServerResponse; data: cstring; encoding = "utf-8".cstring): bool {.
importjs: "#.$1(# + \'\\n\', #)", discardable.}
-
https://nodejs.org/api/http2.html#http2_response_write_chunk_encoding_callback
- '\n' is automatically inserted at the end of data string.
func write(self: Http2ServerResponse; data: Buffer): bool {.importjs: "#.$1(#)",
discardable.}
-
https://nodejs.org/api/http2.html#http2_response_write_chunk_encoding_callback
func close(self: Http2SecureServer or Http2Server) {.importjs: "#.$1()".}
-
https://nodejs.org/api/http2.html#http2_http2session_close_callback
func close[T](self: Http2SecureServer or Http2Server; callback: T) {.
importjs: "#.$1(#)".}
-
https://nodejs.org/api/http2.html#http2_http2session_close_callback
func close[T](self: Http2Stream; code: cint; callback: T) {.
importjs: "#.$1(#, #)".}
-
https://nodejs.org/api/http2.html#http2_http2stream_close_code_callback
func close(self: Http2Stream; code: cint) {.importjs: "#.$1(#)".}
-
https://nodejs.org/api/http2.html#http2_http2stream_close_code_callback
func listen(self: Http2Server or Http2SecureServer) {.importjs: "#.$1()".}
-
https://nodejs.org/api/http.html#http_server_listen
func listen(self: Http2Server or Http2SecureServer; handle: JsObject;
backlog: cint) {.importjs: "#.$1(#, #)".}
-
https://nodejs.org/api/http.html#http_server_listen
func listen[T](self: Http2Server or Http2SecureServer; callback: T) {.
importjs: "#.$1(#)".}
-
https://nodejs.org/api/http.html#http_server_listen
func listen[T](self: Http2Server or Http2SecureServer; options: JsObject;
callback: T) {.importjs: "#.$1(#, #)".}
-
https://nodejs.org/api/http.html#http_server_listen
func listen[T](self: Http2Server or Http2SecureServer; path: cstring;
backlog: cint; callback: T) {.importjs: "#.$1(#, #, #)".}
-
https://nodejs.org/api/http.html#http_server_listen
func listen[T](self: Http2Server or Http2SecureServer; port: int; host: cstring;
callback: T) {.importjs: "#.$1(#, #, #)".}
-
https://nodejs.org/api/http.html#http_server_listen
func listen(self: Http2Server or Http2SecureServer; port: int; host: cstring) {.
importjs: "#.$1(#, #)".}
-
https://nodejs.org/api/http.html#http_server_listen
func listen(self: Http2Server or Http2SecureServer; port: int) {.
importjs: "#.$1(#)".}
-
https://nodejs.org/api/http.html#http_server_listen
func addTrailers(self: Http2ServerResponse; headers: JsObject) {.
importjs: "#.$1(#)".}
-
https://nodejs.org/api/http2.html#http2_response_addtrailers_headers
func getHeaderNames(self: Http2ServerResponse): seq[cstring] {.
importjs: "#.$1()".}
-
https://nodejs.org/api/http2.html#http2_response_getheadernames
func getHeaders(self: Http2ServerResponse): JsObject {.importjs: "#.$1()".}
-
https://nodejs.org/api/http2.html#http2_response_getheaders
func hasHeader(self: Http2ServerResponse; name: cstring): bool {.
importjs: "#.$1(#)".}
-
https://nodejs.org/api/http2.html#http2_response_hasheader_name
func writeContinue(self: Http2ServerResponse) {.importjs: "#.$1()".}
-
hhttps://nodejs.org/api/http2.html#http2_response_writecontinue
func writeHead(self: Http2ServerResponse; statusCode: int;
statusMessage: cstring): Http2ServerResponse {.
importjs: "#.$1(#, #)", discardable.}
-
https://nodejs.org/api/http2.html#http2_response_writehead_statuscode_statusmessage_headers
func writeHead(self: Http2ServerResponse; headers: JsObject or openArray[auto]): Http2ServerResponse {.
importjs: "#.$1(#)", discardable.}
-
https://nodejs.org/api/http2.html#http2_response_writehead_statuscode_statusmessage_headers
func writeHead(self: Http2ServerResponse; statusCode: int;
statusMessage: cstring; headers: openArray[(cstring, cstring)]): Http2ServerResponse {.
importjs: "#.$1(#, #)", discardable.}
-
https://nodejs.org/api/http2.html#http2_response_writehead_statuscode_statusmessage_headers
func createServer(): Http2Server {.importjs: "http.$1()".}
-
https://nodejs.org/api/http2.html#http2_http2_createserver_options_onrequesthandler
func createServer[T](options: JsObject; requestListener: T): Http2Server {.
importjs: "http2.$1(#, #)".}
-
https://nodejs.org/api/http2.html#http2_http2_createserver_options_onrequesthandler
func createServer(options: JsObject): Http2Server {.importjs: "http2.$1(#)".}
-
https://nodejs.org/api/http2.html#http2_http2_createserver_options_onrequesthandler
proc updateSettings(self: Http2SecureServer or Http2Server;
settings: Http2Settings) {.importjs: "#.$1(#)".}
-
https://nodejs.org/api/http2.html#http2_server_updatesettings_settings_1
proc getDefaultSettings(): Http2Settings {.importjs: "http2.$1()".}
-
https://nodejs.org/api/http2.html#http2_http2_getdefaultsettings
proc getPackedSettings(settings: Http2Settings): Buffer {.
importjs: "http2.$1(#)".}
-
https://nodejs.org/api/http2.html#http2_http2_getpackedsettings_settings
proc getUnpackedSettings(settings: Buffer): Http2Settings {.
importjs: "http2.$1(#)".}
-
https://nodejs.org/api/http2.html#http2_http2_getunpackedsettings_buf
proc createPushResponse[T](self: Http2ServerResponse; headers: JsObject;
callback: T): Http2Settings {.importjs: "#.$1(#, #)".}
-
https://nodejs.org/api/http2.html#http2_response_createpushresponse_headers_callback
proc connect(authority: cstring; options: JsObject): ClientHttp2Session {.
importjs: "http2.$1(#, #)".}
-
https://nodejs.org/api/http2.html#http2_server_updatesettings_settings
proc connect[T](authority: cstring; options: JsObject; callback: T): ClientHttp2Session {.
importjs: "http2.$1(#, #, #)".}
-
https://nodejs.org/api/http2.html#http2_server_updatesettings_settings
proc request(self: ClientHttp2Session; headers: JsObject; options: JsObject): ClientHttp2Stream {.
importjs: "#.$1(#, #)".}
-
https://nodejs.org/api/http2.html#http2_clienthttp2session_request_headers_options
proc request(self: ClientHttp2Session; headers: JsObject): ClientHttp2Stream {.
importjs: "#.$1(#)".}
-
https://nodejs.org/api/http2.html#http2_clienthttp2session_request_headers_options
proc priority(self: Http2Stream; options: JsObject) {.importjs: "#.$1(#)".}
-
https://nodejs.org/api/http2.html#http2_http2stream_priority_options
proc sendTrailers(self: Http2Stream; headers: JsObject) {.importjs: "#.$1(#)".}
-
https://nodejs.org/api/http2.html#http2_http2stream_sendtrailers_headers
proc additionalHeaders(self: ServerHttp2Stream; headers: JsObject) {.
importjs: "#.$1(#)".}
-
https://nodejs.org/api/http2.html#http2_http2stream_additionalheaders_headers
proc pushStream[T](self: ServerHttp2Stream; headers: JsObject;
options: JsObject; callback: T) {.importjs: "#.$1(#, #, #)".}
-
https://nodejs.org/api/http2.html#http2_http2stream_additionalheaders_headers
proc pushStream[T](self: ServerHttp2Stream; headers: JsObject; callback: T) {.
importjs: "#.$1(#, #)".}
-
https://nodejs.org/api/http2.html#http2_http2stream_additionalheaders_headers
proc respond(self: ServerHttp2Stream; headers: JsObject; options: JsObject) {.
importjs: "#.$1(#, #)".}
-
https://nodejs.org/api/http2.html#http2_http2stream_respond_headers_options
proc respond(self: ServerHttp2Stream; headers: JsObject) {.importjs: "#.$1(#)".}
-
https://nodejs.org/api/http2.html#http2_http2stream_respond_headers_options
proc respondWithFD(self: ServerHttp2Stream; fd: auto; headers: JsObject;
options: JsObject) {.importjs: "#.$1(#, #, #)".}
-
https://nodejs.org/api/http2.html#http2_http2stream_respondwithfd_fd_headers_options
proc respondWithFD(self: ServerHttp2Stream; fd: auto; headers: JsObject) {.
importjs: "#.$1(#, #)".}
-
https://nodejs.org/api/http2.html#http2_http2stream_respondwithfd_fd_headers_options
proc respondWithFD(self: ServerHttp2Stream; fd: auto) {.importjs: "#.$1(#)".}
-
https://nodejs.org/api/http2.html#http2_http2stream_respondwithfd_fd_headers_options
proc respondWithFile(self: ServerHttp2Stream; path: cstring or Buffer;
headers: JsObject; options: JsObject) {.
importjs: "#.$1(#, #, #)".}
-
https://nodejs.org/api/http2.html#http2_http2stream_respondwithfile_path_headers_options
proc respondWithFile(self: ServerHttp2Stream; path: cstring or Buffer;
headers: JsObject) {.importjs: "#.$1(#, #)".}
-
https://nodejs.org/api/http2.html#http2_http2stream_respondwithfile_path_headers_options
proc respondWithFile(self: ServerHttp2Stream; path: cstring or Buffer) {.
importjs: "#.$1(#)".}
-
https://nodejs.org/api/http2.html#http2_http2stream_respondwithfile_path_headers_options
func on[T](self: Http2Server or Http2SecureServer; event: cstring; callback: T) {.
importjs: "#.on(#, #)", discardable.}
-
func writeProcessing(self: Http2ServerResponse) {.importjs: "#.$1()".}
-
func address(self: Http2Server or Http2SecureServer): cstring {.
importjs: "#.$1()".}
-
func rawListeners(self: Http2Server or Http2SecureServer; event: cstring): seq[
auto] {.importjs: "#.$1(#)".}
-
func removeAllListeners(self: Http2Server or Http2SecureServer; event: cstring) {.
importjs: "#.$1(#)", discardable.}
-
func listeners(self: Http2Server or Http2SecureServer; eventName: cstring): seq[
auto] {.importjs: "#.$1(#)".}
-
func listenerCount(self: Http2Server or Http2SecureServer; eventName: cstring): cint {.
importjs: "#.$1(#)".}
-
func getMaxListeners(self: Http2Server or Http2SecureServer): cint {.
importjs: "#.$1()".}
-
func prependListener[T](self: Http2Server or Http2SecureServer; event: cstring;
callback: T) {.importjs: "#.$1(#, #)", discardable.}
-
func prependOnceListener[T](self: Http2Server or Http2SecureServer;
event: cstring; callback: T) {.
importjs: "#.$1(#, #)", discardable.}
-
func emit(self: Http2Server or Http2SecureServer; eventName: cstring; args: auto) {.
importjs: "#.emit(#, #)", varargs, discardable.}
-
func off[T](self: Http2Server or Http2SecureServer; event: cstring; callback: T) {.
importjs: "#.off(#, #)", discardable.}
-
func once[T](self: Http2Server or Http2SecureServer; event: cstring; callback: T) {.
importjs: "#.once(#, #)", discardable.}
-