Return-Path: Delivered-To: apmail-jakarta-commons-dev-archive@apache.org Received: (qmail 45817 invoked from network); 21 Dec 2002 19:53:36 -0000 Received: from exchange.sun.com (192.18.33.10) by daedalus.apache.org with SMTP; 21 Dec 2002 19:53:36 -0000 Received: (qmail 26571 invoked by uid 97); 21 Dec 2002 19:54:49 -0000 Delivered-To: qmlist-jakarta-archive-commons-dev@jakarta.apache.org Received: (qmail 26554 invoked by uid 97); 21 Dec 2002 19:54:48 -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 26541 invoked by uid 50); 21 Dec 2002 19:54:48 -0000 Date: 21 Dec 2002 19:54:48 -0000 Message-ID: <20021221195448.26537.qmail@nagoya.betaversion.org> From: bugzilla@apache.org To: commons-dev@jakarta.apache.org Cc: Subject: DO NOT REPLY [Bug 14170] - ConvertUtils.convert(Object) doesn't use registered convertor X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT . ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND INSERTED IN THE BUG DATABASE. http://nagoya.apache.org/bugzilla/show_bug.cgi?id=14170 ConvertUtils.convert(Object) doesn't use registered convertor craig.mcclanahan@sun.com changed: What |Removed |Added ---------------------------------------------------------------------------- Status|ASSIGNED |RESOLVED Resolution| |FIXED ------- Additional Comments From craig.mcclanahan@sun.com 2002-12-21 19:54 ------- I've implemented a partial solution to this problem, which should allow applications to do custom Object->String conversions without impacting the rest of how beanutils conversions work. It is available in the 20021222 nightly build of commons-beanutils. The basic idea is that the "ConvertUtils.convert(Object value)" method now uses the registered Converter for java.util.String. The default implementation of this Converter uses toString() -- preserving backwards compatibility -- but you can register something that is smarter for your own needs. The drawback is that this single Object->String converter needs to be smart enough to handle *all* of these conversions, not just your custom ones. A longer term solution would be to move towards bidirectional converters of some sort. But let's see if this change satisfies the immediate needs. Could you test it, please? -- To unsubscribe, e-mail: For additional commands, e-mail: