|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||
public interface IStreamFactory
The IStreamFactory interface should be implemented by classes that wish to change the transport mechanism used by a RemoteDataSource.
It's openStream() method is called by the StreamWriter when each new message that is being sent by the StreamWriter begins. When the message ends, the StreamWriter calls the closeStream() method. the StreamFactory should then close the stream that it opened in the openStream method. The IStreamFactory should aquire this stream by calling the getStream() method on the StreamWriter rather than storing the stream locally. This ensures that if the StreamWriter wrapped the stream with another stream, that the stream will be flushed and closed normally.
| Method Summary | |
|---|---|
void |
closeStream(StreamWriter sw)
Close an output stream for a StreamWriter. |
OutputStream |
openStream(StreamWriter sw)
Open an output stream for a StreamWriter. |
| Method Detail |
|---|
OutputStream openStream(StreamWriter sw)
throws IOException
sw - the StreamWriter who is calling this method
IOExceptionvoid closeStream(StreamWriter sw)
sw - the StreamWriter who is calling this method
|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||