added a standard "validate" method.