Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- "[{"sclass":"test","message":"hello","time":"2016-01-13T16:37:24+08:00"}][{"sclass":"test","message":"hello","time":"2016-01-13T16:37:30+08:00"}][{"sclass":"test","message":"hello","time":"2016-01-13T16:37:36+08:00"}][{"sclass":"test","message":"hello","time":"2016-01-13T16:37:43+08:00"}][{"sclass":"test","message":"hello","time":"2016-01-13T16:37:49+08:00"}][{"sclass":"test","message":"hello","time":"2016-01-13T16:37:55+08:00"}][{"sclass":"test","message":"hello","time":"2016-01-13T16:38:01+08:00"}][{"sclass":"test","message":"hello","time":"2016-01-13T16:38:07+08:00"}][{"sclass":"test","message":"hello","time":"2016-01-13T16:38:13+08:00"}][{"sclass":"test","message":"hello","time":"2016-01-13T16:38:20+08:00"}]"
- file = StringIO.new(data)
- file.each_line do |line|
- p JSON.parse(line)
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement