Return-Path: Delivered-To: apmail-jakarta-commons-dev-archive@apache.org Received: (qmail 45503 invoked from network); 29 Oct 2002 23:35:21 -0000 Received: from unknown (HELO nagoya.betaversion.org) (192.18.49.131) by daedalus.apache.org with SMTP; 29 Oct 2002 23:35:21 -0000 Received: (qmail 14110 invoked by uid 97); 29 Oct 2002 23:34:38 -0000 Delivered-To: qmlist-jakarta-archive-commons-dev@jakarta.apache.org Received: (qmail 13979 invoked by uid 97); 29 Oct 2002 23:34:37 -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 13891 invoked by uid 98); 29 Oct 2002 23:34:36 -0000 X-Antivirus: nagoya (v4218 created Aug 14 2002) Message-ID: <009b01c27fa3$ae3c9d40$c72229d9@oemcomputer> From: "Stephen Colebourne" To: "Jakarta Commons Developers List" References: <010101c27ee6$f98954e0$6d4029d9@oemcomputer> <053201c27ee9$b375b270$0200a8c0@GATEWAY> Subject: Re: [clazz] Accessing the properties Date: Tue, 29 Oct 2002 23:34:09 -0000 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: daedalus.apache.org 1.6.2 0/1000/N From: "Dmitri Plotnikov" > From: "Stephen Colebourne" > > I think the key to all APIs like this is to re-use what Java offers, and > > thats the collections API in this case. > It would indeed be very appealing to re-use the Java collections interfaces. > > However, I'll have to be honest with you. I must be old-fashioned, but the > allocation of all these wrappers bothers me. I have noticed that wrappers > have become quite fashionable lately (e.g. WrapDynaBean), but I am still not > convinced that allocating all these stateless objects is worth the literal > reuse of standard interfaces. > > Also, I am not convinced that we need interfaces as wide as those of > Collections. The implementation of those APIs can be quite an effort, > especially in the case where the target object is a Java bean, not a > DynaBean. We then have to map all these APIs to some methods on the bean. I'm not opposed to adding some methods onto the main object to bypass the need to create the wrapper. Thus a get method would be on the main object for example. However, I find that once you get into the depths of defining an add/set/put/remove etc. method, then you should in fact just be exposing the Map/List. Part of the effort of [clazz] will be implementing suitable Maps/Lists. This may involve adding to [collections]. Stephen -- To unsubscribe, e-mail: For additional commands, e-mail: