edu.upc.dama.dex.core
Class Values

java.lang.Object
  extended by edu.upc.dama.dex.core.Values
All Implemented Interfaces:
java.io.Closeable, java.util.Iterator

public class Values
extends java.lang.Object
implements java.util.Iterator, java.io.Closeable

Value collection iterator. It is possible to get an ascending or descending Value collection iterator.

See Also:
Graph.getValues(long, short), Graph.ORDER_ASCENDENT, Graph.ORDER_DESCENDENT, Value
Author:
Sparsity Technologies

Method Summary
 void close()
          Closes the collection.
 boolean hasNext()
          Gets whether there are more Values into the collection.
 Value next()
          Gets the next Value into the collection and moves forward the iterator.
 void remove()
          Unsupported operation.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

hasNext

public boolean hasNext()
Gets whether there are more Values into the collection.

Specified by:
hasNext in interface java.util.Iterator
Returns:
true if there is at least another Value into the collection, false otherwise.

next

public Value next()
Gets the next Value into the collection and moves forward the iterator.

Specified by:
next in interface java.util.Iterator
Returns:
The next Value.

remove

public void remove()
Unsupported operation.

Specified by:
remove in interface java.util.Iterator

close

public void close()
Closes the collection.

It is important to close Values as soon as possible to free its memory resources.

Specified by:
close in interface java.io.Closeable