Return-Path: Delivered-To: apmail-jakarta-lucene-dev-archive@apache.org Received: (qmail 13784 invoked from network); 5 Dec 2001 18:33:04 -0000 Received: from unknown (HELO nagoya.betaversion.org) (192.18.49.131) by daedalus.apache.org with SMTP; 5 Dec 2001 18:33:04 -0000 Received: (qmail 12077 invoked by uid 97); 5 Dec 2001 18:33:07 -0000 Delivered-To: qmlist-jakarta-archive-lucene-dev@jakarta.apache.org Received: (qmail 12036 invoked by uid 97); 5 Dec 2001 18:33:06 -0000 Mailing-List: contact lucene-dev-help@jakarta.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Subscribe: List-Help: List-Post: List-Id: "Lucene Developers List" Reply-To: "Lucene Developers List" Delivered-To: mailing list lucene-dev@jakarta.apache.org Received: (qmail 12025 invoked from network); 5 Dec 2001 18:33:06 -0000 Message-ID: <4BC270C6AB8AD411AD0B00B0D0493DF0EE7D56@mail.grandcentral.com> From: Doug Cutting To: 'Lucene Developers List' Cc: klicnik@ca.ibm.com Subject: RE: Separating translatable strings Date: Wed, 5 Dec 2001 10:20:10 -0800 MIME-Version: 1.0 X-Mailer: Internet Mail Service (5.5.2653.19) Content-Type: text/plain; charset="iso-8859-1" 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: Otis Gospodnetic [mailto:otis_gospodnetic@yahoo.com] > > I thought this was a nice idea. Is this something others > would like to see? Sure, if it doesn't complicate the code too much. I imagine it would change things like: throw new IOException(bar + " is not bazzed: " + foo); to: throw new IOException(ErrorStrings.format("not.bazzed", new Object[]{bar, foo}); or better yet: throw new LuceneException("not.bazzed", new Object[]{bar, foo}); It would be nice to see a proposal that details the new exception API. In the ideal world, different exception classes would be used for different error conditions. User interfaces could then catch specific exceptions and decide what to do. Unfortunately Lucene's use of exceptions is not so good, and applications end up just displaying error strings directly to users. So translating these error strings is probably useful. Doug -- To unsubscribe, e-mail: For additional commands, e-mail: