Use Precondititions.checkNotNull.