Java implementation of contract function
Contract function is function that applied to input value before one is passed to target function. Where target function is function wrapped by Contract one. Target function is not invoked if contract evaluates false.
This code is part my article at medium.com