Return-Path: Delivered-To: apmail-jakarta-commons-dev-archive@apache.org Received: (qmail 27154 invoked from network); 17 Jan 2003 14:59:25 -0000 Received: from exchange.sun.com (192.18.33.10) by daedalus.apache.org with SMTP; 17 Jan 2003 14:59:24 -0000 Received: (qmail 8932 invoked by uid 97); 17 Jan 2003 13:52:49 -0000 Delivered-To: qmlist-jakarta-archive-commons-dev@jakarta.apache.org Received: (qmail 26971 invoked by uid 97); 17 Jan 2003 13:46:58 -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 1496 invoked by uid 50); 16 Jan 2003 23:47:18 -0000 Date: 16 Jan 2003 23:47:18 -0000 Message-ID: <20030116234718.1495.qmail@nagoya.betaversion.org> From: bugzilla@apache.org To: commons-dev@jakarta.apache.org Cc: Subject: DO NOT REPLY [Bug 13367] - StringUtil enhancement 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=13367 StringUtil enhancement ------- Additional Comments From tvj@pobox.com 2003-01-16 23:47 ------- Note that the docs for trim do NOT specify that trim("") == null What's really missing is my most-used utility method: clean(str, defaultValue) which returns defaultValue if str is null or becomes null after trimming. Kinda like defaltString(trim(str), defaultValue) but much easier to type. Also, how does strip differ from these? Just in its handling of control characters? The docs on all these are vague. It also seems like some refactoring would be appropriate to get the desired functionality. Personally, I find it hard to remember the difference between trim and clean without looking at the javadocs. -- To unsubscribe, e-mail: For additional commands, e-mail: