Unverified Commit a136fd0d authored by luvarqpp's avatar luvarqpp Committed by GitHub
Browse files

Remove three checked GitLabApiException (#928)

There was not chance of throwing checked exception GitLabApiException  from given three methods. I have removed them to make user code using given methods easier to read.
parent 2483e642
...@@ -255,9 +255,8 @@ public class Pager<T> implements Iterator<List<T>>, Constants { ...@@ -255,9 +255,8 @@ public class Pager<T> implements Iterator<List<T>>, Constants {
* Returns the first page of List. Will rewind the iterator. * Returns the first page of List. Will rewind the iterator.
* *
* @return the first page of List * @return the first page of List
* @throws GitLabApiException if any error occurs
*/ */
public List<T> first() throws GitLabApiException { public List<T> first() {
return (page(1)); return (page(1));
} }
...@@ -280,9 +279,8 @@ public class Pager<T> implements Iterator<List<T>>, Constants { ...@@ -280,9 +279,8 @@ public class Pager<T> implements Iterator<List<T>>, Constants {
* Returns the previous page of List. Will set the iterator to the previous page. * Returns the previous page of List. Will set the iterator to the previous page.
* *
* @return the previous page of List * @return the previous page of List
* @throws GitLabApiException if any error occurs
*/ */
public List<T> previous() throws GitLabApiException { public List<T> previous() {
return (page(currentPage - 1)); return (page(currentPage - 1));
} }
...@@ -290,9 +288,8 @@ public class Pager<T> implements Iterator<List<T>>, Constants { ...@@ -290,9 +288,8 @@ public class Pager<T> implements Iterator<List<T>>, Constants {
* Returns the current page of List. * Returns the current page of List.
* *
* @return the current page of List * @return the current page of List
* @throws GitLabApiException if any error occurs
*/ */
public List<T> current() throws GitLabApiException { public List<T> current() {
return (page(currentPage)); return (page(currentPage));
} }
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment