Package javax.faces.component

Examples of javax.faces.component.UIComponent.encodeAll()


            try {
                ByteArrayOutputStream outputStream = new ByteArrayOutputStream();
                PrintWriter printWriter = new PrintWriter(outputStream);
                ResponseWriter newResponseWriter = facesContext.getRenderKit().createResponseWriter(printWriter, null, null);
                facesContext.setResponseWriter(newResponseWriter);
                facet.encodeAll(facesContext);
                printWriter.flush();
                String value = new String(outputStream.toByteArray());
                options.put(name, value);
            } catch (IOException e) {
                throw new FacesException("Can't encode facet '" + name + "' of component '" + component.getClass().getName()
View Full Code Here


        String cellStyleClass = (String) dataTableBase.getAttributes().get("noDataCellStyleClass");
        cellStyleClass = concatClasses(getNoDataCellClass(), cellStyleClass);
        writer.writeAttribute(HtmlConstants.CLASS_ATTRIBUTE, cellStyleClass, null);

        if (noDataFacet != null && noDataFacet.isRendered()) {
            noDataFacet.encodeAll(facesContext);
        } else if (noDataLabel != null && noDataLabel.length() > 0) {
            writer.writeText(noDataLabel, "noDataLabel");
        } else {
            writer.writeAttribute(HtmlConstants.STYLE_ATTRIBUTE, "display: none;", null);
        }
View Full Code Here

        renderFacet(context, component, CONTROLS_FACET);
    }

    private void renderFacet(FacesContext context, UIComponent component, String facet) throws IOException {
        UIComponent headerFacet = component.getFacet(facet);
        headerFacet.encodeAll(context);
    }

    @SuppressWarnings("unchecked")
    protected void doDecode(FacesContext context, UIComponent component) {
        super.doDecode(context, component);
View Full Code Here

            if (strategy != null) {
                strategy.begin(writer, context, column, new String[] { facetName });

                UIComponent facet = column.getFacet(facetName);
                if (facet != null && facet.isRendered()) {
                    facet.encodeAll(context);
                }
                strategy.end(writer, context, column, new String[] { facetName });
            }
            if (useBuiltInSort) {
                this.renderSortButton(context, column, "rf-dt");
View Full Code Here

                    if (component.isRendered()) {
                        rowEnded = true;
                        encodeRowEnd(writer);
                    }

                    component.encodeAll(facesContext);
                    rowHolder.setRowStart(true);
                }
            }
        }
View Full Code Here

        //Resources
        UIViewRoot viewRoot = context.getViewRoot();
        ListIterator<UIComponent> iter = (viewRoot.getComponentResources(context, "head")).listIterator();
        while (iter.hasNext()) {
            UIComponent resource = (UIComponent)iter.next();
            resource.encodeAll(context);
        }
    }

    @Override
    public void encodeChildren(FacesContext context, UIComponent component) throws IOException {
View Full Code Here

    renderCSSDependency(facesContext, themeRelativePath + "/theme.min.css");
   
    ListIterator<UIComponent> iter = (facesContext.getViewRoot().getComponentResources(facesContext, "head")).listIterator();
    while(iter.hasNext()) {
      UIComponent resource = (UIComponent)iter.next();
      resource.encodeAll(facesContext);
    }
 
    writer.startElement("script", null);
    writer.writeAttribute("type", "text/javascript", null);
   
View Full Code Here

        UIComponent header = column.getFacet("header");
        if(header != null) {
          if(ComponentUtils.isLiteralText(header))
            writer.write(header.toString());
          else
            header.encodeAll(facesContext);
        }
       
        writer.endElement("span");
        writer.endElement("div");
        writer.endElement("th");
View Full Code Here

        renderChildren(facesContext, list);     
        writer.endElement(listItemTag);
       
        if(isDefinition) {
          writer.startElement("dd", null);
          definition.encodeAll(facesContext);
          writer.endElement("dd");
        }
      }
    }
   
View Full Code Here

                if (child.getId().equals(stepToDisplay)) {
                    tabToDisplay = child;
                }
            }

            tabToDisplay.encodeAll(fc);

            RequestContext.getCurrentInstance().addCallbackParam("currentStep", wizard.getStep());
           
        } else {
            encodeMarkup(fc, wizard);
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.