Search in sources :

Example 11 with RemoteCallback

use of org.jboss.errai.common.client.api.RemoteCallback in project drools-wb by kiegroup.

the class DecisionTableXLSEditorPresenter method convert.

private void convert() {
    busyIndicatorView.showBusyIndicator(DecisionTableXLSEditorConstants.INSTANCE.Converting());
    decisionTableXLSService.call(new RemoteCallback<ConversionResult>() {

        @Override
        public void callback(final ConversionResult response) {
            busyIndicatorView.hideBusyIndicator();
            if (response.getMessages().size() > 0) {
                final PopupListWidget popup = new PopupListWidget();
                for (ConversionMessage message : response.getMessages()) {
                    popup.addListItem(new ConversionMessageWidget(message));
                }
                popup.show();
            }
        }
    }).convert(versionRecordManager.getCurrentPath());
}
Also used : ConversionMessage(org.drools.workbench.models.guided.dtable.shared.conversion.ConversionMessage) ConversionResult(org.drools.workbench.models.guided.dtable.shared.conversion.ConversionResult) ConversionMessageWidget(org.drools.workbench.screens.dtablexls.client.widgets.ConversionMessageWidget) PopupListWidget(org.drools.workbench.screens.dtablexls.client.widgets.PopupListWidget) RemoteCallback(org.jboss.errai.common.client.api.RemoteCallback)

Aggregations

RemoteCallback (org.jboss.errai.common.client.api.RemoteCallback)11 PackageDataModelOracleBaselinePayload (org.kie.workbench.common.services.datamodel.model.PackageDataModelOracleBaselinePayload)5 GuidedDecisionTable52 (org.drools.workbench.models.guided.dtable.shared.model.GuidedDecisionTable52)4 ObservablePath (org.uberfire.backend.vfs.ObservablePath)4 List (java.util.List)2 GuidedDecisionTableView (org.drools.workbench.screens.guided.dtable.client.widget.table.GuidedDecisionTableView)2 ValidationMessage (org.guvnor.common.services.shared.validation.model.ValidationMessage)2 HasBusyIndicatorDefaultErrorCallback (org.uberfire.ext.widgets.common.client.callbacks.HasBusyIndicatorDefaultErrorCallback)2 NotificationEvent (org.uberfire.workbench.events.NotificationEvent)2 IsWidget (com.google.gwt.user.client.ui.IsWidget)1 ProvidesResize (com.google.gwt.user.client.ui.ProvidesResize)1 RequiresResize (com.google.gwt.user.client.ui.RequiresResize)1 ArrayList (java.util.ArrayList)1 Collection (java.util.Collection)1 Optional (java.util.Optional)1 Set (java.util.Set)1 Event (javax.enterprise.event.Event)1 ConversionMessage (org.drools.workbench.models.guided.dtable.shared.conversion.ConversionMessage)1 ConversionResult (org.drools.workbench.models.guided.dtable.shared.conversion.ConversionResult)1 ConversionMessageWidget (org.drools.workbench.screens.dtablexls.client.widgets.ConversionMessageWidget)1