On Thu, Nov 10, 2005 at 03:47:20AM -0800, Lars D. Noodén wrote:
> On Wed, 9 Nov 2005, Peter Karman wrote:
> > ... Given that SWISH::Filter doesn't handle multiple files and/or
> > compressed files, you might be better off writing your own filtering
> > program (in whatever language) and feeding that directly to -S prog.
> It could be really simple since the separate files do belong together and
> could have been a single file had the designers of OpenDocument made
> different decisions:
> echo "<xml>`unzip -c $FILE meta.xml contents.xml`</xml>";
You can't have two XML declarations in the file. Libxml2 will just
> I guess I'm a bit unclear about how SWISH::Filter works. I'd expect that
> it would look at the ODF file, which is the zip equivalent of a tar-ball,
> and then pass it off to the relevant SWISH::Filter::* filter which then
> returns a stream of text. Is that about right?
I think looking at other filters will help. The document is either
passed as a file or in already in RAM. There's utility functions so
you don't have to worry about that -- you can ask for its filename and
it will get written to a temp file automatically if currently in
memory. That would be if your filter program requires that the
document be on disk. Other filter programs (or perl modules) can work
with files in memory or with files on disk.
Unsubscribe from or help with the swish-e list:
Help with Swish-e:
Received on Thu Nov 10 05:06:01 2005