org.datanucleus.store.mapped.scostore
Class ListStoreIterator

java.lang.Object
  extended by org.datanucleus.store.mapped.scostore.ListStoreIterator
All Implemented Interfaces:
java.util.Iterator, java.util.ListIterator

public abstract class ListStoreIterator
extends java.lang.Object
implements java.util.ListIterator

Abstract iterator for presenting the results for a list store.


Constructor Summary
ListStoreIterator(ObjectProvider sm, java.lang.Object resultSet, ResultObjectFactory rof, AbstractListStore als)
          Constructor
 
Method Summary
 void add(java.lang.Object o)
           
protected abstract  AbstractMemberMetaData getOwnerMemberMetaData(DatastoreContainerObject containerTable)
          Method to return the owner member metadata for the supplied table
 boolean hasNext()
           
 boolean hasPrevious()
           
 java.lang.Object next()
           
protected abstract  boolean next(java.lang.Object resultSet)
          Method to move to the next row in the results.
 int nextIndex()
           
 java.lang.Object previous()
           
 int previousIndex()
           
 void remove()
           
 void set(java.lang.Object o)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ListStoreIterator

public ListStoreIterator(ObjectProvider sm,
                         java.lang.Object resultSet,
                         ResultObjectFactory rof,
                         AbstractListStore als)
                  throws MappedDatastoreException
Constructor

Parameters:
sm - the StateManager
resultSet - the ResultSet
rof - the Query.ResultObjectFactory
Throws:
java.sql.SQLException
MappedDatastoreException
Method Detail

add

public void add(java.lang.Object o)
Specified by:
add in interface java.util.ListIterator

hasNext

public boolean hasNext()
Specified by:
hasNext in interface java.util.Iterator
Specified by:
hasNext in interface java.util.ListIterator

hasPrevious

public boolean hasPrevious()
Specified by:
hasPrevious in interface java.util.ListIterator

next

public java.lang.Object next()
Specified by:
next in interface java.util.Iterator
Specified by:
next in interface java.util.ListIterator

nextIndex

public int nextIndex()
Specified by:
nextIndex in interface java.util.ListIterator

previous

public java.lang.Object previous()
Specified by:
previous in interface java.util.ListIterator

previousIndex

public int previousIndex()
Specified by:
previousIndex in interface java.util.ListIterator

remove

public void remove()
Specified by:
remove in interface java.util.Iterator
Specified by:
remove in interface java.util.ListIterator

set

public void set(java.lang.Object o)
Specified by:
set in interface java.util.ListIterator

next

protected abstract boolean next(java.lang.Object resultSet)
                         throws MappedDatastoreException
Method to move to the next row in the results.

Parameters:
resultSet - The result set
Returns:
Whether there is a next row
Throws:
MappedDatastoreException

getOwnerMemberMetaData

protected abstract AbstractMemberMetaData getOwnerMemberMetaData(DatastoreContainerObject containerTable)
Method to return the owner member metadata for the supplied table

Parameters:
containerTable - The table for the list
Returns:
the metadata for the owner member


Copyright © 2011. All Rights Reserved.