As an upgrade (Restlet request!), looking through the source code it seems that the simplest thing would be if I could insert my own ReferenceList implementation. Perhaps you could have a #setReferenceList option which would take my own (sub-)class. Not only could I change the HREF, but it would be great to put in my own HTML representation anyway, with style, logo, etc.
Cliff _____ From: Cliff Binstock [mailto:[EMAIL PROTECTED] Sent: Friday, November 21, 2008 2:54 PM To: discuss@restlet.tigris.org Subject: Usurping Directory I would like to modify the standard Directory to return something different than "the" file when a file is encountered. For example, peruse a directory structure (default behavior), but when you get to the "bottom" (an actual file), then return a report based on that file, instead of the file itself. It appears that I need a custom "DirectoryResource" which is attached to a "Directory" via #setTargetClass. I have the following questions: 1. Setting the target class doesn't seem to be invoking the resource 2. I'm not sure what I would need to override to have custom behavior: #getVariants? 3. Is there a better way to approach the problem? Thanks in advance, Cliff