|
|
|
|||||
|
1/ How to reset an Out/InputStream ?
There is a promising method BasicStream.reset() that allow stream recycling, but no clear equivalent in the user defined interfaces. What is the behavior of the stream created by Ice.Util.createXXXStream(..) after a call to finish? Can it be reused for a new message? 2/ Useless code? The BasicOutputStream is written as: Code:
public class BasicOutputStream extends BasicStream
{
public
BasicOutputStream(Instance instance, Ice.OutputStream out)
{
super(instance);
_out = out;
}
public Ice.OutputStream _out;
}
Code:
public class OutputStreamI implements OutputStream
{
public
OutputStreamI(Communicator communicator)
{
_communicator = communicator;
_os = new IceInternal.BasicOutputStream(Util.getInstance(communicator), this);
}
Rewritting it as: Code:
public class OutputStreamI implements OutputStream
{
public
OutputStreamI(Communicator communicator)
{
_communicator = communicator;
_os = new IceInternal.BasicStream(Util.getInstance(communicator));
}
The BasicOutputStream class can be entirely removed without breaking any client. |
|
|||||
|
Quote:
Can you provide some background? And you can add this question to the shoplist: Why the BasicStream is a kind of input/output mixin class? (Usually, input and output related funtionnalities are provided by separate interfaces, eventually collapsed into one "full duplex" at some time in the stream type hierarchy.) Thanks |
|
||||||
|
Quote:
Quote:
- Mark |
|
||||||
|
BasicStream is both an input and output stream because this simplifies Ice internals. Other than that I cannot provide more information, as discussing Ice internal design details (BasicStream is an internal class, i.e., the Ice application developer must not use it) is out of the scope of the support we can give here on this message board.
|
|
|||||
|
Quote:
This is not a support request (thus i use this 'comments' newsgroup), just user feedback. The streaming API is new, its documentation minimalistic and of great interest for us. It just appears that its structure is slightly different of what we are accustomed to see in other streaming libraries, and we are looking for the best way to adapt ourselves. I understand you provide the best support for your product and you need to get time to develop it and make some business with it. Regards. |
![]() |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Need Help with Streaming | zhi | Help Center | 14 | 01-09-2007 10:40 PM |
| streaming function "write/readContext" for Ice::Context | sylvain | Help Center | 0 | 09-13-2006 06:14 AM |
| Question about of readObject() in Streaming Interface | kongchoy | Help Center | 2 | 02-08-2006 12:55 PM |