use of com.centurylink.mdw.plugin.designer.dialogs.MdwMessageDialog in project mdw-designer by CenturyLinkCloud.
the class PluginMessages method uiMessage.
public static void uiMessage(Shell shell, String message, String title, WorkflowProject project, int level) {
log(message);
boolean sendMessage = level >= getReportingLevel();
if (shell != null) {
MdwMessageDialog messageDialog = new MdwMessageDialog(shell, title, message, level);
messageDialog.open();
sendMessage = messageDialog.isReportMessage();
}
if (sendMessage)
PluginUtil.sendError(null, title, message, project, level);
}
use of com.centurylink.mdw.plugin.designer.dialogs.MdwMessageDialog in project mdw-designer by CenturyLinkCloud.
the class PluginMessages method uiMessage.
public static void uiMessage(Shell shell, Throwable t, String message, String title, WorkflowProject project, int level) {
log(t);
if (t instanceof ValidationException || t.getCause() instanceof ValidationException) {
ValidationException valEx = t instanceof ValidationException ? (ValidationException) t : (ValidationException) t.getCause();
StringBuilder messageBuf = new StringBuilder();
valEx.fillInErrors(messageBuf, 3);
message = messageBuf.toString();
title = "Validation Error: " + title;
level = VALIDATION_MESSAGE;
}
if (message == null)
message = PluginMessages.getUserMessage(t);
boolean sendMessage = level >= getReportingLevel();
if (shell != null) {
MdwMessageDialog messageDialog = new MdwMessageDialog(shell, title, message, level);
messageDialog.open();
sendMessage = messageDialog.isReportMessage();
}
if (sendMessage)
PluginUtil.sendError(t, title, message, project, level);
}
Aggregations