Geert Josten wrote:

I was uncertain that it is in the 'main' block, so looked things up. And you know what? You can find ZipSource and ZipSourceFactory in scratchpad block (2.1.6 at least).

:-P


you are right, indeed.

I put them into Lenya directly and it compiles very fine and now it
also works very fine. I will start another thread about putting these
two classes back into Cocoon, because it seems to me they are very useful
and I guess a lot of people would like to render OpenDocument(s) through Cocoon.

Thanks again for your help

Michi


Look in package dir org/apache/cocoon/components/source/impl/

There is also a DirectoryZipArchiver (a reader), but haven't had a change to look at it yet...

Grtz,
Geert

Michael Wechner wrote:

Geert Josten wrote:

Hi,

Done a few things with reading zip files and I haven't included a specific block for that. Just use the zip: pseudo protocol when specifying a source for map:generate or map:read. It should follow this uri format: zip://[EMAIL PROTECTED]




that's what I actually try, but I receive the following error:

java.io.FileNotFoundException: /sitemap/[EMAIL PROTECTED] (No such file or directory)
   at java.io.FileInputStream.open(Native Method)
   at java.io.FileInputStream.<init>(FileInputStream.java:106)
at org.apache.excalibur.source.impl.FileSource.getInputStream(FileSource.java:146) at org.apache.cocoon.components.source.SourceUtil.getInputSource(SourceUtil.java:521) at org.apache.cocoon.components.source.SourceUtil.parse(SourceUtil.java:325)
   at


It seems to me that the FileSource is being taken, because no "zip" source is being defined within cocoon.xconf, or is the FileSource able to handle
zip files?

Thanks for your help

Michi


Though, you have to know the name and path of the file you want from the zip in advance. It doesn't implement the Traversable interface (or how was it called). Unless someone has added that after 2.1.7 orso..

HTH,
Geert

Michael Wechner wrote:

Hi

I would like to use the zip (or jar) source to view ODTs (OpenDocument).

I have found a very nice description at:

http://137.207.120.195:8080/cocoon/wampum/repo/OpenOfficeRocks.odt

but somehow I have trouble to do this myself, because it seems
to me that the zip (and jar) source are or not part of the default cocoon.xconf declaration and I can't figure out what packages I have to include to enable them.

Any pointers are very welcome.

Thanks

Michi







--
Michael Wechner
Wyona      -   Open Source Content Management   -    Apache Lenya
http://www.wyona.com                      http://lenya.apache.org
[EMAIL PROTECTED]                        [EMAIL PROTECTED]


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

Reply via email to