cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Mathias Reem <>
Subject Checking if resource "type" exists
Date Mon, 16 Mar 2009 22:03:25 GMT

I've been searching for a while for a way to not just determine whether
a resource exists but also if the resource has a specific type (dir,
file, hidden).

As I could not find anything, I wanted to extend the default
ResourceExistsSelector, but as all of its members are private without
any getters or setters I just had to c&p it. :-( Anyway maybe it can be
useful for somebody else too.

You can use my ResourceExistsSelector as a drop in replacement for the
default, it will behave exactly the same way. I've you want to further
restrict the "type" of the resource you just have to pass a parameter
named type to the selector.

Have fun.

View raw message