org.objectweb.david.apis.presentation
Interface DavidStreamFactory

All Superinterfaces:
MarshallerFactory
All Known Implementing Classes:
PortableMarshallerFactory

public interface DavidStreamFactory
extends MarshallerFactory

Factory for David streams.


Method Summary
 DavidInputStream newInputStream(Chunk chunk, int read)
          Creates a new input stream, reading data from the provided chunk.
 DavidInputStream newInputStream(ChunkProvider message)
          Creates a new input stream, reading data from the specified chunk provider.
 DavidOutputStream newOutputStream()
          Creates a new output stream.
 
Methods inherited from interface org.objectweb.jonathan.apis.presentation.MarshallerFactory
newMarshaller, newUnMarshaller, newUnMarshaller
 

Method Detail

newOutputStream

public DavidOutputStream newOutputStream()
Creates a new output stream.

Returns:
a new output stream.

newInputStream

public DavidInputStream newInputStream(ChunkProvider message)
Creates a new input stream, reading data from the specified chunk provider.

Parameters:
message - a chunk provider.
Returns:
a new input stream.

newInputStream

public DavidInputStream newInputStream(Chunk chunk,
                                       int read)
Creates a new input stream, reading data from the provided chunk.

The read parameters indicates the number of bytes read since the beginning of the message.

Parameters:
chunk - a chunk;
read - the number of bytes already read from the message.
Returns:
a new input stream.