JClass DesktopViews 6.3.0 API
Documentation

com.klg.jclass.datasource
Interface StoreModel

All Known Implementing Classes:
Store

public interface StoreModel

Provides storage and retrieval for DataTableData. Maps between bookmarks and row indexes.


Method Summary
 void addRow(long bookmark, Object row)
          Add a row.
 void addRow(long bookmark, Object row, int ordinal)
          Insert a row.
 void clear()
          Clear all rows.
 long getBookmark(int ordinal)
          Return the bookmark of the row at ordinal.
 int getIndex(long bookmark)
          Get index.
 Object getRow(long bookmark)
          Given a bookmark, return the row
 int getRowCount()
          Return the number of rows in this store
 void removeRow(long bookmark)
          Remove a row.
 

Method Detail

getRowCount

public int getRowCount()
Return the number of rows in this store

Returns:
an int which is the number of rows in this store

getRow

public Object getRow(long bookmark)
Given a bookmark, return the row

Parameters:
bookmark - the long which uniquely identifies a row
Returns:
the row object for this bookmark

addRow

public void addRow(long bookmark,
                   Object row)
Add a row.


addRow

public void addRow(long bookmark,
                   Object row,
                   int ordinal)
Insert a row.


removeRow

public void removeRow(long bookmark)
Remove a row.

Parameters:
bookmark - the long bookmark of the row to be removed

getIndex

public int getIndex(long bookmark)
Get index.

Parameters:
bookmark - a long which uniquely identifies a row
Returns:
its ordinal position

getBookmark

public long getBookmark(int ordinal)
Return the bookmark of the row at ordinal.

Returns:
the long bookmark of the row at ordinal

clear

public void clear()
Clear all rows.


Copyright © 2004 Quest Software Inc..
All rights reserved.