Validating the right number of parameters when calling a method