On 10/18/07, Felix Meschberger <[EMAIL PROTECTED]> wrote:

> ...Well, thinking along these lines: Why do we need a Resource and
> ResourceResolver in the first place then ? .......

Technically, as we're limiting ourselves to JCR content, we don't
really need a Resource, you're right.

But currently the Resource does abstract the fact that a Node might be
mapped to an Object or not. The fact that the Resource interface is
small doesn't make it useless: it makes it beautiful ;-)

OTOH we *do* need the ResourceResolver interface very much: it
encapsulates our "rules" for finding a Resource that the current
request must process.

> ...Honestly, if we abstract the Resource, we also have to take the next
> step and abstract access to relative Resources and children....

I might agree about the relative resources, but why the children? And
why just the children axis and not the full
ancestors/descendants/siblings/next/previous axes?

If navigation between Resources is needed and that cannot be covered
by JCR, I'd suggest making that a separate ResourceHierarchyNavigation
interface.

-Bertrand

Reply via email to