Klasse QueryIterator<T>

java.lang.Object
de.caluga.morphium.query.QueryIterator<T>
Alle implementierten Schnittstellen:
MorphiumIterator<T>, Iterable<T>, Iterator<T>

public class QueryIterator<T> extends Object implements MorphiumIterator<T>, Iterator<T>, Iterable<T>
User: Stephan Bösebeck Date: 25.03.16 Time: 22:33

iterating over huge collections using the mongodb internal cursor

  • Konstruktordetails

    • QueryIterator

      public QueryIterator()
  • Methodendetails

    • getWindowSize

      public int getWindowSize()
    • setWindowSize

      public QueryIterator<T> setWindowSize(int windowSize)
    • getQuery

      public Query<T> getQuery()
    • setQuery

      public void setQuery(Query<T> q)
    • getCount

      public long getCount()
    • ahead

      public void ahead(int jump)
      Beschreibung aus Schnittstelle kopiert: MorphiumIterator
      move the cursor position ahead
      Angegeben von:
      ahead in Schnittstelle MorphiumIterator<T>
      Parameter:
      jump - number of elements to jump
    • back

      public void back(int jump)
      Beschreibung aus Schnittstelle kopiert: MorphiumIterator
      get back some positions
      Angegeben von:
      back in Schnittstelle MorphiumIterator<T>
      Parameter:
      jump - number of elements to jump back
    • available

      public int available()
      Beschreibung aus Schnittstelle kopiert: MorphiumIterator
      retruns the number of elements now in buffer. Max windowsize
      Angegeben von:
      available in Schnittstelle MorphiumIterator<T>
      Gibt zurück:
      list
    • iterator

      public Iterator<T> iterator()
      Angegeben von:
      iterator in Schnittstelle Iterable<T>
    • hasNext

      public boolean hasNext()
      Angegeben von:
      hasNext in Schnittstelle Iterator<T>
    • nextMap

      public Map<String,Object> nextMap()
      Angegeben von:
      nextMap in Schnittstelle MorphiumIterator<T>
    • next

      public T next()
      Angegeben von:
      next in Schnittstelle Iterator<T>
    • getCurrentBuffer

      public List<T> getCurrentBuffer()
      Beschreibung aus Schnittstelle kopiert: MorphiumIterator
      get the current buffer. Maximum length is specified windowsize
      Angegeben von:
      getCurrentBuffer in Schnittstelle MorphiumIterator<T>
      Gibt zurück:
      list
    • close

      public void close()
      Angegeben von:
      close in Schnittstelle MorphiumIterator<T>
    • getCursor

      public int getCursor()
      Beschreibung aus Schnittstelle kopiert: MorphiumIterator
      returns current cursor position
      Angegeben von:
      getCursor in Schnittstelle MorphiumIterator<T>
      Gibt zurück:
      int
    • getMongoCursor

      public MorphiumCursor getMongoCursor()