1 dojo.provide("calitha.collections.IIterator"); 2 dojo.require("calitha.exception.VirtualFunctionException"); 3 4 /** 5 * @name calitha.collections.IIterator 6 * @class An iterator over a collection. 7 * <p> 8 * It is based on the 9 * <a href="http://java.sun.com/javase/6/docs/api/java/util/Iterator.html">Java Iterator interface</a>. 10 */ 11 dojo.declare("calitha.collections.IIterator", null, 12 /** @lends calitha.collections.IIterator# */ 13 { 14 /** 15 * @function 16 * @returns {Boolean} true if the iterator has more elements. 17 * @description Returns true if the iteration has more elements. 18 */ 19 hasNext: function() 20 {throw new calitha.exception.VirtualFunctionException(Error());} 21 , 22 /** 23 * @function 24 * @returns {Object} the next element in the iteration. 25 * @description Returns the next element in the iteration. 26 */ 27 next: function() 28 {throw new calitha.exception.VirtualFunctionException(Error());} 29 , 30 /** 31 * @function 32 * @description Removes from the underlying collection the last element returned by the iterator. 33 */ 34 remove: function() 35 {throw new calitha.exception.VirtualFunctionException(Error());} 36 }); 37