Custom ContentAdapter: How to distinguish between Files and Directories?
"Kris Bravo" <[email protected]> Sun, 18 Mar 2007 10:33:29 -0400
| Newsgroups | gmane.comp.jakarta.slide.user |
|---|---|
| Message-ID | <[email protected]> |
Hi, I am trying to create a file-sharing system where publishers are required to login to add content and consumers are given a URL to retrieve specific content. The URL must not contain the path to the file, but instead use some sort of UUID. A servlet would cross reference the UUID to the specific file. I didn't find something which does this, so I have been working to create the functionality with Slide. I have begun with a custom Content Adapter which Slide triggers on create events. My intention is to create a .URL file in the store to accompany every file that is created. The .URL file would give the publisher the UUID associated with their file. Unfortunately, I can't figure out how to distinguish between a create event on a file and a create event on a directory. What method should I be calling to identify one versus the other? Thanks, Kris