de.dante.extex.backend.outputStream
Interface OutputStreamFactory

All Known Implementing Classes:
OutputFactory, TrivialOutputFactory

public interface OutputStreamFactory

This is the factory for new OutputStreams.

Version:
$Revision: 1.3 $
Author:
Gerd Neugebauer

Method Summary
 java.io.OutputStream getOutputStream(java.lang.String name, java.lang.String type)
          Getter for a new OutputStream.
 void register(OutputStreamObserver observer)
          Register an observer which is invoked to notify about any output stream requested via a call to getOututStream(),
 void setExtension(java.lang.String extension)
          Setter for the default extension.
 

Method Detail

getOutputStream

public java.io.OutputStream getOutputStream(java.lang.String name,
                                            java.lang.String type)
                                     throws DocumentWriterException
Getter for a new OutputStream.

Parameters:
name - the name segment to characterize the stream externally. This segment might be used as part of the output file. If the name is null then it is treated as not given at all.
type - the type of the stream to acquire. In general this should correspond to the extension of a file of this type
Returns:
the new OutputStream
Throws:
DocumentWriterException - in case of an error

register

public void register(OutputStreamObserver observer)
Register an observer which is invoked to notify about any output stream requested via a call to getOututStream(),

Parameters:
observer - the observers to register

setExtension

public void setExtension(java.lang.String extension)
Setter for the default extension. The default extension is used when the type specified is null.

Parameters:
extension - the default extension