Frank Kim wrote:
> 
> I agree that it is a good idea to throw TurbineException because it helps
> differentiate between turbine specific exceptions and other exceptions.  But
> I don't want to have to catch Exceptions within a given method and then cast
> it into a TurbineException.  I think we can leave the method signatures to
> throw plain old Exception and just throw TurbineException (or subclasses of
> it like InvalidPermissionException) within a particular method where
> necessary.  For example, the Loaders could throw TurbineException to make it
> clear that it's a Turbine problem of not being able to find a class.  That
> way Turbine will still catch all exceptions in one place and we'll be able
> to differentiate between Turbine generated exceptions and other exceptions.
> 
> Different applications have different exception handling frameworks and I
> think Turbine's strategy of catching and then logging, displaying, etc all
> exceptions in one place is a good one.
<snip>

Not a cast:

try {
...
} catch(Exception e) {
    throw new TurbineException(e.getMessage()); //or whatever
}

-- 
Kevin A Burton ([EMAIL PROTECTED])
http://relativity.yi.org
Message to SUN:  "Open Source Java!"
"For evil to win is for good men to do nothing."


------------------------------------------------------------
To subscribe:        [EMAIL PROTECTED]
To unsubscribe:      [EMAIL PROTECTED]
Problems?:           [EMAIL PROTECTED]

Reply via email to