Clean up basically: convert comments to PHPDoc, reformat file, replace \r\n with \n, add todo-comments, sort methods alphabetically.