I personally believe that the DbC libraries currently available left something to be desired, and none of the libraries I looked at played well with the Bean Validation API.
The libraries I looked at have been documented here
There are many crossroads with DbC concepts in the Bean API for validation. In some cases, the Bean Validation API cannot be used as a simple POJO (Code Driven without CDI). The IMO wrapper around the Bean Validation API should be sufficient.
I found that existing libraries are a bit complicated to add to existing web projects, given that they are implemented either with AOP or with byte code tools. Probably, with the advent of the Bean API, verification of such complexity for the implementation of DbC is unreasonable.
I also documented my rant in this post and hope to build a small library that uses the Bean validation API
Sudarshan Sep 10 '13 at 16:11 2013-09-10 16:11
source share