Class AResultImpl

java.lang.Object
org.opencastproject.assetmanager.impl.query.AResultImpl
All Implemented Interfaces:
Iterable<ARecord>, AResult

public final class AResultImpl extends Object implements AResult
  • Constructor Details

    • AResultImpl

      public AResultImpl(LinkedHashSet<ARecord> records, long size, long offset, long limit, long searchTime)
  • Method Details

    • iterator

      public Iterator<ARecord> iterator()
      Specified by:
      iterator in interface Iterable<ARecord>
    • getRecords

      public LinkedHashSet<ARecord> getRecords()
      Description copied from interface: AResult
      Return the found records.
      Specified by:
      getRecords in interface AResult
    • getSize

      public long getSize()
      Description copied from interface: AResult
      Return the size of the retrieved slice. This value is <= AResult.getLimit().
      Specified by:
      getSize in interface AResult
      See Also:
    • getQuery

      public String getQuery()
      Description copied from interface: AResult
      Return a string representation of the query.
      Specified by:
      getQuery in interface AResult
    • getTotalSize

      public long getTotalSize()
      Description copied from interface: AResult
      Return the number of items the query could potentially yield.
      Specified by:
      getTotalSize in interface AResult
      Returns:
      the total value or -1 to indicate that the value has not been calculated
    • getLimit

      public long getLimit()
      Description copied from interface: AResult
      Return the set's size limit. It reflects the requested page size if specified in the query. This value is >= AResult.getSize().
      Specified by:
      getLimit in interface AResult
      Returns:
      the requested size limit or -1 if none has been specified
      See Also:
    • getOffset

      public long getOffset()
      Description copied from interface: AResult
      Return the offset within the total result set.
      Specified by:
      getOffset in interface AResult
    • getSearchTime

      public long getSearchTime()
      Description copied from interface: AResult
      Return the search time of the query.
      Specified by:
      getSearchTime in interface AResult
      Returns:
      the search time or -1 to indicate that it has not been measured