Completed class definitions and unit tests

Updated schema, continually improved test data, fleshed out class
definitions, fixed bugs.