|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectjavax.faces.component.UIComponent
javax.faces.component.UIComponentBase
javax.faces.component.UIData
com.ibm.xsp.component.UIDataEx
public class UIDataEx
Extends UIData to delegate to
ApplicationEx.createDataModel(Object) to
create the data model, and adds other functionalities needed by the Data
Table and View Panel controls.
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from class javax.faces.component.UIComponentBase |
|---|
javax.faces.component.UIComponentBase.AggregatedIterator, javax.faces.component.UIComponentBase.UnmodifiableIterator |
| Nested classes/interfaces inherited from class javax.faces.component.UIComponent |
|---|
javax.faces.component.UIComponent.StateMap, javax.faces.component.UIComponent.StateMapEntry |
| Field Summary | |
|---|---|
static java.lang.String |
AJAX_GETROWS
|
static java.lang.String |
COMPONENT_TYPE
|
static int |
DEFAULT_ROWS_PER_PAGE
This is a default value that will be applied if "rows" is not set or is less than 1 |
| Fields inherited from class javax.faces.component.UIData |
|---|
COMPONENT_FAMILY |
| Fields inherited from class javax.faces.component.UIComponentBase |
|---|
EMPTY_ITERATOR |
| Fields inherited from class javax.faces.component.UIComponent |
|---|
_xspStateId |
| Fields inherited from interface javax.faces.component.NamingContainer |
|---|
SEPARATOR_CHAR |
| Constructor Summary | |
|---|---|
UIDataEx()
|
|
| Method Summary | |
|---|---|
void |
_xspCleanTransientData()
|
void |
broadcast(javax.faces.event.FacesEvent event)
|
protected java.lang.String |
computeDataModelKey()
Computes Data model key based on parent DataIterators. |
protected javax.faces.model.DataModel |
createDataModel()
Available to be extended by subclasses. |
void |
encodeBegin(javax.faces.context.FacesContext context)
|
void |
encodeEnd(javax.faces.context.FacesContext context)
|
java.lang.String |
getAjaxUrl(javax.faces.context.FacesContext context,
java.lang.String verb)
Compose the URL for a Ajax request related to a component; generally the AJAX_GETROWS would be passed in as the verb. |
java.lang.String |
getAjaxUrl(java.lang.String verb)
Compose the URL for a Ajax request related to a component; generally the AJAX_GETROWS would be passed in as the verb. |
DataSource |
getData()
returns the DataSource for this control. |
javax.faces.model.DataModel |
getDataModel()
Create a data model from the value using the data model factory method on the application instance. |
DataSource |
getDataSource()
|
java.lang.String |
getIndexVar()
|
javax.faces.model.DataModel |
getLastCreatedDataModel()
Return the last created data model for this component. |
java.lang.String |
getNonChildClientId(javax.faces.context.FacesContext context)
|
java.lang.String |
getRefreshId()
|
int |
getRowCount()
|
int |
getRowCount(int maxCount)
|
int |
getRows()
|
java.lang.String |
getStyleKitFamily()
The styleKitFamily is basically the default themeId, to use if the "themeId" property is not set on this control instance in the XPage source. |
java.lang.Object |
getValue()
|
boolean |
gotoFirstPage()
Go to the first page in the data control. |
boolean |
gotoLastPage()
Go to the last page in the data control. |
boolean |
gotoNextPage()
Go to the next page in the data control. |
boolean |
gotoPage(int page)
Go to the specified page in the data control. |
boolean |
gotoPreviousPage()
Go to the previous page in the data control. |
boolean |
gotoRow(int row)
Go to the specified row in the data control. |
boolean |
handles(javax.faces.context.FacesContext context)
This FacesAjaxComponent implementation returns false as it
requires the context of the surrounding XPage, instead of directly
handling the response without data from data sources or other variables
in the XPage. |
boolean |
invokeOnComponent(javax.faces.context.FacesContext context,
java.lang.String clientId,
javax.faces.component.ContextCallback callback)
|
protected boolean |
isNestedInDataIterator()
|
boolean |
isPartialExecute()
|
boolean |
isPartialRefresh()
|
protected void |
processAjaxGetRows(javax.faces.context.FacesContext context)
|
void |
processAjaxRequest(javax.faces.context.FacesContext context)
This FacesAjaxComponent implementation handles non-partial-update
AJAX requests where the XPage name is like /page1.xsp/getrows, that is,
where the path info ( ExternalContext.getRequestPathInfo() begins
with AJAX_GETROWS. |
void |
processDecodes(javax.faces.context.FacesContext context)
|
void |
processUpdates(javax.faces.context.FacesContext context)
|
void |
processValidators(javax.faces.context.FacesContext context)
|
protected java.util.List<DataPublisher.ShadowedObject> |
publishControlData(javax.faces.context.FacesContext context)
This publishes 1)the data source object, 2) the current item being repeated through and 3) the index of the item, to be available as variables in the request scope, so they may be used by computed values within this repeating control. |
void |
queueEvent(javax.faces.event.FacesEvent event)
|
protected void |
resetDataModel()
resets data model |
protected java.lang.Object |
resolveValue()
|
void |
restoreState(javax.faces.context.FacesContext context,
java.lang.Object state)
|
protected void |
revokeControlData(java.util.List<DataPublisher.ShadowedObject> shadowed,
javax.faces.context.FacesContext context)
Revokes the values published in publishControlData(FacesContext),
removing them from the request scope. |
java.lang.Object |
saveState(javax.faces.context.FacesContext context)
|
void |
setData(DataSource data)
Sets the DataSource for this control. |
protected void |
setDataModel(javax.faces.model.DataModel dataModel)
|
void |
setIndexVar(java.lang.String indexVar)
The var set on this control can then be used by children to reference the data defined on the UIData Control. |
void |
setRowIndex(int index)
|
void |
setRows(int rows)
|
void |
setValue(java.lang.Object value)
|
void |
setValueBinding(java.lang.String name,
javax.faces.el.ValueBinding binding)
|
void |
setVar(java.lang.String var)
|
boolean |
visitTree(javax.faces.component.visit.VisitContext context,
javax.faces.component.visit.VisitCallback callback)
|
| Methods inherited from class javax.faces.component.UIData |
|---|
getClientId, getFamily, getFirst, getFooter, getHeader, getRowData, getRowIndex, getVar, isRowAvailable, setFirst, setFooter, setHeader |
| Methods inherited from class javax.faces.component.UIComponentBase |
|---|
_xspGetReadOnlyObj, _xspGetRendererData, _xspRemoveReadOnlyObj, _xspRemoveRendererData, _xspSetIdUnchecked, _xspSetReadOnlyObj, _xspSetRendererData, addFacesListener, decode, encodeChildren, findComponent, getAttributes, getChildCount, getChildren, getFacesContext, getFacesListeners, getFacet, getFacetCount, getFacets, getFacetsAndChildren, getId, getParent, getRenderer, getRendererType, getRendersChildren, getValueBinding, isRendered, isTransient, processRestoreState, processSaveState, removeFacesListener, restoreAttachedState, saveAttachedState, setId, setParent, setRendered, setRendererType, setTransient |
| Methods inherited from class javax.faces.component.UIComponent |
|---|
_xspGetStateId, _xspGetStateMap, _xspRestoreAttribute, _xspRestoreState, _xspSaveState, isVisitable, markInitialState, setControlState |
| 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.component.FacesDataIterator |
|---|
getFirst, getRowIndex, setFirst |
| Field Detail |
|---|
public static final int DEFAULT_ROWS_PER_PAGE
public static final java.lang.String COMPONENT_TYPE
public static final java.lang.String AJAX_GETROWS
processAjaxRequest(FacesContext),
Constant Field Values| Constructor Detail |
|---|
public UIDataEx()
| Method Detail |
|---|
public java.lang.String getStyleKitFamily()
ThemeControlThe implementation may return different values depending on the configuration of the current control, for example the Button control returns a different value and looks different when it is configured as a cancel button.
getStyleKitFamily in interface ThemeControlnull themeId corresponding to the
configuration for this type of control in a theme file.public void _xspCleanTransientData()
_xspCleanTransientData in class javax.faces.component.UIComponentBasepublic boolean isPartialRefresh()
public java.lang.String getRefreshId()
public boolean isPartialExecute()
public javax.faces.model.DataModel getDataModel()
getDataModel in interface FacesDataIteratorgetDataModel in class javax.faces.component.UIDataprotected void setDataModel(javax.faces.model.DataModel dataModel)
setDataModel in class javax.faces.component.UIDataprotected javax.faces.model.DataModel createDataModel()
protected java.lang.String computeDataModelKey()
protected void resetDataModel()
protected boolean isNestedInDataIterator()
public void setData(DataSource data)
DataSource for this control.
data - public DataSource getData()
DataSource for this control.
public DataSource getDataSource()
public void setIndexVar(java.lang.String indexVar)
indexVar - The index var to set.public java.lang.String getIndexVar()
public java.lang.Object getValue()
getValue in class javax.faces.component.UIDataprotected java.lang.Object resolveValue()
public javax.faces.model.DataModel getLastCreatedDataModel()
public void setRowIndex(int index)
setRowIndex in class javax.faces.component.UIData
public void encodeBegin(javax.faces.context.FacesContext context)
throws java.io.IOException
encodeBegin in class javax.faces.component.UIDatajava.io.IOException
public void encodeEnd(javax.faces.context.FacesContext context)
throws java.io.IOException
encodeEnd in class javax.faces.component.UIComponentBasejava.io.IOExceptionpublic int getRowCount()
getRowCount in class javax.faces.component.UIDatapublic int getRowCount(int maxCount)
public int getRows()
getRows in interface FacesDataIteratorgetRows in class javax.faces.component.UIDatapublic void setRows(int rows)
setRows in interface FacesDataIteratorsetRows in class javax.faces.component.UIDatapublic void processDecodes(javax.faces.context.FacesContext context)
processDecodes in class javax.faces.component.UIDatapublic void processUpdates(javax.faces.context.FacesContext context)
processUpdates in class javax.faces.component.UIDatapublic void processValidators(javax.faces.context.FacesContext context)
processValidators in class javax.faces.component.UIData
public boolean invokeOnComponent(javax.faces.context.FacesContext context,
java.lang.String clientId,
javax.faces.component.ContextCallback callback)
throws javax.faces.FacesException
invokeOnComponent in class javax.faces.component.UIDatajavax.faces.FacesException
public boolean visitTree(javax.faces.component.visit.VisitContext context,
javax.faces.component.visit.VisitCallback callback)
visitTree in class javax.faces.component.UIDatapublic void queueEvent(javax.faces.event.FacesEvent event)
queueEvent in class javax.faces.component.UIData
public void broadcast(javax.faces.event.FacesEvent event)
throws javax.faces.event.AbortProcessingException
broadcast in class javax.faces.component.UIDatajavax.faces.event.AbortProcessingException
public void restoreState(javax.faces.context.FacesContext context,
java.lang.Object state)
restoreState in interface javax.faces.component.StateHolderrestoreState in class javax.faces.component.UIDatapublic java.lang.Object saveState(javax.faces.context.FacesContext context)
saveState in interface javax.faces.component.StateHoldersaveState in class javax.faces.component.UIDatapublic void setValue(java.lang.Object value)
setValue in class javax.faces.component.UIData
public void setValueBinding(java.lang.String name,
javax.faces.el.ValueBinding binding)
setValueBinding in class javax.faces.component.UIDatapublic void setVar(java.lang.String var)
setVar in class javax.faces.component.UIDatapublic boolean gotoFirstPage()
public boolean gotoPreviousPage()
public boolean gotoNextPage()
public boolean gotoLastPage()
public boolean gotoRow(int row)
public boolean gotoPage(int page)
protected java.util.List<DataPublisher.ShadowedObject> publishControlData(javax.faces.context.FacesContext context)
UIData.getVar(),
and the current item index is published under the name from
getIndexVar(). Note, this control is not a
FacesDataProvider, publishing a list of data sources, as only a
single data source may be configured.
context -
for general discussion of publish and revoke.
protected void revokeControlData(java.util.List<DataPublisher.ShadowedObject> shadowed,
javax.faces.context.FacesContext context)
publishControlData(FacesContext),
removing them from the request scope.
shadowed - context - public java.lang.String getNonChildClientId(javax.faces.context.FacesContext context)
getNonChildClientId in interface FacesRefreshableComponentFacesRefreshableComponent.getNonChildClientId(javax.faces.context.FacesContext)public java.lang.String getAjaxUrl(java.lang.String verb)
AJAX_GETROWS would be passed in as the verb.
public java.lang.String getAjaxUrl(javax.faces.context.FacesContext context,
java.lang.String verb)
AJAX_GETROWS would be passed in as the verb.
public boolean handles(javax.faces.context.FacesContext context)
FacesAjaxComponent implementation returns false as it
requires the context of the surrounding XPage, instead of directly
handling the response without data from data sources or other variables
in the XPage.
handles in interface FacesAjaxComponentFacesAjaxComponent.handles(FacesContext)
public void processAjaxRequest(javax.faces.context.FacesContext context)
throws java.io.IOException
FacesAjaxComponent implementation handles non-partial-update
AJAX requests where the XPage name is like /page1.xsp/getrows, that is,
where the path info ( ExternalContext.getRequestPathInfo() begins
with AJAX_GETROWS. For such a request, the rows portion of the
control's HTML output is returned to the browser, without the TABLE tag
or similar headers normally output by this control.
processAjaxRequest in interface FacesAjaxComponentjava.io.IOExceptionFacesAjaxComponent.processAjaxRequest(FacesContext)
protected void processAjaxGetRows(javax.faces.context.FacesContext context)
throws java.io.IOException
java.io.IOException
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||