【文件属性】:
文件名称:ndjson.rb:Ruby的ndjson解析器和生成器
文件大小:2KB
文件格式:ZIP
更新时间:2021-05-16 05:40:24
Ruby
ndjson.rb
简单的ndjson解析器gem。
解析器以及生成器都使用IO对象或字符串。 字符串用open-uri宝石open-uri 。
请注意,这是由Ruby noob编写的,用于寻找真正的Ruby开发合作者。
用法
NDJSON :: Parser
require 'ndjson'
parser = NDJSON :: Parser . new ( $stdin )
parser . each { | l | puts l }
NDJSON :: Generator
generator = NDJSON :: Generator . new ( 'test.file' )
generator . write ( { :hello => "world" } )
generator . write ( { :noob => "what" } )
资源
【文件预览】:
ndjson.rb-master
----ndjson.gemspec(411B)
----lib()
--------ndjson.rb(560B)
----readme.md(774B)