Return-Path: Delivered-To: apmail-jakarta-commons-dev-archive@www.apache.org Received: (qmail 75223 invoked from network); 3 Oct 2003 23:15:48 -0000 Received: from daedalus.apache.org (HELO mail.apache.org) (208.185.179.12) by minotaur-2.apache.org with SMTP; 3 Oct 2003 23:15:48 -0000 Received: (qmail 78479 invoked by uid 500); 3 Oct 2003 23:15:29 -0000 Delivered-To: apmail-jakarta-commons-dev-archive@jakarta.apache.org Received: (qmail 78409 invoked by uid 500); 3 Oct 2003 23:15:29 -0000 Mailing-List: contact commons-dev-help@jakarta.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Subscribe: List-Help: List-Post: List-Id: "Jakarta Commons Developers List" Reply-To: "Jakarta Commons Developers List" Delivered-To: mailing list commons-dev@jakarta.apache.org Received: (qmail 78358 invoked from network); 3 Oct 2003 23:15:28 -0000 Received: from unknown (HELO rhenium.btinternet.com) (194.73.73.93) by daedalus.apache.org with SMTP; 3 Oct 2003 23:15:28 -0000 Received: from host81-128-68-113.in-addr.btopenworld.com ([81.128.68.113] helo=oemcomputer) by rhenium.btinternet.com with smtp (Exim 3.22 #23) id 1A5Z95-0006MN-00; Sat, 04 Oct 2003 00:15:35 +0100 Message-ID: <006901c38a04$d3c967c0$71448051@oemcomputer> From: "Stephen Colebourne" To: "Jakarta Commons Developers List" , References: Subject: Re: [collections] general problem with decorators Date: Sat, 4 Oct 2003 00:19:42 +0100 MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 5.50.4133.2400 X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4133.2400 X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N newInstance is probably best. Although its certainly not a fun job going through all the decorators to add this. Any patch volunteers? Stephen ----- Original Message ----- From: "Todd Jonker" To: "Jakarta Commons Developers List" ; "Jakarta Commons Developers List" Sent: Friday, October 03, 2003 7:07 PM Subject: Re: [collections] general problem with decorators > I like newInstance. Unlike defaultInstance, it clearly allocates a new object. defaultInstance sounds singleton-y. > > .T. > > > -----Original Message----- > > From: __matthewHawthorne [mailto:matth@phreaker.net] > > Sent: Friday, October 3, 2003 01:26 AM > > To: 'Jakarta Commons Developers List' > > Subject: Re: [collections] general problem with decorators > > > > I would prefer something like: > > > > OrderedSet.defaultInstance() > > > > or > > > > OrderedSet.newInstance() > > > > It seems more standard... what do you think? > > > > > > > > > > Stephen Colebourne wrote: > > > This sounds OK, but what would the method be called? > > > > > > OrderedSet.decorate() > > > OrderedSet.decorateHashSet() > > > > > > ? > > > Stephen > > > > > > ----- Original Message ----- > > > From: "Henri Yandell" > > > > > >>Basically, the lack of empty constructors with default decoration > > >>decisions. Example I'm looking at: > > >> > > >>I want an OrderedSet. The only way to get this is: > > >> > > >>OrderedSet.decorate( new HashSet() ) > > >> > > >>[okay, could do TreeSet etc, also could use MapUtils]. > > >> > > >>I don't know about you, but this feels odd. :) Especially as the user > > >>knows that HashSet is unordered, so why provide it. > > >> > > >>This may be a unique example, but it seems that we could choose a default > > >>empty map for each one. > > >> > > >>Just a view.. > > >> > > >>Hen > > >> > > >> > > >>--------------------------------------------------------------------- > > >>To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org > > >>For additional commands, e-mail: commons-dev-help@jakarta.apache.org > > >> > > > > > > > > --------------------------------------------------------------------- > > To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org > > For additional commands, e-mail: commons-dev-help@jakarta.apache.org > > > > > > > > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org > For additional commands, e-mail: commons-dev-help@jakarta.apache.org > --------------------------------------------------------------------- To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org For additional commands, e-mail: commons-dev-help@jakarta.apache.org