On 20 November 2014 12:05, Gordon Ross <gordon.w.r...@gmail.com> wrote:
> Could one use some javascript code to convert the LDJSON form to the
> other proposed form? (with "stdout" and array wrapper stuff)
> Assuming that's true, I'd lean toward providing only the LDJSON form,
> which seems more "minimalist".

Absolutely.  If you're writing Javascript software that runs in a
Node.js environment, the "lstream" module will split input on any
stream (including "stdout" from a child process) into lines as they
are read into the process.  You can then parse and process each line
independently.  If you _need_ one big array, and your dataset fits in
entirely in the heap, you can assemble it trivially with Array.push()
as it arrives.

If you're asking about Javascript in the browser, there are myriad
frameworks targeting the browser environment (e.g. jQuery, etc).
You'd need to do whatever your framework supports for streaming big
datasets from remote servers, but the basic principle is the same.



Cheers.

-- 
Joshua M. Clulow
UNIX Admin/Developer
http://blog.sysmgr.org
_______________________________________________
developer mailing list
developer@open-zfs.org
http://lists.open-zfs.org/mailman/listinfo/developer

Reply via email to