[Pharo-users] [launcher] Refresh buttons in status bar
Hi Damien, I've just noticed that the latest PharoLauncher has two buttons in the status bar. This since the their superclass is PhLGeneralCommand rather than PhLImageCommand or PhLTemplateCommand classes. Is this intentional? cheers -ben
[Pharo-users] #subStrings: alternative preserving separators
I have a string like 'foo|bar||foobar|' and I want to split it into separate tokens like: 'foo|bar||foobar|' subStrings: $| -> #('foo' 'bar' '' 'foobar' ''). It is... to INCLUDE empty strings (or nil for that case) for the elements between to consecutive separators. I can't found a method implementing this in Pharo (in Dolphin it works as I expect). Thank you! Esteban A. Maringolo
Re: [Pharo-users] #subStrings: alternative preserving separators
In VA, tgey just introduced allSubStrings: for this matter, because subStrings was changed to return only non-empty parts... Do you find that in Pharo? Joachim "Esteban A. Maringolo" schrieb: >I have a string like 'foo|bar||foobar|' and I want to split it into >separate tokens like: > >'foo|bar||foobar|' subStrings: $| -> #('foo' 'bar' '' 'foobar' ''). > >It is... to INCLUDE empty strings (or nil for that case) for the >elements between to consecutive separators. > >I can't found a method implementing this in Pharo (in Dolphin it works >as I expect). > >Thank you! > >Esteban A. Maringolo > >
Re: [Pharo-users] #subStrings: alternative preserving separators
No, there is no #allSubStrings: . However, after your email (and having solved my issue in other way) I just found #findTokens:escapedBy: which does exactly what I need :) 'foo,baz,"3,14",,foobaz' findTokens: $, escapedBy: $". -> an OrderedCollection('foo' 'baz' '3,14' '' 'foobaz') Regards! Esteban A. Maringolo 2013/11/20 Joachim Tuchel : > In VA, tgey just introduced allSubStrings: for this matter, because > subStrings was changed to return only non-empty parts... > Do you find that in Pharo? > > Joachim > > "Esteban A. Maringolo" schrieb: > >>I have a string like 'foo|bar||foobar|' and I want to split it into >>separate tokens like: >> >>'foo|bar||foobar|' subStrings: $| -> #('foo' 'bar' '' 'foobar' ''). >> >>It is... to INCLUDE empty strings (or nil for that case) for the >>elements between to consecutive separators. >> >>I can't found a method implementing this in Pharo (in Dolphin it works >>as I expect). >> >>Thank you! >> >>Esteban A. Maringolo >> >>
[Pharo-users] optimizing io
Hi all! Im making some performance enhancement on PhaROS, i realised that one of my common scenarios is having several sockets that should receive exactly the same information, in order to do that, im using n calls to the vm, which does n system-calls. I was wondering if there something done in: - send the same data to all the sockets in just one primitive - send the same data to all the sockets in just one syscall. I checked around in google but i didn't found anything useful, but probably i have no knowledge about the proper words for such search :). Thanks!
Re: [Pharo-users] #subStrings: alternative preserving separators
Am 20.11.2013 um 04:20 schrieb Esteban A. Maringolo : > I have a string like 'foo|bar||foobar|' and I want to split it into > separate tokens like: > > 'foo|bar||foobar|' subStrings: $| -> #('foo' 'bar' '' 'foobar' ''). > > It is... to INCLUDE empty strings (or nil for that case) for the > elements between to consecutive separators. > > I can't found a method implementing this in Pharo (in Dolphin it works > as I expect). > $| split: 'foo|bar||foobar|' Norbert