The @Nullable annotation is a good way of positively identifying that a
parameter may be null. The converse may in fact be more useful - specifying
that a parameter *may not* be null.
Aside from adding to the documentary benefit that @Nullable provides,
@NonNullable could be used to actively check the precondition that the
parameter it marks is non-null, using AOP. This would be a neat way of
checking this precondition, without having to directly run the
Preconditions#checkNotNull(T) check as the first line of the method.
Original issue reported on code.google.com by joe.kear...@gtempaccount.com on 27 Feb 2008 at 2:11
Original issue reported on code.google.com by
joe.kear...@gtempaccount.com
on 27 Feb 2008 at 2:11