As far as I know, declaring an interface is like so:
public interface Roots_Squares {
public double square_root( double value );
}
Now... how do you enforce value to have non-negative values? Such a function should avoid negative values right? If someone creates a class that implements this, and that implementation does not handle negative values, and then I use their class with a negative value... well, things break.
It then becomes my responsibility to check for negatives when I'm pretty sure the implementor should do the checking.
Arrays::<@NonNegative Integer>sort
with things such as code.google.com/p/jsr-305/source/browse/trunk/ri/src/main/java/…