FieldDef: Mark Getter#get as nullable
Change-Id: I6bb474883e2657aaa8effcc5600681426a484dcf
diff --git a/java/com/google/gerrit/index/FieldDef.java b/java/com/google/gerrit/index/FieldDef.java
index beb9c07..f565e52 100644
--- a/java/com/google/gerrit/index/FieldDef.java
+++ b/java/com/google/gerrit/index/FieldDef.java
@@ -18,6 +18,7 @@
import static java.util.Objects.requireNonNull;
import com.google.common.base.CharMatcher;
+import com.google.gerrit.common.Nullable;
import com.google.gwtorm.server.OrmException;
import java.io.IOException;
import java.sql.Timestamp;
@@ -60,6 +61,7 @@
@FunctionalInterface
public interface Getter<I, T> {
+ @Nullable
T get(I input) throws OrmException, IOException;
}
@@ -133,6 +135,7 @@
* @return the field value(s) to index.
* @throws OrmException
*/
+ @Nullable
public T get(I input) throws OrmException {
try {
return getter.get(input);