[phpdoc] Update PhpDoc

Update PhpDoc and refactor some code (no code changes).
wrong