Fix #1624: Implement case preservation in PDO class reflection.

Updated version of PR#1740