Example usage for com.vaadin.v7.ui ComboBox getItem

List of usage examples for com.vaadin.v7.ui ComboBox getItem

Introduction

In this page you can find the example usage for com.vaadin.v7.ui ComboBox getItem.

Prototype

@Override
public Item getItem(Object itemId) 

Source Link

Document

Gets the item from the container with given id.

Usage

From source file:de.symeda.sormas.ui.utils.AbstractEditForm.java

License:Open Source License

protected void addNonPrimaryDiseasesTo(ComboBox diseaseField) {
    List<Disease> diseases = FacadeProvider.getDiseaseConfigurationFacade().getAllActiveDiseases();
    for (Disease disease : diseases) {
        if (diseaseField.getItem(disease) != null) {
            continue;
        }//from  ww w. j av a 2 s  .c om

        Item newItem = diseaseField.addItem(disease);
        newItem.getItemProperty(SormasFieldGroupFieldFactory.CAPTION_PROPERTY_ID).setValue(disease.toString());
    }
}