/** * Adds a validator to the current field component. * * @param validator A Vaadin validator */ public void addValidator(Validator validator) { if (fieldComponent != null) { if (fieldComponent instanceof Field) { ((Field) fieldComponent).addValidator(validator); } else if (fieldComponent instanceof FilterContainer) { ((FilterContainer) fieldComponent).addValidator(validator); } } }
public FieldQuery<F> addValidator(Validator v) { for (Field<?> f : this) { f.addValidator(v); } return createQuery(); }