Code Standards/PHP Doc improvements

This is the first commit on this branch. 

I'll group them into batches so it might be feasible to have some sort of review (well..)

Batch 1: 
Improvements to code base to follow coding standards (variable naming)
Improve phpdoc validation (formatting and types of attributes) - core api's E->Z so far.
Add type hints.

Batch 2: (to follow in an hour) will be core api's A-E and rest of code base.

I'll create a separate pull request to this one to cover a build process that any of us can run. Before doing that, i'll send a mantisbt-dev list email to get feedback on what OS's/tools our core developers run so I can test process validation scripts against those tools/OS's