Name
DataModel
Synopsis
This abstract class represents
the model for a
UIData
component.
Class name: |
javax.faces.model.DataModel |
Extends: |
None |
Implements: |
None |
Constructor
-
public DataModel()
Creates a new, empty instance.
Methods
-
public void addDataModelListener(javax.faces.model.DataModelListener l)
Adds the
DataModelListener
to the list of listeners for theDataModelEvent
this model fires.-
public javax.faces.model.DataModelListener[] getDataModelListeners()
Returns all
DataModelListener
instances registered for the model.-
public abstract int getRowCount()
Returns the number of rows represented by the model or -1 if unknown.
-
public abstract Object getRowData()
Returns an object representing the current row index or
null
if there is no row data for the row index.-
public abstract int getRowIndex()
Returns the zero-based index for the current row or -1 if no row is selected.
-
public abstract Object getWrappedData()
Returns the raw data wrapped by this model or
null
if the data isn’t set.-
public abstract boolean isRowAvailable()
Returns
true
if the current row index matches an existing row.-
public void removeDataModelListener(javax.faces.model.DataModelListener l)
Removes the
DataModelListener
from the list of listeners for theDataModelEvent
this model fires.-
public abstract void setRowIndex(int index)
Sets the zero-based index for the current row or to -1 if no row is selected.
-
public abstract void setWrappedData(Object data)
Sets the data containing rows.
Get JavaServer Faces now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.