About pushBack:
Michael Rueger
michael at impara.de
Thu Aug 2 13:31:13 UTC 2007
stéphane ducasse wrote:
> Hi Mike
>
> we are heroically trying to clean Stream hierarchy (in fact making sure
> that the new and sexy one that damien is writing can be plugged in).
>
> We are reading
>
> PositionableStream>>pushBack: aString
> "Compatibility with SocketStreams"
> self skip: aString size negated
>
>
> and it seems to me that pushBack argument is not good. It should not be
> a string but a number since
> it never take care of pushing back different elements in the stream but
> just moving the cursor of the stream.
Yes, but...
On a SocketStream we can't position the cursor, once the characters are
read they are no longer in the stream as there is no underlying
collection. The buffer doesn't count, as the content can be replaced at
any time during read or write.
> Do you know if the method pushBack on the XMLTokenizer is ever used?
It's used when parsing and resolving entity definitions.
Michael
More information about the Squeak-dev
mailing list
|