picohttpparser

Bindings for picohttpparser.

Readme

nim-picohttpparser

Nim binding for picohttpparser.

##Setup In order to use these bindings in your program, you must install the picohttpparser.h header on your machine, and link your Nim program with picohttpparser.c.

The easiest way to do this is to:

  1. Copy the picohttpparser sources into your project sources,
  2. Use the cincludes Nim compiler flag to add the picohttpparser sources to the C compiler include search path,
  3. And create a Nim file that uses the compile pragma to compile picohttpparser.c.

##Usage To use the low level picohttpparser API binding, import picohttpparser_api in your program, and use parseRequest or tryParseRequest.

Converter procs toStringTableRef and toHttpHeaders are provided to convert picohttpparser's native seq[phr_header] header type to types that are often used in Nim libraries.

##Todo A high level picohttpparser API named picohttpparser would be nice. Patches welcome!

##License This project is licensed under the same license as picohttpparser, which is dual-licensed under the Perl License or the MIT License.

Need help? Read Nimble
Available versions:
License: MIT

Project website Hosted docs