Added docs for toQuery and fromQuery. Fixes #136.