Class CredentialResult<T extends AccessCredential>

java.lang.Object
com.inrupt.client.accessgrant.CredentialResult<T>
Type Parameters:
T - the access credential type

public class CredentialResult<T extends AccessCredential> extends Object
A page-able result from a credential query.
  • Constructor Details

    • CredentialResult

      public CredentialResult(List<T> items, CredentialFilter<T> first, CredentialFilter<T> prev, CredentialFilter<T> next, CredentialFilter<T> last)
      A page of access credential results.
      Parameters:
      items - the result items
      first - a filter for the first page of results, may be null
      prev - a filter for the previous page of results, may be null
      next - a filter for the next page of results, may be null
      last - a filter for the last page of results, may be null
  • Method Details

    • firstPage

      public Optional<CredentialFilter<T>> firstPage()
      Get a filter for the first page of results.
      Returns:
      the first page filter, if present
    • prevPage

      public Optional<CredentialFilter<T>> prevPage()
      Get a filter for the previous page of results.
      Returns:
      the previous page filter, if present
    • nextPage

      public Optional<CredentialFilter<T>> nextPage()
      Get a filter for the next page of results.
      Returns:
      the next page filter, if present
    • lastPage

      public Optional<CredentialFilter<T>> lastPage()
      Get a filter for the last page of results.
      Returns:
      the last page filter, if present
    • getItems

      public List<T> getItems()
      Get the credential items in the result page.
      Returns:
      the credential items