use of org.drools.workbench.screens.guided.dtree.client.widget.popups.ParserMessagesPopup in project drools-wb by kiegroup.
the class GuidedDecisionTreeEditorPresenter method getModelSuccessCallback.
private RemoteCallback<GuidedDecisionTreeEditorContent> getModelSuccessCallback() {
return new RemoteCallback<GuidedDecisionTreeEditorContent>() {
@Override
public void callback(final GuidedDecisionTreeEditorContent content) {
// Path is set to null when the Editor is closed (which can happen before async calls complete).
if (versionRecordManager.getCurrentPath() == null) {
return;
}
GuidedDecisionTreeEditorPresenter.this.content = content;
model = content.getModel();
metadata = content.getOverview().getMetadata();
final PackageDataModelOracleBaselinePayload dataModel = content.getDataModel();
oracle = oracleFactory.makeAsyncPackageDataModelOracle(versionRecordManager.getCurrentPath(), model, dataModel);
resetEditorPages(content.getOverview());
addSourcePage();
addImportsTab(importsWidget);
importsWidget.setContent(oracle, model.getImports(), isReadOnly);
view.setModel(model, isReadOnly);
view.setDataModel(oracle, isReadOnly);
view.hideBusyIndicator();
// If there were any parsing errors give the User the option to remove the broken DRL or ignore it
if (!model.getParserErrors().isEmpty()) {
final ParserMessagesPopup popup = new ParserMessagesPopup(model);
popup.show();
}
createOriginalHash(model);
}
};
}
Aggregations