Chapter 15. Ruby and Data Formats

“Your information, sir,” the Librarian says. “Are you smart enough to tie that information into YOU ARE HERE?” Hiro says.“I’ll see what I can do, sir. The formats appear to be reconcilable.”

—Snow Crash, by Neal Stephenson

In computing, it is a fact of life that when information becomes complex enough, it evolves its own “mini-language” in which that information is best expressed. More often, it evolves multiple such mini-languages. We call these file formats or data formats.

Anyone who has used a computer can name many file formats. There are image formats such as GIF, JPG, and PNG; document formats such as DOC and PDF; “universal” formats such as CSV, JSON, and XML; and countless thousands of proprietary data ...

Get The Ruby Way: Solutions and Techniques in Ruby Programming, Third Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.