org.bitrepository.audittrails.store
Class AuditEventIterator

java.lang.Object
  extended by org.bitrepository.audittrails.store.AuditEventIterator

public class AuditEventIterator
extends Object

Class to iterate over the set of AuditTrailEvents produced by a resultset.


Constructor Summary
AuditEventIterator(PreparedStatement ps)
           
 
Method Summary
 void close()
          Method to explicitly close the ResultSet in the AuditEventIterator
 AuditTrailEvent getNextAuditTrailEvent()
          Method to return the next AuditTrailEvent in the ResultSet When no more AuditTrailEvents are available, null is returned and the internal ResultSet closed.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AuditEventIterator

public AuditEventIterator(PreparedStatement ps)
Parameters:
ps - The prepare statement to execute and iterate over.
Method Detail

close

public void close()
           throws SQLException
Method to explicitly close the ResultSet in the AuditEventIterator

Throws:
SQLException - in case of a sql error

getNextAuditTrailEvent

public AuditTrailEvent getNextAuditTrailEvent()
Method to return the next AuditTrailEvent in the ResultSet When no more AuditTrailEvents are available, null is returned and the internal ResultSet closed.

Returns:
The next AuditTrailEvent available in the ResultSet, or null if no more events are available.
Throws:
SQLException - In case of a sql error.


Copyright © 2010-2013 The State and University Library, The Royal Library and The State Archives, Denmark. All Rights Reserved.