[
https://issues.apache.org/jira/browse/TRINIDAD-1432?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12688780#action_12688780
]
Maria Kaval commented on TRINIDAD-1432:
---------------------------------------
Some further comments on why this API is needed:
Internal views are viewIds that may be requested by a client and are handled
internal to the web application, without necessarily dispatching to a resource
like a JSP. An internal view handler is implemented by extending the
org.apache.myfaces.trinidad.render.InternalView abstract class.
Certain controllers keep track of the viewId of the currently displayed view in
a window. When a request is received on the server the controller checks to
see if the requested viewId is different from the last known viewId for that
window. If the viewIds are different then the controller recognizes this
situation as a navigation and releases any state it had for the previous view.
The problem is internal views doesn't always result in display of a new view in
window, i.e. in navigation. Instead, they may just request some logic be
executed or that a new window be opened.
In order to prevent incorrectly triggering the controller's navigation
detection, the controller needs to be able to determine if the current View
Root is an internal view or not. The proposed API is thus:
RequestContext
{
/**
* Determines whether the current View Root is an internal view
* @param context Faces context
* @return true if the current View Root is an internal view, false otherwise
*/
public abstract boolean isInternalViewRequest(FacesContext context);
}
> Need a method on RequestContext to detect an internal view
> ----------------------------------------------------------
>
> Key: TRINIDAD-1432
> URL: https://issues.apache.org/jira/browse/TRINIDAD-1432
> Project: MyFaces Trinidad
> Issue Type: New Feature
> Components: Archetype
> Affects Versions: 1.2.11-core
> Reporter: Max Starets
> Attachments: trinidad-1432.patch
>
>
> We need to expose a method on the RequestContext to determine whether the
> current View Root represents an internal view. This functionality
> is needed for tracking navigation by a Controller module outside of Trinidad.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.