Re: [boost] Interest in a flyweight library?

----- Mensaje original ----- De: Caleb Epstein <caleb.epstein@gmail.com> Fecha: Viernes, Junio 30, 2006 8:38 pm Asunto: Re: [boost] Interest in a flyweight library? [...]
I immediately thought of an "interned_string" class I had written when I read Joaquin's description. I have only really seen this technique called "interning" and (once) "coadunation" before.
There is an implementation of something similar for strings only in the ASL called adobe::name_t: http://opensource.adobe.com/classadobe_1_1name__t.html I like this utility, but I agree it might be better named boost::interned<T>.
-- Caleb Epstein
Hello Caleb, Please see my previous answer to Steve Harris. It'd help me a lot if, for uniformity's sake, name proposals could be given in this format: lib name / namespace names / main utility like for instance: Boost.Intern / boost::intern / boost::interned<> So, cast your vote :) Best, Joaquín M López Muñoz Telefónica, Investigación y Desarrollo

JOAQUIN LOPEZ MU?Z wrote:
Please see my previous answer to Steve Harris. It'd help me a lot if, for uniformity's sake, name proposals could be given in this format:
lib name / namespace names / main utility
like for instance:
Boost.Intern / boost::intern / boost::interned<>
So, cast your vote :)
I have a problem with these names -- Boost.intern sounds like a developer that should be working on an SOC project. 'Interned' sounds like what happens when someone dies and is buried -- not too pleasant. I think flyweight is better, although maybe some variant of 'wrapper' might be better. Another question, C# and some other languages have the idea of 'boxing' -- perhaps that's what this really is? Jeff

Jeff Garland wrote:
JOAQUIN LOPEZ MU?Z wrote:
Please see my previous answer to Steve Harris. It'd help me a lot if, for uniformity's sake, name proposals could be given in this format:
lib name / namespace names / main utility
like for instance:
Boost.Intern / boost::intern / boost::interned<>
So, cast your vote :)
I have a problem with these names -- Boost.intern sounds like a developer that should be working on an SOC project. 'Interned' sounds like what happens when someone dies and is buried -- not too pleasant. I think flyweight is better, although maybe some variant of 'wrapper' might be better. Another question, C# and some other languages have the idea of 'boxing' -- perhaps that's what this really is?
I second Jeff. This is also the impression I get with intern, interned. I've been using the flyweight pattern for a long time now, as a pattern and not as actual classes, but I wouldn't mind seeing them as such. I have no problem with it. Regards, -- Joel de Guzman http://www.boost-consulting.com http://spirit.sf.net

On 7/1/06, Jeff Garland <jeff@crystalclearsoftware.com> wrote:
I have a problem with these names -- Boost.intern sounds like a developer that should be working on an SOC project. 'Interned' sounds like what happens when someone dies and is buried -- not too pleasant. Thanks for phrasing what I was thinking better than I had managed to.
I have never heard of intern, but recognize flyweight from the GoF book. I don't think it would be confused as something else, since a library that only offered representation sharing would probably be called copy_on_write or cow_ptr or similar. Boost.Flyweight / boost::flyweights / boost::flyweight<T> sounds good to me. ~ Scott McMurray

"JOAQUIN LOPEZ MUNOZ" wrote: [ name proposal ]
Boost.Intern / boost::intern / boost::interned<>
I am not sure whether "intern" is used widely enough. If I knew such use in the past I did forget it quickly. One possibly term is Multiton (modeled after Singleton, meaning pool of unique shared objects, singletons): http://en.wikipedia.org/wiki/Multiton_pattern (It is infrequently used term and was actually implemented in deceased Boost.Singleton library.) As Multiton is obvious loser perhaps the descriptive "Shared Object Pool"for the library and "pool" (or "pooled_object" or variant) for type name may be considered. "flyweight" is something different from what the library does and thus not very good term. /Pavel
participants (5)
-
Jeff Garland
-
JOAQUIN LOPEZ MU?Z
-
Joel de Guzman
-
me22
-
Pavel Vozenilek