Path: csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!feeder.erje.net!eu.feeder.erje.net!fu-berlin.de!uni-berlin.de!individual.net!not-for-mail From: Robert Klemme Newsgroups: comp.lang.java.programmer Subject: Re: About java program. Date: Sun, 07 Jul 2013 20:43:44 +0200 Lines: 23 Message-ID: References: <324f929f-772e-4004-81e1-6b454cdae794@googlegroups.com> <19wnriq53qxel.u9rt8wy6z52g.dlg@40tude.net> <1lvu4yv8sxe73$.n4o05ixuag9y.dlg@40tude.net> <85GdncWZdo04-lzMnZ2dnUVZ8mydnZ2d@bt.com> <51d6396c$0$295$14726298@news.sunsite.dk> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Trace: individual.net gaB5H6xV1VuNB9feI7xi0QM2DGnzIj4IEROC1/4vj75w9OcfI= Cancel-Lock: sha1:/Qr3rpTHvA5qrmpz7RU6/rIU5yw= User-Agent: Mozilla/5.0 (Windows NT 6.0; WOW64; rv:17.0) Gecko/20130620 Thunderbird/17.0.7 In-Reply-To: X-Antivirus: avast! (VPS 130707-1, 07.07.2013), Outbound message X-Antivirus-Status: Clean Xref: csiph.com comp.lang.java.programmer:24692 On 06.07.2013 14:22, Eric Sosman wrote: > On 7/6/2013 7:14 AM, Robert Klemme wrote: >> [...] >> Well, you can forget the logging on *any* level of the application. >> There is no really a difference between asking the author of this method >> to do proper error handling or asking the author of some other code to >> do it. > > The caller has more context. When Integer.parseInt() is > unable to make sense of the input string, it has no way of knowing > whether the failure is fatal, unusual, or expected. Do you think > it should log all such failures in addition to throwing up? No. That is exactly my point. Cheers robert -- remember.guy do |as, often| as.you_can - without end http://blog.rubybestpractices.com/