(NEWBIE) FileStream help??
Eric Arseneau
eat at huv.com
Fri Apr 28 12:36:11 UTC 2000
> When I -> Do it the transcript displays several rows of 5 digit
> numbers and
> I do not know what they are. This works fine in st express. What
> does Squeak
> do different?
You problem here is that nextWord on Squeak Stream's returns the next binary
word, ie it takes the next byte, shits it by 8 bits, then adds the next bye,
or the other way around. The point here is that nextWord is not giving you
the next bunch of characters up to the next space.
I couldn't find a method that would give you what you want, but then I have
a really old image. I would recommend you take a look at the one in ST
Express and copy it, or write your own. Something like
nextWordString
| start |
[self next isSeparator] whileTrue.
self atEnd ifTrue: [^''].
start := self position - 1.
[self next isSeperator] whileFalse.
^self copyFrom: start to: self position - 1
Something like that, I haven't run this code but I think you get the idea.
More information about the Squeak-dev
mailing list
|