org.apache.myfaces.trinidad.render

## Class InternalView

- java.lang.Object
- - org.apache.myfaces.trinidad.render.InternalView

-     public abstract class InternalView
      extends Object

  An InternalView is a view ID that is handled internally to the webapp, without (necessarily) dispatching to an external resource. This can also be used to register pseudo-URLs that

  InternalViews should be registered with a .properties-syntax file at `/META-INF/org.apache.myfaces.trinidad.render.InternalView.properties`

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `InternalView()`

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `abstract javax.faces.component.UIViewRoot` | `createView(javax.faces.context.FacesContext context, String viewId)` Creates the UIViewRoot.
    `boolean` | `isStateless(javax.faces.context.FacesContext context, String viewId)` Return true if this view is stateless; which, by default, it is.
    `abstract void` | `renderView(javax.faces.context.FacesContext context, javax.faces.component.UIViewRoot viewToRender)` Renders the view.
    `abstract javax.faces.component.UIViewRoot` | `restoreView(javax.faces.context.FacesContext context, String viewId)` Restores the UIViewRoot; return null if no view should be returned.

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### InternalView

          public InternalView()

  - ### Method Detail

    - #### createView

          public abstract javax.faces.component.UIViewRoot createView(javax.faces.context.FacesContext context,
                                                    String viewId)

      Creates the UIViewRoot.

      Unlike ViewHandler.createView(), null is an acceptable return value - it indicates that a default, empty UIViewRoot for this viewId should be created on behalf of the InternalView, which might populate the view during renderView().

    - #### restoreView

          public abstract javax.faces.component.UIViewRoot restoreView(javax.faces.context.FacesContext context,
                                                     String viewId)

      Restores the UIViewRoot; return null if no view should be returned.

    - #### renderView

          public abstract void renderView(javax.faces.context.FacesContext context,
                        javax.faces.component.UIViewRoot viewToRender)
                                   throws IOException,
                                          javax.faces.FacesException

      Renders the view.
      Throws:
        `IOException`
        `javax.faces.FacesException`

    - #### isStateless

          public boolean isStateless(javax.faces.context.FacesContext context,
                            String viewId)

      Return true if this view is stateless; which, by default, it is. Stateless views will have no state saved during Render Response. restoreView() will still be called, so a stateless view can still process postback by returning a populated component tree from restoreView().

Copyright © 2001-2016 The Apache Software Foundation. All Rights Reserved.