Package javax.faces.context

Examples of javax.faces.context.ResponseWriter.endDocument()


        // Call encodeAll() on the UIViewRoot
        viewToRender.encodeAll(facesContext);

        // Call endDocument() on the ResponseWriter
        responseWriter.endDocument();

        responseWriter.flush();
    }

    /**Create a new response-writer using as an underlying writer the stateAwareWriter
View Full Code Here


                    // render the view to the response
                    writer.startDocument();

                    view.encodeAll(context);

                    writer.endDocument();

                    // finish writing
                    // -= Leonardo Uribe =- This does not has sense too, because that's the reason
                    // of the try/finally block. In practice, it only forces the close of the tag
                    // in HtmlResponseWriter if necessary, but according to the spec, this should
View Full Code Here

    newWriter.startDocument();

    doRenderView(context, viewToRender);

    newWriter.endDocument();

    // replace markers in the body content and write it to response.

    ResponseWriter responseWriter;
View Full Code Here

      writer.startDocument();
      encodeAjaxBegin(context);
      context.getViewRoot().encodeAll(context);
      saveViewState(context);
      encodeAjaxEnd(context);
      writer.endDocument();
      writer.flush();
      writer.close();
      servletWriter.close();
      // Save tree state.
    } catch (IOException e) {
View Full Code Here

            } catch (UnsupportedOperationException uoe) {
                if (LOGGER.isLoggable(Level.FINE)) {
                    LOGGER.fine("ExternalContext.getFlash() throw UnsupportedOperationException -> Flash unavailable");
                }
            }
            newWriter.endDocument();
        }


        // replace markers in the body content and write it to response.
View Full Code Here

                } catch (UnsupportedOperationException uoe) {
                    if (LOGGER.isLoggable(Level.FINE)) {
                        LOGGER.fine("ExternalContext.getFlash() throw UnsupportedOperationException -> Flash unavailable");
                    }
                }
                writer.endDocument();
            }
            // finish writing
            writer.close();

View Full Code Here

      }
      context.setResponseWriter(newWriter);

      newWriter.startDocument();
      viewToRender.encodeAll(context);
      newWriter.endDocument();

      // replace markers in the body content and write it to response.

      strWriter.flushToWriter();
View Full Code Here

        // Call encodeAll() on the UIViewRoot
        viewToRender.encodeAll(facesContext);

        // Call endDocument() on the ResponseWriter
        responseWriter.endDocument();

        responseWriter.flush();
    }

    /**Create a new response-writer using as an underlying writer the stateAwareWriter
View Full Code Here

      newWriter.startDocument();

      doRenderView(context, viewToRender);

      newWriter.endDocument();

      // replace markers in the body content and write it to response.

      strWriter.flushToWriter();
View Full Code Here

    writer.startElement("span", input);
   
    NSUtils.writeNameSpace(facesContext, input);
   
    writer.endElement("span");
    writer.endDocument();

    String result = stringWriter.getBuffer().toString();
    assertTrue(result.contains("span xmlns:rich=\"http://richfaces.ajax4jsf.org/rich\""));
  }
}
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.