Initial code commit.

Needs more unit tests, but it should work.
Tabs to spaces.
Added TODO, and removed un-used import.
Touch up readme, with a few other changes