diff --git a/src/main/java/org/kohsuke/github/GHRepository.java b/src/main/java/org/kohsuke/github/GHRepository.java
index c5ddd443e..e3fbc8cea 100644
--- a/src/main/java/org/kohsuke/github/GHRepository.java
+++ b/src/main/java/org/kohsuke/github/GHRepository.java
@@ -2967,12 +2967,15 @@ public class GHRepository extends GHObject {
/**
* Streams a zip archive of the repository, optionally at a given ref.
*
+ * @param
+ * the type of result
* @param streamFunction
* The {@link InputStreamFunction} that will process the stream
* @param ref
* if null the repository's default branch, usually master,
* @throws IOException
* The IO exception.
+ * @return the result of reading the stream.
*/
public T readZip(InputStreamFunction streamFunction, String ref) throws IOException {
return downloadArchive("zip", ref, streamFunction);
@@ -2981,19 +2984,23 @@ public class GHRepository extends GHObject {
/**
* Streams a tar archive of the repository, optionally at a given ref.
*
+ * @param
+ * the type of result
* @param streamFunction
* The {@link InputStreamFunction} that will process the stream
* @param ref
* if null the repository's default branch, usually master,
* @throws IOException
* The IO exception.
+ * @return the result of reading the stream.
*/
public T readTar(InputStreamFunction streamFunction, String ref) throws IOException {
return downloadArchive("tar", ref, streamFunction);
}
- private T downloadArchive(@Nonnull String type, @CheckForNull String ref, @Nonnull InputStreamFunction streamFunction)
- throws IOException {
+ private T downloadArchive(@Nonnull String type,
+ @CheckForNull String ref,
+ @Nonnull InputStreamFunction streamFunction) throws IOException {
requireNonNull(streamFunction, "Sink must not be null");
String tailUrl = getApiTailUrl(type + "ball");
if (ref != null) {
diff --git a/src/main/java/org/kohsuke/github/function/FunctionThrows.java b/src/main/java/org/kohsuke/github/function/FunctionThrows.java
index bfa5d6619..cb23cc577 100644
--- a/src/main/java/org/kohsuke/github/function/FunctionThrows.java
+++ b/src/main/java/org/kohsuke/github/function/FunctionThrows.java
@@ -2,8 +2,24 @@ package org.kohsuke.github.function;
/**
* A functional interface, equivalent to {@link java.util.function.Function} but that allows throwing {@link Throwable}
+ *
+ * @param
+ * the type of input
+ * @param
+ * the type of output
+ * @param
+ * the type of error
*/
@FunctionalInterface
public interface FunctionThrows {
+ /**
+ * Apply r.
+ *
+ * @param input
+ * the input
+ * @return the r
+ * @throws E
+ * the e
+ */
R apply(T input) throws E;
}
diff --git a/src/main/java/org/kohsuke/github/function/InputStreamFunction.java b/src/main/java/org/kohsuke/github/function/InputStreamFunction.java
index ff342097d..efad6fcd1 100644
--- a/src/main/java/org/kohsuke/github/function/InputStreamFunction.java
+++ b/src/main/java/org/kohsuke/github/function/InputStreamFunction.java
@@ -6,6 +6,8 @@ import java.io.InputStream;
/**
* A functional interface, equivalent to {@link java.util.function.Function} but that allows throwing {@link Throwable}
*
+ * @param
+ * the type to of object to be returned
*/
@FunctionalInterface
public interface InputStreamFunction extends FunctionThrows {