Interface ContainerBatchIterator

    • Method Summary

      All Methods Instance Methods Abstract Methods Default Methods 
      Modifier and Type Method Description
      void advanceIfNeeded​(char target)
      Advance until the value.
      ContainerBatchIterator clone()
      Creates a copy of the iterator.
      boolean hasNext()
      Whether the underlying container is exhausted or not
      default int next​(int key, int[] buffer)
      Fills the buffer with values prefixed by the key, and returns how much of the buffer was used.
      int next​(int key, int[] buffer, int offset)
      Fills the buffer with values prefixed by the key, and returns how much of the buffer was used.
      void releaseContainer()
      Discard the reference to the container
    • Method Detail

      • next

        int next​(int key,
                 int[] buffer,
                 int offset)
        Fills the buffer with values prefixed by the key, and returns how much of the buffer was used.
        Parameters:
        key - the prefix of the values
        buffer - the buffer to write values onto
        offset - the offset into the buffer to write values onto
        Returns:
        how many values were written.
      • next

        default int next​(int key,
                         int[] buffer)
        Fills the buffer with values prefixed by the key, and returns how much of the buffer was used.
        Parameters:
        key - the prefix of the values
        buffer - the buffer to write values onto
        Returns:
        how many values were written.
      • hasNext

        boolean hasNext()
        Whether the underlying container is exhausted or not
        Returns:
        true if there is data remaining
      • clone

        ContainerBatchIterator clone()
        Creates a copy of the iterator.
        Returns:
        a clone of the current iterator
      • releaseContainer

        void releaseContainer()
        Discard the reference to the container
      • advanceIfNeeded

        void advanceIfNeeded​(char target)
        Advance until the value.
        Parameters:
        target - the value to advance to.