Added the possibility to add a validation method to a query parameter definition