codebase cleanup

* tabs to spaces
* underscore name prefix on non-public methods
* code docs