Simple stupid assertion framework for java.
public void order(Customer customer) {
Assert.notNull (customer);
Assert.notBlank(customer.getId());
Assert.notBlank(customer.getToken());
Assert.notEmpty(customer.getOrders());
orderService.order(customer)
}
- nullsafe
- Exceptiontype: IllegalArgumentException
- notNull
- Object
- notBlank
- String
- notEmpty
- String
- Collection
- Iterator
- notTrue
- Boolean
- notFalse
- Boolean