I think that this overlaps with commons-vfs in terms of functionality. Have you seen that project?

Stephen


Bill Silvester wrote:
Hi,

I've built and am using a StreamResolver interface which I find useful, and wondered if anyone here would be interested in adding it to the commons-io library.

The basic interface is pretty simple, and is intended to allow simple access to input/output streams, without having to worry about the mechanics of exactly where/what kind of stream they are.

   public interface StreamResolver {
       public boolean exists(String path);
       public InputStream openInputStream(String path);
       public OutputStream openOutputStream(String path);
       public String resolvePath(String path);
   }

I've currently got the following implementations:

   FileStreamResolver - a basic resolver just using a file path.
ZipStreamResolver - uses base resolver to access a zip file, and provides access to files within the archive. ServletStreamResolver - based on a ServletContext, using getResourceAsStream() internally.

If anyone wants to checkout my current implementation, you can currently find it at http://bsxl.com/tmp/stream-resolver.tgz.

If anyone is interested in this, I'll be happy to format it as per the guidelines, and contribute it to the project.

Cheers,

Bill

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to