org.openrdf.sesame.sail.util
Class EmptyStatementIterator

java.lang.Object
  extended byorg.openrdf.sesame.sail.util.EmptyStatementIterator
All Implemented Interfaces:
StatementIterator

public class EmptyStatementIterator
extends Object
implements StatementIterator

A StatementIterator that contains exactly zero statements.

Version:
$Revision: 1.4.4.2 $

Constructor Summary
EmptyStatementIterator()
          Creates an EmptyStatementIterator.
 
Method Summary
 void close()
          Closes the iterator and frees any resources that it uses (e.g.
 Value getObject()
          Deprecated. Replaced by Statement.getObject().
 Resource getPredicate()
          Deprecated. Replaced by Statement.getPredicate().
 Resource getSubject()
          Deprecated. Replaced by Statement.getSubject().
 boolean hasNext()
          Always return false;
 Statement next()
          Always throws a NoSuchElementException as there are no results in an EmptyStatementIterator.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

EmptyStatementIterator

public EmptyStatementIterator()
Creates an EmptyStatementIterator.

Method Detail

hasNext

public boolean hasNext()
Always return false;

Specified by:
hasNext in interface StatementIterator
Returns:
true if there are more statements available, false otherwise.

next

public Statement next()
Always throws a NoSuchElementException as there are no results in an EmptyStatementIterator.

Specified by:
next in interface StatementIterator
Returns:
the next statement.
Throws:
NoSuchElementException - Is always thrown.

getSubject

public Resource getSubject()
Deprecated. Replaced by Statement.getSubject().

Always returns null.


getPredicate

public Resource getPredicate()
Deprecated. Replaced by Statement.getPredicate().

Always returns null.


getObject

public Value getObject()
Deprecated. Replaced by Statement.getObject().

Always returns null.


close

public void close()
Description copied from interface: StatementIterator
Closes the iterator and frees any resources that it uses (e.g. connections to databases). Every StatementIterator should be properly closed when it has returned all of its statements, or when it is no longer needed.

Specified by:
close in interface StatementIterator


Copyright © 2002-2006 Aduna BV, GNU LGPL License applies.