Fixed typos
Fixed PHPDoc
Clean up classes and write comments