com.ibm.xsp.page.compiled
Class AbstractCompiledPage

java.lang.Object
  extended by com.ibm.xsp.page.compiled.AbstractCompiledPage
All Implemented Interfaces:
com.ibm.xsp.page.compiled.CompiledPage, com.ibm.xsp.page.compiled.CompiledViewPage, FacesPage

public abstract class AbstractCompiledPage
extends java.lang.Object
implements com.ibm.xsp.page.compiled.CompiledViewPage

The superclass of one of the classes in the generated XPage .java file, not intended to be manually subclassed or used programmatically by application developers or third party Java developers. See FacesPage for details.


Nested Class Summary
static class AbstractCompiledPage.ComponentInfo
          Used in one of the classes in the generated XPage .java file, not intended to be used programmatically by application developers or third party Java developers.
 
Field Summary
static int[] EMPTY_INT_ARRAY
           
static java.lang.Object[][] EMPTY_OBJECT_ARRAY_ARRAY
           
 
Constructor Summary
AbstractCompiledPage(int rootIndex, AbstractCompiledPage.ComponentInfo[] infos)
           
 
Method Summary
 void addComponent(javax.faces.context.FacesContext context, FacesComponentBuilder builder, javax.faces.component.UIComponent parent, java.lang.String initialTag)
          Creates this page's view root and adds it, or one of it's descendant components, as a child of the specified parent.
 javax.faces.component.UIComponent buildComponent(int refId, javax.faces.context.FacesContext context, javax.faces.component.UIComponent parent, PageExpressionEvaluator evaluator)
           
 javax.faces.component.UIViewRoot createViewRoot(javax.faces.context.FacesContext context)
          Create the view for the specified page
protected  java.util.Map<java.lang.String,java.lang.Object> getAttributes(javax.faces.component.UIComponent comp)
           
 int[] getChildrenForId(int id)
           
 int getComponentForId(java.lang.String id)
          A default implementation, which throws a NoSuchComponentException, assuming that no component in the page has an id.
protected  PageErrorHandler getErrorHandler()
           
 int getFacetForId(int id, java.lang.String key)
          Returns -1 if no facet for the given id.
 java.lang.String[] getFacetsForId(int id)
           
protected  PageParam getPageParam()
           
 void init(PageParam param)
           
protected  void initBindingProperty(javax.faces.context.FacesContext context, javax.faces.el.ValueBinding binding, javax.faces.component.UIComponent component)
          Available to be called from the subclasses when the control "binding" property is set.
 void initComponent(javax.faces.context.FacesContext context, FacesComponentBuilder parent, javax.faces.component.UIComponent component, int elementId, PageExpressionEvaluator evaluator, boolean isInclude)
           
protected  void initIncluderAsRoot(javax.faces.context.FacesContext context, PageExpressionEvaluator evaluator, javax.faces.component.UIComponent root)
          Initializes the component including this page with the properties that would have been set on the UIViewRoot (note when a page is included in another, its UIViewRoot is never created).
protected  void initViewRoot(javax.faces.component.UIViewRoot root)
          Available to be called from the subclasses
 boolean isCurrentKitIn(java.lang.String[] renderKitGroup)
          True if the current renderKitId is one of the given arguments
 boolean isNonMarkup(int id)
           
protected  void setId(javax.faces.component.UIComponent component, java.lang.String id)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.ibm.xsp.page.compiled.CompiledViewPage
createComponent
 

Field Detail

EMPTY_INT_ARRAY

public static final int[] EMPTY_INT_ARRAY

EMPTY_OBJECT_ARRAY_ARRAY

public static final java.lang.Object[][] EMPTY_OBJECT_ARRAY_ARRAY
Constructor Detail

AbstractCompiledPage

public AbstractCompiledPage(int rootIndex,
                            AbstractCompiledPage.ComponentInfo[] infos)
Method Detail

init

public void init(PageParam param)

createViewRoot

public javax.faces.component.UIViewRoot createViewRoot(javax.faces.context.FacesContext context)
                                                throws FacesPageException
Description copied from interface: FacesPage
Create the view for the specified page

Specified by:
createViewRoot in interface FacesPage
Returns:
Throws:
FacesPageException

buildComponent

public javax.faces.component.UIComponent buildComponent(int refId,
                                                        javax.faces.context.FacesContext context,
                                                        javax.faces.component.UIComponent parent,
                                                        PageExpressionEvaluator evaluator)
                                                 throws NoSuchComponentException
Specified by:
buildComponent in interface com.ibm.xsp.page.compiled.CompiledViewPage
Throws:
NoSuchComponentException

initIncluderAsRoot

protected void initIncluderAsRoot(javax.faces.context.FacesContext context,
                                  PageExpressionEvaluator evaluator,
                                  javax.faces.component.UIComponent root)
Initializes the component including this page with the properties that would have been set on the UIViewRoot (note when a page is included in another, its UIViewRoot is never created). The root will be a FacesDataComponent. Default implementation is empty. Available to override in subclass.

Parameters:
context -
evaluator -
root - will be a FacesDataComponent

getComponentForId

public int getComponentForId(java.lang.String id)
                      throws NoSuchComponentException
A default implementation, which throws a NoSuchComponentException, assuming that no component in the page has an id.

Specified by:
getComponentForId in interface com.ibm.xsp.page.compiled.CompiledViewPage
Throws:
NoSuchComponentException

initComponent

public void initComponent(javax.faces.context.FacesContext context,
                          FacesComponentBuilder parent,
                          javax.faces.component.UIComponent component,
                          int elementId,
                          PageExpressionEvaluator evaluator,
                          boolean isInclude)
                   throws FacesPageException
Specified by:
initComponent in interface com.ibm.xsp.page.compiled.CompiledViewPage
Parameters:
component - if isInclude, it'll be the XFInclude or XFIncludeComposite called from the called page, else it'll be the component that was just created.
elementId, - if isInclude, this will be the id of the root element in the page (which the XFInclude or XFIncludeComposite will represent)
Throws:
FacesPageException

addComponent

public void addComponent(javax.faces.context.FacesContext context,
                         FacesComponentBuilder builder,
                         javax.faces.component.UIComponent parent,
                         java.lang.String initialTag)
                  throws FacesPageException
Description copied from interface: FacesPage
Creates this page's view root and adds it, or one of it's descendant components, as a child of the specified parent.

The optional initial tag refers to a tag in the included page (this page). It is the id of the component that will be inserted into the calling page as a child of the parent. It is used when including a portion of one page in another

The parent is a component in a caller page. It is usually an UIIncludeComposite or an UIInclude.

Specified by:
addComponent in interface FacesPage
Throws:
FacesPageException

initViewRoot

protected void initViewRoot(javax.faces.component.UIViewRoot root)
Available to be called from the subclasses

Parameters:
root -

initBindingProperty

protected void initBindingProperty(javax.faces.context.FacesContext context,
                                   javax.faces.el.ValueBinding binding,
                                   javax.faces.component.UIComponent component)
Available to be called from the subclasses when the control "binding" property is set. This was added in 8.5.2, when the property was changed to allow run-time bindings for SPR#MKEE7TYLGF. Non-readonly runtime bindings are passed to this method.

Parameters:
context -
binding -
component -

isNonMarkup

public boolean isNonMarkup(int id)
                    throws NoSuchComponentException
Specified by:
isNonMarkup in interface com.ibm.xsp.page.compiled.CompiledViewPage
Throws:
NoSuchComponentException

getChildrenForId

public int[] getChildrenForId(int id)
                       throws NoSuchComponentException
Specified by:
getChildrenForId in interface com.ibm.xsp.page.compiled.CompiledViewPage
Throws:
NoSuchComponentException

getFacetsForId

public java.lang.String[] getFacetsForId(int id)
                                  throws NoSuchComponentException
Specified by:
getFacetsForId in interface com.ibm.xsp.page.compiled.CompiledViewPage
Throws:
NoSuchComponentException
See Also:
com.ibm.xsp.page.compiled.ICompiledPage#getFacetForId(java.lang.String, java.lang.String)

getFacetForId

public int getFacetForId(int id,
                         java.lang.String key)
                  throws NoSuchComponentException
Returns -1 if no facet for the given id.

Specified by:
getFacetForId in interface com.ibm.xsp.page.compiled.CompiledViewPage
Throws:
NoSuchComponentException
See Also:
com.ibm.xsp.page.compiled.ICompiledPage#getFacetForId(java.lang.String, java.lang.String)

isCurrentKitIn

public boolean isCurrentKitIn(java.lang.String[] renderKitGroup)
True if the current renderKitId is one of the given arguments

Parameters:
renderKitGroup -
Returns:

getPageParam

protected PageParam getPageParam()

getAttributes

protected java.util.Map<java.lang.String,java.lang.Object> getAttributes(javax.faces.component.UIComponent comp)

setId

protected void setId(javax.faces.component.UIComponent component,
                     java.lang.String id)

getErrorHandler

protected PageErrorHandler getErrorHandler()