On 12.06.2012, at 15:01, Julian Reschke wrote:

> Is this just to avoid catching exceptions? (keep in mind that the 
> exception might be thrown anyway...)

No, if hasProperty() returns true, you don't expect the PathNotFoundEx and 
don't have to handle it for the purpose of semantics! There is no 
catch(PathNotFoundEx) in the code you quote :-)

You only have to handle the RepositoryException, which can then be seen as 
unrecoverable error condition (and is usually passed through and handled at a 
more generic layer in application code).

Cheers,
Alex

Reply via email to