@Ocramius There are problems with simply munging exceptions. For example, you cannot provide a problemType or additional details easily (really, at all) unless the exception follows specific interfaces (hence the ProblemExceptionInterface). Additionally, I would argue returning an ApiProblem from a controller or a Resource class makes sense -- these are at a layer where knowledge of the domain/request layer makes sense, and doing a try/catch that returns an ApiProblem on detection of an exception makes sense.

There's also already a listener that will cast an exception to an ApiProblem -- but that's already having to make concessions as noted in the previous paragraph.

The solution presented here (and which @bakura10 is not even modifying in this PR) is tested and has had a lot of thought. Basically, if you can come up with a better plan, provide a PR, so we can discuss pros and cons against the current approach.