public void setIsRequired ( boolean required ) { if ( ! required ) { validators . remove ( REQUIRED_FIELD_VALIDATOR ) ; } else if ( ! isRequired ( ) ) { validators . add ( REQUIRED_FIELD_VALIDATOR ) ; } }
Sets whether this field is required to have user input .