ENG-4825: First crack at refactoring parameterConverter to work right.

Change about 2/5ths of the code, but refactor quite a bit.