Changes between Version 5 and Version 6 of GeoNetworkException


Ignore:
Timestamp:
Dec 1, 2008, 12:43:05 PM (16 years ago)
Author:
erikvaningen
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • GeoNetworkException

    v5 v6  
    2020Heikki: -1. When was option 1 chosen and by whom ?? In my opinion throwing !RuntimeExceptions as a default strategy for exception handling does not make any sense. Also I do not think that try-catch blocks 'dirty' the code. Throwing !RuntimeException is a bit like avoiding strong typing by using ony java.lang.Object as parameter type; or like the current practice in GeoNetwork not to model an object domain, but do everything with JDOM Elements. Also what will we do if a !RuntimeException occurs: let the JVM exit?? I think not; this means we'll catch them somewhere in any case.
    2121
     22Erik: +1. Since I like the minimalistic approach I prefer 1. Another advantage is that you have always the choice to catch the exception. In this project does it mean that the exception will be catched in the service layer. In all other layers you don't see boilerplate code, only code which makes sense.