First, you can specify the type of combo box as follows when you create it.
private ComboBox<TestExecution> comboExecution = new ComboBox<>("Select Execution");
, , ItemCaptionGenerator.
comboExecution.setItemCaptionGenerator(new ItemCaptionGenerator<TestExecution>() {
@Override
public String apply(TestExecution execution) {
return execution.getName();
}
});
, lamda .
comboExecution.setItemCaptionGenerator(execution -> execution.getName());