Package javax.faces.application.FacesMessage

Examples of javax.faces.application.FacesMessage.Severity


      
    String labelStyle = null;
      
    String passLabel = null;
      
    Severity severity = null;
      
          
    if(facesMsg != null){
      
      severity = facesMsg.getSeverity();
View Full Code Here


   
    String outerClass = null;
      
    String outerStyle = null;
      
    Severity severity = null;
      
      
    if(facesMsg != null){
        
      severity = facesMsg.getSeverity();
View Full Code Here

   
    if(acceptLevels.contains(ALL_NAME) || message == null){
      return true;
    }
   
    Severity severity = message.getSeverity();
   
    if(severity == FacesMessage.SEVERITY_ERROR
        && acceptLevels.contains(ERROR_NAME)){
      accept = true;
     
View Full Code Here

                 : componentMessageLists.keySet().iterator());        
     }

     public Severity getMaximumSeverity() {
         assertNotReleased();
         Severity result = null;
         if (componentMessageLists != null && !(componentMessageLists.isEmpty())) {
             for (Iterator<FacesMessage> i =
                   new ComponentMessagesIterator(componentMessageLists);
                  i.hasNext();) {
                 Severity severity = i.next().getSeverity();
                 if (result == null || severity.compareTo(result) > 0) {
                     result = severity;                
                 }
                 if (result == FacesMessage.SEVERITY_FATAL) {
                     break;
                 }
View Full Code Here

     * @see javax.faces.context.FacesContext#getMaximumSeverity()
     */
    @Override
    public Severity getMaximumSeverity() {
        assertNotReleased();
        Severity result = null;
        if (componentMessageLists != null
            && !(componentMessageLists.isEmpty())) {
            for (Iterator<FacesMessage> i =
                  new ComponentMessagesIterator(componentMessageLists);
                 i.hasNext();) {
                Severity severity = i.next().getSeverity();
                if (result == null || severity.compareTo(result) > 0) {
                    result = severity;
                }
                if (result == FacesMessage.SEVERITY_FATAL) {
                    break;
                }
View Full Code Here

        Util.notNull("message", message);

        if (maxSeverity == null) {
            maxSeverity = message.getSeverity();
        } else {
            Severity sev = message.getSeverity();
            if (sev.getOrdinal() > maxSeverity.getOrdinal()) {
                maxSeverity = sev;
            }
        }

        if (componentMessageLists == null) {
View Full Code Here

        return Lists.newArrayList(filteredMessages);
    }

    private Predicate<MessageForRender> getMessagesLevelFilter(FacesContext context, UIComponent component) {

        final Severity level = getLevel(component);
        final boolean displayAll = isComponentMessages(component);
        final boolean redisplay = Boolean.TRUE.equals(component.getAttributes().get("redisplay"));
        Predicate<MessageForRender> predicate = new Predicate<MessageForRender>() {
            private int count = 0;
View Full Code Here

        return predicate;
    }

    protected Severity getLevel(UIComponent component) {
        Object levelName = component.getAttributes().get("level");
        final Severity level = (Severity) (FacesMessage.VALUES_MAP.containsKey(levelName) ? FacesMessage.VALUES_MAP
                .get(levelName) : FacesMessage.SEVERITY_INFO);
        return level;
    }
View Full Code Here

            UIComponent target = rendererUtils.findComponentFor(component, forId);
            if (null != target) {
                parametersBuilder.put("forComponentId", target.getClientId(facesContext));
            }
        }
        Severity level = getLevel(component);
        if (FacesMessage.SEVERITY_INFO != level) {
            parametersBuilder.put("level", level.getOrdinal());
        }
        if (!rendererUtils.isBooleanAttribute(component, "showSummary")) {
            parametersBuilder.put("showSummary", false);
        }
        if (rendererUtils.isBooleanAttribute(component, "showDetail")) {
View Full Code Here

            UIComponent target = rendererUtils.findComponentFor(component, forId);
            if (null != target) {
                parametersBuilder.put("forComponentId", target.getClientId(facesContext));
            }
        }
        Severity level = getLevel(component);
        if (FacesMessage.SEVERITY_INFO != level) {
            parametersBuilder.put("level", level.getOrdinal());
        }
        if (!rendererUtils.isBooleanAttribute(component, "showSummary")) {
            parametersBuilder.put("showSummary", false);
        }
        if (rendererUtils.isBooleanAttribute(component, "showDetail")) {
View Full Code Here

TOP

Related Classes of javax.faces.application.FacesMessage.Severity

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.