jsmn.nim
jsmn.nim copied to clipboard
Accept memory maps and streams
Memory maps for large JSON files would be nice to have, as well as support for some sort of streaming mechanism (for things like sockets).
can you explain more about these terms? Im not fimiliar with them. thank you
Well, currently the parsing procedures take in a string containing the entire file, and output a sequence containing all the json nodes.
While this works well for most cases, it breaks down when one is using a data stream containing an unknown amount of json data (like if a client is sending data to a server over a socket).
Memory mapped files are less of an issue. If a document is very big, it is sometimes more convenient to load it into memory using a memory mapping.
thank you, I will read mroe about it