Package org.exoplatform.webui.exception

Examples of org.exoplatform.webui.exception.MessageException


        } catch (Exception e) {
            String message = e.getLocalizedMessage();
            log.error("Error processing the action: " + message, e);
            Object[] args = { message };
            context.addUIComponentToUpdateByAjax(uicomponent);
            throw new MessageException(new ApplicationMessage("UIPortletLifecycle.msg.process-error", args,
                    ApplicationMessage.ERROR));
        }

    }
View Full Code Here


                Util.getPortalRequestContext().setResponseComplete(true);
            } catch (Exception e) {
                UIPortletApplication uiPortlet = uiGadget.getAncestorOfType(UIPortletApplication.class);
                context.addUIComponentToUpdateByAjax(uiPortlet);
                context.setAttribute(UIGadget.SAVE_PREF_FAIL, true);
                throw new MessageException(new ApplicationMessage("UIDashboard.msg.ApplicationNotExisted", null,
                        ApplicationMessage.ERROR));
            }

            //
            if (uiGadget.isLossData()) {
View Full Code Here

      }
      label = label.trim();
      if (label.charAt(label.length() - 1) == ':')
         label = label.substring(0, label.length() - 1);
      Object[] args = {label, uiInput.getBindingField()};
      throw new MessageException(new ApplicationMessage("EmptyFieldValidator.msg.empty-input", args));
   }
View Full Code Here

         if (Character.isLetter(c) || Character.isDigit(c) || c == '_' || c == '-' || Character.isSpaceChar(c))
         {
            continue;
         }
         Object[] args = {label, uiInput.getBindingField()};
         throw new MessageException(new ApplicationMessage("SpecialCharacterValidator.msg.Invalid-char", args,
            ApplicationMessage.WARNING));
      }
   }
View Full Code Here

      if (label.charAt(label.length() - 1) == ':')
      {
         label = label.substring(0, label.length() - 1);
      }
      Object[] args = {label,};
      throw new MessageException(new ApplicationMessage(key_, args, ApplicationMessage.WARNING));
   }
View Full Code Here

            error = true;
            continue;
         }
         error = false;
         Object[] args = {label, uiInput.getBindingField()};
         throw new MessageException(new ApplicationMessage("NumberFormatValidator.msg.Invalid-number", args));
      }
      if (error == true && s.charAt(0) == '-')
      {
         Object[] args = {label, uiInput.getBindingField()};
         throw new MessageException(new ApplicationMessage("PositiveNumberFormatValidator.msg.Invalid-number", args));
      }
   }
View Full Code Here

        public void validate(UIFormInput uiInput) throws Exception {
            try {
                new GadgetSpec(Uri.parse("http://exoplatform.org"), (String) uiInput.getValue());
            } catch (Exception se) {
                throw new MessageException(new ApplicationMessage("UIGadgetEditor.msg.invalidSpec", null,
                        ApplicationMessage.WARNING));
            }
        }
View Full Code Here

      label = label.trim();
      if (label.charAt(label.length() - 1) == ':')
         label = label.substring(0, label.length() - 1);
      Object[] args =
      {label, uiInput.getBindingField()};
      throw new MessageException(new ApplicationMessage("CaptchaValidator.msg.Invalid-input", args,
            ApplicationMessage.WARNING));
   }
View Full Code Here

         UIFormInputContainer uiInputContainer = (UIFormInputContainer)uiInput;
         String value = (String)uiInputContainer.getValue();
         if (value == null || value.trim().length() < 1)
         {
            String[] args = {"UITabPane.title.UIPermissionSelector"};
            throw new MessageException(new ApplicationMessage("MandatoryValidatorIterator.msg.empty", args,
               ApplicationMessage.INFO));
         }
      }
View Full Code Here

            uiGadget.addUserPref(event.getRequestContext().getRequestParameter("userPref"));
         } catch(Exception e){
            WebuiRequestContext context = WebuiRequestContext.getCurrentInstance();
            UIPortletApplication uiPortlet = uiGadget.getAncestorOfType(UIPortletApplication.class);
            context.addUIComponentToUpdateByAjax(uiPortlet);
            throw new MessageException(new ApplicationMessage("UIDashboard.msg.ApplicationNotExisted", null, ApplicationMessage.ERROR));
         }

         //
         if (uiGadget.isLossData())
         {
View Full Code Here

TOP

Related Classes of org.exoplatform.webui.exception.MessageException

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.