cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Bart Molenkamp" <>
Subject RE: Write binary data to output stream from flow
Date Fri, 18 Feb 2005 10:37:17 GMT

> -----Original Message-----
> From: Upayavira []
> Sent: Friday, February 18, 2005 11:20 AM
> To:
> Subject: Re: Write binary data to output stream from flow
> Bart Molenkamp wrote:
> > Yes, it makes even better sense.
> >
> > Would such a more generic, JXPath oriented stream reader be a
> > contribution to Cocoon?
> To me it would. Anyone else think so, or have some reasons against?
> In fact, the object you pass to the reader (via the XPath string),
> should not be the input stream, but some object that has a
> getInputStream method. That would make better sense. 

If the object in the context is a bean, the path ./inputStream will make
JXPath invoke getInputStream(), right? And the same for mimeType of
course. So this leaves the user to make the decision if he passes an
object which has a getInputStream() method, or if he passes the stream

> And the reader
> could check to see if the object has a getMimeType() method, and if
> get the mime type from that. It should also be possible to configure
> mime type in the component definition or via the <map:read
> mime-type="xxx"> approach, or however the ResourceReader currently
> Regards, Upayavira


View raw message