maven-doxia-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Hervé BOUTEMY <>
Subject Re: (output) encoding support in doxia-sink-api
Date Fri, 07 Nov 2008 16:57:30 GMT
Le vendredi 07 novembre 2008, Benjamin Bentmann a écrit :
> It might however be convenient to create an AbstractTextSinkFactory from
> which all/most text-based sinks could inherit.
Seems a good idea.
This would ensure too that every text-based sinks have the same default 
encoding: it gives some consistency. Is it too limitating? I don't think.

> > Or if we want an API without filename, this method could be transformed
> > into Sink createSink( OutputStream output ) + Sink createSink(
> > OutputStream output, String encoding ).
> Unless we actually have need for this (testing with in-memory streams?),
if we want to generate and zip or transfer on-the-fly, for example. It's only 
an general idea: I don't really have any plans. I was just guessing that if a 
method with a Writer was added, some had something in mind.

> I would keep the interface slim to ease its implementation.
ok with that

> Another question might be: Does the relation
>    1 sink -> 1 output file/stream
> always hold or are there formats that might need to output multiple
> files? In the later case, createSink( OutputStream ) would be troublesome.
AFAIK, we always have 1 sink -> 1 file/stream
but I don't have sufficient experience with Doxia use-cases to affirm that.

> Benjamin
thanks for your comments


View raw message