agg package: add @ParametersAreNonnullByDefault

And remove all the function-specific @Nonnull parameters, and add a few
missing @Nullable.

This is a much more principled way to indicate when parameters are
@Nullable.
PrimitiveAggregators: compute needsX once at construction

Rather than checking every tuple / tuplebatch.