Class
caplin.grid

DataProviderRowModel

The DataProviderRowModel is the default implementation of caplin.grid.GridRowModel, and attempts to perform all the generic tasks that a caplin.grid.GridRowModel can provide, but delegates all the implementation specific jobs of caplin.grid.GridRowModel to the caplin.grid.GridDataProvider it is associated with.

The DataProviderRowModel provides the following functionality:

The DataProviderRowModel defines a model for acquiring row data and for listening to row model events.

Constructor Summary

Attributes Name and Description
caplin.grid.DataProviderRowModel(caplin.grid.GridColumnModel oColumnModel, caplin.grid.GridDataProvider oDataProvider)

Constructs a caplin.grid.DataProviderRowModel.

Field Summary

Attributes Name and Description
<static> caplin.grid.DataProviderRowModel.OBJECT_DATA_TIMEOUT

The amount of time to wait for each object before firing caplin.grid.GridRowModelListener#onAllDataReceived

Method Summary

Attributes Name and Description
void getSubjects()

void setRowDataBySubject(int nIndex, Map mRowData)

Method added to allow editing data inside grid.

void supportsFeature(int nFeature)

Determine whether this instance of GridRowModel supports a particular feature.

Methods implemented from class caplin.grid.GridRowModel:
addRow, addRowModelListener, clearFilterExpression, clearGroupByField, clearSortRule, getAllFilterExpressions, getFilterExpression, getGridDataProvider, getGroupByField, getIndexBySubject, getPermissionKey, getRowData, getRowRangeSize, getSerializedState, getSize, getSortRule, getStartIndex, getSubjectId, getTransformMode, getVisibleSubjects, pauseUpdates, removeRow, removeRowModelListener, removeRows, resumeUpdates, setFilterExpression, setGroupByField, setRowData, setRowRange, setSortRule, terminateUpdates
Methods implemented from class caplin.grid.GridColumnModelListener:
onApplyFilters, onColumnsAdded, onColumnsRemoved, onFiltersChanged, onRequiredFieldsChanged, onSortColumnChanged, onWidthChanged
Methods implemented from class caplin.grid.GridDataProviderListener:
onDataReceived, onDataRequested, onDataUnavailable, onRecordAdded, onRecordContentsChanged, onRecordMoved, onRecordRemoved, onSizeChanged, onStartIndexChanged, onStructureChangeComplete

Constructor Detail

caplin.grid.DataProviderRowModel(caplin.grid.GridColumnModel oColumnModel, caplin.grid.GridDataProvider oDataProvider)

Constructs a caplin.grid.DataProviderRowModel.

Parameters
caplin.grid.GridColumnModel oColumnModel The column model this row model is associated with — necessary for listening to sorting and filtering events on the column model.
caplin.grid.GridDataProvider oDataProvider The data provider instance that will do the actual work of providing the data that will be contained by the row model.

Field Detail

<static> int caplin.grid.DataProviderRowModel.OBJECT_DATA_TIMEOUT

The amount of time to wait for each object before firing caplin.grid.GridRowModelListener#onAllDataReceived

Method Detail

void getSubjects()

void setRowDataBySubject(int nIndex, Map mRowData)

Method added to allow editing data inside grid. The implementation adds the field to a field cache which overrides the fields received from rttp Sets the field value for the row with the specific index

Parameters
int nIndex index id of the row to add field
Map mRowData field maps to update

void supportsFeature(int nFeature)

Determine whether this instance of GridRowModel supports a particular feature.

This method is merely proxied on to the underlying caplin.grid.GridDataProvider.

Parameters
int nFeature the feature constant that is being queried.
See
caplin.grid.GridRowModel#supportsFeature