Class DatabaseCursor


  • public class DatabaseCursor
    extends java.lang.Object
    DatabaseCursor class Show database position of request response
    • Constructor Detail

      • DatabaseCursor

        protected DatabaseCursor()
        For Json
      • DatabaseCursor

        public DatabaseCursor​(long total,
                              long offset,
                              long limit)
        DatabaseCursor constructor
        Parameters:
        total - total of inserted/modified/selected items
        offset - the offset of items in database
        limit - number limit of items per response
      • DatabaseCursor

        public DatabaseCursor​(long total,
                              long offset,
                              long limit,
                              long size)
        DatabaseCursor constructor
        Parameters:
        total - total of inserted/modified/selected items
        offset - the offset of items in database
        limit - number limit of items per response
        size - size of the current response
      • DatabaseCursor

        public DatabaseCursor​(long total,
                              long offset,
                              long limit,
                              long size,
                              java.lang.String scrollId)
        DatabaseCursor constructor
        Parameters:
        total - total of inserted/modified/selected items
        offset - the offset of items in database
        limit - number limit of items per response
        size - size of the current response
        scrollId - cursorId of the current response
    • Method Detail

      • getTotal

        public long getTotal()
        Returns:
        the total of units inserted/modified/selected as potential total response size (beyond current limit)
      • setTotal

        public DatabaseCursor setTotal​(long total)
        Parameters:
        total - of units as integer
        Returns:
        the DatabaseCursor with the total is setted
      • getOffset

        public long getOffset()
        Returns:
        the offset of units in database
      • setOffset

        public DatabaseCursor setOffset​(long offset)
        Parameters:
        offset - the offset of units in database
        Returns:
        the DatabaseCursor with the offset is setted
      • getLimit

        public long getLimit()
        Returns:
        the limit of units per response
      • setLimit

        public DatabaseCursor setLimit​(long limit)
        Parameters:
        limit - limit of units as integer
        Returns:
        the DatabaseCursor with the limits of units is setted
      • getSize

        public long getSize()
        Returns:
        the size as current response size
      • setSize

        public DatabaseCursor setSize​(long size)
        Parameters:
        size - the size as current response size
        Returns:
        this
      • getScrollId

        public java.lang.String getScrollId()
        Returns:
        the scrollId as current response size
      • setScrollId

        public DatabaseCursor setScrollId​(java.lang.String scrollId)
        Parameters:
        scrollId - the cursorId as current response size
        Returns:
        this