Validates an integer.
the validation state
the instance to validate
the minimum value
the maximum value