|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.vaadin.client.data.DataSource.RowHandle<T>
com.vaadin.client.data.AbstractRemoteDataSource.RowHandleImpl
protected class AbstractRemoteDataSource.RowHandleImpl
| Constructor Summary | |
|---|---|
AbstractRemoteDataSource.RowHandleImpl(T row,
java.lang.Object key)
|
|
| Method Summary | |
|---|---|
protected boolean |
equalsExplicit(java.lang.Object obj)
An explicit override for Object.equals(Object). |
T |
getRow()
Gets the most recent representation for the row this handle represents. |
protected int |
hashCodeExplicit()
An explicit override for Object.hashCode(). |
boolean |
isPinned()
|
void |
pin()
Marks this row as pinned. |
void |
setRow(T row)
A method for the data source to update the row data. |
void |
unpin()
Marks this row as unpinned. |
void |
updateRow()
Informs the DataSource that the row data represented by this RowHandle has been updated. |
| Methods inherited from class com.vaadin.client.data.DataSource.RowHandle |
|---|
equals, hashCode |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public AbstractRemoteDataSource.RowHandleImpl(T row,
java.lang.Object key)
| Method Detail |
|---|
public void setRow(T row)
row - the updated row object
public T getRow()
throws java.lang.IllegalStateException
DataSource.RowHandle
getRow in class DataSource.RowHandle<T>java.lang.IllegalStateException - if this row handle isn't currently pinnedDataSource.RowHandle.pin()public boolean isPinned()
public void pin()
DataSource.RowHandleNote: Pinning a row multiple times requires an equal amount of unpins to free the row from the "pinned" status.
Technical Note: Pinning a row makes sure that the row object for a particular set of data is always kept as up to date as the data source is able to. Since the DataSource might create a new instance of an object, object references aren't necessarily kept up-to-date. This is a technical work-around for that.
pin in class DataSource.RowHandle<T>DataSource.RowHandle.unpin()
public void unpin()
throws java.lang.IllegalStateException
DataSource.RowHandleNote: Pinning a row multiple times requires an equal amount of unpins to free the row from the "pinned" status.
Technical Note: Pinning a row makes sure that the row object for a particular set of data is always kept as up to date as the data source is able to. Since the DataSource might create a new instance of an object, object references aren't necessarily kept up-to-date. This is a technical work-around for that.
unpin in class DataSource.RowHandle<T>java.lang.IllegalStateException - if this row handle has not been pinned beforeDataSource.RowHandle.pin()protected boolean equalsExplicit(java.lang.Object obj)
DataSource.RowHandleObject.equals(Object). This method
should be functionally equivalent to a properly implemented equals
method.
Having a properly implemented equals method is imperative for RowHandle to function. Because Java has no mechanism to force an override of an existing method, we're defining a new method for that instead.
equalsExplicit in class DataSource.RowHandle<T>true if this object is the same as the obj argument;
false otherwise.protected int hashCodeExplicit()
DataSource.RowHandleObject.hashCode(). This method
should be functionally equivalent to a properly implemented hashCode
method.
Having a properly implemented hashCode method is imperative for RowHandle to function. Because Java has no mechanism to force an override of an existing method, we're defining a new method for that instead.
hashCodeExplicit in class DataSource.RowHandle<T>public void updateRow()
DataSource.RowHandle
updateRow in class DataSource.RowHandle<T>DataChangeHandler.dataUpdated(int, int)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||