在Vaadin 8中,给定以下网格定义:
grid = new Grid<>();
grid.getEditor().setEnabled(true);
carBinder = grid.getEditor().getBinder();
grid.getEditor().addSaveListener(event -> {
try {
Binder<Car> binder = event.getSource().getBinder();
grid.getDataProvider().refreshAll();
} catch(Exception e)
ExceptionNotification.show(e);
}
});