You are viewing a plain text version of this content. The canonical link for it is here.
Posted to adffaces-issues@incubator.apache.org by "Matthias Weßendorf (JIRA)" <ad...@incubator.apache.org> on 2007/03/16 07:59:10 UTC
[jira] Updated: (ADFFACES-342) ChildPropertyTreeModel and
SortableModel will throw NPE if used outside of the JSF lifecycle
[ https://issues.apache.org/jira/browse/ADFFACES-342?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Matthias Weßendorf updated ADFFACES-342:
----------------------------------------
Fix Version/s: 1.0.0-incubating-core
Affects Version/s: 1.0.0-incubating-core
> ChildPropertyTreeModel and SortableModel will throw NPE if used outside of the JSF lifecycle
> --------------------------------------------------------------------------------------------
>
> Key: ADFFACES-342
> URL: https://issues.apache.org/jira/browse/ADFFACES-342
> Project: MyFaces ADF-Faces
> Issue Type: Bug
> Affects Versions: 1.0.0-incubating-core
> Reporter: Adam Winer
> Assigned To: Adam Winer
> Fix For: 1.0.0-incubating-core
>
>
> ChildPropertyTreeModel uses PropertyResolver to look at children. All good, but if you're outside of the JSF lifecycle, the following line is going to throw a null pointer exception:
> FacesContext context = FacesContext.getCurrentInstance();
> return
> context.getApplication().getPropertyResolver().getValue(parentData, prop);
> SortableModel has similar code.
> We've just had an internal user attempt to use ChildPropertyTreeModel from a filter. A little strange, but there's no obvious reason why these classes should only be useable with a FacesContext active (they don't take FacesContext anywhere in the API), and the Application can be retrieved from the ApplicationFactory (albeit more slowly).
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.