class DataSetDefEditorPresenter extends BaseEditor {

    @Override
    protected Command onValidate() {
        return () -> {
            workflow.flush();
            if (!workflow.hasErrors()) {
                notification.fire(new NotificationEvent(DataSetAuthoringConstants.INSTANCE.validationOk(),
                                                        SUCCESS));
            } else {
                notification.fire(new NotificationEvent(DataSetAuthoringConstants.INSTANCE.validationFailed(),
                                                        ERROR));
            }
        };
    }

}