QuickAddEntityComboBox extends QuickAddEntityField<ID, T, T> implements Refreshable, SharedProvider<T> { @Override public void refresh() { if (comboBox != null) { comboBox.refresh(getFilter()); } } @SafeVarargs  QuickAddEntityComboBox(EntityModel<T> entityModel, AttributeModel attributeModel, BaseService<ID, T> service,
			SelectMode mode, SerializablePredicate<T> filter, boolean search, ListDataProvider<T> sharedProvider,
			List<T> items, SortOrder<?>... sortOrder); @Override Registration addValueChangeListener(
			ValueChangeListener<? super ComponentValueChangeEvent<CustomField<T>, T>> listener); @Override void clearAdditionalFilter(); @Override void focus(); EntityComboBox<ID, T> getComboBox(); @Override @SuppressWarnings("unchecked") ListDataProvider<T> getSharedProvider(); @Override T getValue(); @Override void refresh(); @Override void refresh(SerializablePredicate<T> filter); @Override void setAdditionalFilter(SerializablePredicate<T> additionalFilter); @Override void setInvalid(boolean invalid); @Override void setPlaceholder(String placeholder); @Override void setValue(T newFieldValue);  }
@Test public void testRefresh() { EntityModel<TestEntity> em = factory.getModel(TestEntity.class); AttributeModel am = em.getAttributeModel("testDomain"); QuickAddEntityComboBox<Integer, TestEntity> select = new QuickAddEntityComboBox<>(em, am, service, SelectMode.FILTERED, null, false, null, null); select.initContent(); assertEquals(3, select.getComboBox().getDataProviderSize()); select.refresh(new EqualsPredicate<TestEntity>("name", "Kevin")); assertEquals(1, select.getComboBox().getDataProviderSize()); select.refresh(); assertEquals(1, select.getComboBox().getDataProviderSize()); }