[ENH] asDigitVersion ( [er] String maybe not the best place for this )

stéphane ducasse ducasse at iam.unibe.ch
Sun Mar 28 16:46:11 UTC 2004


Hi

I coded it but I was sure it was somewhere :). After losing time to 
look for it, I did it. Because I was frustrated not to be able to make 
what I wanted.

So what do you prefer? I like the idea of alexander. Alexander do you 
want to do it? I can review it that way. Now I'm the middle of an 
export/import facility for ThreadNavigator so that I stop to lose
time for building demoes.

Stef

On 28 mars 04, at 17:52, Alexander at Lazarevic.de wrote:

>
> I would place this kind of functioality into class Integer (or maybe
> throughout the Number hierarchy) in a more general form like
>
> printOn: aStream base: base length: total padding: aBoolean
>
> and friends
>
> printStringBase: base length: total padding: aBoolean
> printString: length
> printStringPadded: length
> ...
>
> So
>
> 	1 printStringPadded: 3 -> '001'
>
> would give you what you want and would be open to many other uses cases
>




More information about the Squeak-dev mailing list