Added Query class. Changed query processing functions to use Query class.
Added tests for schema and queries. Tests are not yet complete.