On Wed, Sep 22, 2010 at 2:23 AM, Kevin Wright <[email protected]>wrote:

> Which begs the question... Is a flaky shared drive a common enough (and
> recoverable enough) situation that it justifies forcing all API users to
> make an explicit check for the condition with each and every function call
> that manipulates files?


No, which is why your idea of using Either as a return code is bad and why
exceptions are the correct way to handle this (install a handler as high in
the stack frame as possible so that code lower down can just happily ignore
the fact that the calls they make can throw an exception).

-- 
Cédric

-- 
You received this message because you are subscribed to the Google Groups "The 
Java Posse" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/javaposse?hl=en.

Reply via email to