> public interface ResourceResolver {
> void resolveResource(SlingRequestContext context) throws
> SlingException;
> }
>
> The resolver would set the Resource and SlingRequestPathInfo on the
> context immediately. And I think, the SlingRequestContext probably needs
> a "backlink" to the request it belongs to, which would also help making
> the RequestParameterMap generation lazy.
this limits the 'resource resolution' to only work with a sling
request context. what if i want to resolve a resourse without context
? e.g. when i want to check if a respective resource exists?
i would have to create a fake request context ?
> > public interface ResourceResolver {
> >
> > Result resolveResource(HttpServletRequest req) throws Exception;
> >
> > public static class Result {
> > ...
> > public Resource getResource();
> >
> > // Indicates which part of the request URI path
> > // was used to resolve the resource (see SLING-60)
> > // This is usually the Resource's JCR path, but I have
> > // this vague feeling that decoupling them might be
> > // good (if only to expose this method here)
> > public String getResolutionPath();
> > }
> > }
what about a:
interface ResolvedResource extends Resource {
public String getResolutionPath();
}
and:
ResolvedResource resolveResource(HttpServletRequest req) throws Exception;
--
-----------------------------------------< [EMAIL PROTECTED] >---
Tobias Bocanegra, Day Management AG, Barfuesserplatz 6, CH - 4001 Basel
T +41 61 226 98 98, F +41 61 226 98 97
-----------------------------------------------< http://www.day.com >---