[ 
https://issues.apache.org/jira/browse/TRINIDAD-1796?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Kamran Kashanian updated TRINIDAD-1796:
---------------------------------------

    Status: Patch Available  (was: Open)

> NoRowAvailableException in ChildPropertyTreeModel
> -------------------------------------------------
>
>                 Key: TRINIDAD-1796
>                 URL: https://issues.apache.org/jira/browse/TRINIDAD-1796
>             Project: MyFaces Trinidad
>          Issue Type: Bug
>          Components: Components
>    Affects Versions: 2.0.0.3-core
>         Environment: All
>            Reporter: Kamran Kashanian
>         Attachments: ChildPropertyTreeModel.patch
>
>
> The contract for the Trinidad CollectionModel/TreeModel  setRowKey() API is 
> that this API should silently fail if an incorrect row key is passed in as a 
> parameter.   The caller is then required to call isRowAvailable() to check 
> for a valid 'current' row in the model before doing anything with the row 
> data.  The JSF DataModel 'setRowIndex()' API behaves the same way.
> The Trinidad ChildPropertyTreeModel implementation,  however,  can throw a 
> NoRowAvailableException if the setRowKey() API is called with an invalid row 
> key in the key path.
> The proposed fix is to check for valid row keys in the key path (by calling 
> isRowAvailable on each child model)  as the setRowKey API implementation 
> traverses the tree model hierarchy and sets the current row at each level.
> I will submit a patch.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to