Class OffsetLimit


  • public class OffsetLimit
    extends Object
    • Field Detail

      • offset

        protected final long offset
      • limit

        protected final long limit
    • Constructor Detail

      • OffsetLimit

        public OffsetLimit​(long offset,
                           long limit)
    • Method Detail

      • getOffset

        public long getOffset()
      • getLimit

        public long getLimit()
      • isPresent

        public boolean isPresent()
      • hasOffset

        public boolean hasOffset()
      • hasLimit

        public boolean hasLimit()
      • limit

        public static OffsetLimit limit​(int limit2)
      • getLimitOrMax

        public long getLimitOrMax()
      • hashCode

        public final int hashCode()
        Overrides:
        hashCode in class Object
      • getFromIndex

        public long getFromIndex​(long maxIndex)
        Returns the first row index to fetch.
        Parameters:
        maxIndex - maximal index accessible
      • getToIndex

        public long getToIndex​(long maxIndex)
        Returns the last row index to fetch (non-inclusive).
        Parameters:
        maxIndex - maximal index accessible