Added a registration function.  Changed the way parameters are handled