[
https://issues.apache.org/jira/browse/MYFACES-2628?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12894800#action_12894800
]
Leonardo Uribe edited comment on MYFACES-2628 at 8/2/10 11:19 PM:
------------------------------------------------------------------
There is no reason to expose it, but note ResourceResolver is part of the
current api, and there is a web config param:
javax.faces.FACELETS_RESOURCE_RESOLVER
used to override it. This class is used by the vdl to retrieve facelet xhtml
files and construct Facelet instances (in this case DefaultFacelet instances).
My first idea looking this stuff is why there is a param for create an instance
to an object that I can't retrieve from the place it could be useful?
Thinking more about it the problem is the vdl should be responsible to indicate
if the viewId is valid or not, on in other words, if there is a source file
that can generate a view with the viewId identifier. In jsp case it just should
try to locate a .jsp file with the same name, in facelets case check this
condition using the ResourceResolver instance (in the default case it does the
same a jsp case but for xhtml files). Note
FaceletViewDeclarationLanguage.createFaceletFactory creates an instance of
ResourceResolver and pass it to DefaultFaceletFactory. Maybe we should send an
email to jsr-314-open, so this could be included in jsf 2.1.
To solve this issue maybe we can hold a duplicate instance to ResourceResolver,
one on facelets vdl (specifically on the factory) and the other one on
RestoreViewSupport instance. After all, this class is expected to be stateless,
so it will be no problem.
Suggestions are welcome.
was (Author: lu4242):
There is no any reason to expose it, but note ResourceResolver is part of
the current api, and there is a web config param:
> Facelets ResourceSolver cant work
> ---------------------------------
>
> Key: MYFACES-2628
> URL: https://issues.apache.org/jira/browse/MYFACES-2628
> Project: MyFaces Core
> Issue Type: Bug
> Components: JSR-314
> Affects Versions: 2.0.0-beta-3
> Environment: tomcat 6.0.20, java 1.6(mac osx),
> Reporter: Mark Li
> Original Estimate: 1h
> Remaining Estimate: 1h
>
> In facelets 1.1.14, I can load page from classpath via ResourceSolver,
> by in myfaces 2.0.0-beta-3, I cant do this, because
> 'DefaultRestoreViewSupport.checkResourceExists' method check the resource
> exists using 'servletContext.getResource(path);', should do some delegate.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.