[Pharo-users] Couple grafoscopio notes

2017-01-19 Thread Peter Uhnak
Hi, I've started playing around with grafoscopio, I am happy that I can finally organize all those little scripts and not lose them all the time. :) However there are couple of issues and notes I've ran into (don't worry about fixing them in any timely fashion, it is not blocking me) 1. For

Re: [Pharo-users] singleton trait

2017-01-19 Thread Siemen Baader
On Thu, Jan 19, 2017 at 3:51 PM, Siemen Baader wrote: > > On Thu, Jan 19, 2017 at 11:33 AM, Cyril Ferlicot D. < > cyril.ferli...@gmail.com> wrote: > >> >> You just need a class variable #UniqueInstance and those methods: >> >> current >> "Can also be named #default or

Re: [Pharo-users] singleton trait

2017-01-19 Thread Cyril Ferlicot D.
On 19/01/2017 15:51, Siemen Baader wrote: > > Wouldn't a class instance variable be better? I want new singletons for > every subclass. > http://rmod-pharo-mooc.lille.inria.fr/MOOC/Slides/Week3/C019-W3S03-Basic-Variables.pdf I use a class variable because I try to avoid a maximum the use of the

Re: [Pharo-users] singleton trait

2017-01-19 Thread jtuc...@objektfabrik.de
Am 19.01.17 um 15:51 schrieb Siemen Baader: Wouldn't a class instance variable be better? I want new singletons for every subclass. http://rmod-pharo-mooc.lille.inria.fr/MOOC/Slides/Week3/C019-W3S03-Basic-Variables.pdf I would also have used super new, why BasicNew? But my wish to create

Re: [Pharo-users] singleton trait

2017-01-19 Thread Siemen Baader
On Thu, Jan 19, 2017 at 11:33 AM, Cyril Ferlicot D. < cyril.ferli...@gmail.com> wrote: > > You just need a class variable #UniqueInstance and those methods: > > current > "Can also be named #default or #instance" > ^ UniqueInstance > ifNil: [ UniqueInstance := self

Re: [Pharo-users] [Deployement] Apache rewrite rules for Pharo

2017-01-19 Thread Blondeau Vincent
Hi, That is what I done to configure the apache server with 2 servers (one running on 8181 and the other on 8080): ProxyPreserveHost On ProxyRequests Off RewriteEngine On RewriteRule ^//(.*)$ http://localhost:8181/< my service >/$1 [proxy] RewriteRule

Re: [Pharo-users] singleton trait

2017-01-19 Thread Siemen Baader
On Thu, Jan 19, 2017 at 11:37 AM, Sven Van Caekenberghe wrote: > The Traits would be cool to standardise the behaviour and to mark it as > such (implicit documentation) Exactly. > , however, Traits cannot add instance/class variables IIUC, that limits > what they can do (and

Re: [Pharo-users] singleton trait

2017-01-19 Thread Denis Kudriashov
2017-01-19 11:37 GMT+01:00 Sven Van Caekenberghe : > The Traits would be cool to standardise the behaviour and to mark it as > such (implicit documentation), however, Traits cannot add instance/class > variables IIUC, that limits what they can do (and would make it more than > one

Re: [Pharo-users] singleton trait

2017-01-19 Thread Sven Van Caekenberghe
The Traits would be cool to standardise the behaviour and to mark it as such (implicit documentation), however, Traits cannot add instance/class variables IIUC, that limits what they can do (and would make it more than one step). > On 19 Jan 2017, at 11:33, Cyril Ferlicot D.

Re: [Pharo-users] singleton trait

2017-01-19 Thread Cyril Ferlicot D.
On 19/01/2017 11:23, Siemen Baader wrote: > Is there a trait to quickly create singletons in Pharo, along the way of > the Ruby Singleton mixin? > > https://ruby-doc.org/stdlib-1.9.3/libdoc/singleton/rdoc/Singleton.html > > (and ideally also observer/observable, which I am going to need next..)

[Pharo-users] singleton trait

2017-01-19 Thread Siemen Baader
Is there a trait to quickly create singletons in Pharo, along the way of the Ruby Singleton mixin? https://ruby-doc.org/stdlib-1.9.3/libdoc/singleton/rdoc/Singleton.html (and ideally also observer/observable, which I am going to need next..) -- Siemen

Re: [Pharo-users] STON encoding of slashes

2017-01-19 Thread Peter Uhnak
On Wed, Jan 18, 2017 at 04:38:15PM +0100, Sven Van Caekenberghe wrote: > Being a superset means that you get a simple JSON parser (and even limited > writer) for free once you install STON (or once it is part of the Pharo > image, as it is now). It also means that we can fall back to the JSON