001 package railo.runtime.type; 002 003 import railo.runtime.exp.PageException; 004 005 /** 006 * Interface for a simple Iterator 007 */ 008 public interface Iterator { 009 010 /** 011 * set the intern pointer of the iterator to the next position, 012 * return true if next position exist otherwise false. 013 * @return boolean 014 * @throws PageException 015 * @deprecated use instead <code>{@link #next(int)}</code> 016 */ 017 public boolean next()throws PageException; 018 019 /** 020 * set the intern pointer of the iterator to the next position, 021 * return true if next position exist otherwise false. 022 * @return boolean 023 * @throws PageException 024 */ 025 public boolean next(int pid)throws PageException; 026 027 /** 028 * reset ther intern pointer 029 * @throws PageException 030 * @deprecated use instead <code>{@link #reset(int)}</code> 031 */ 032 public void reset()throws PageException; 033 034 /** 035 * 036 * reset ther intern pointer 037 * @throws PageException 038 */ 039 public void reset(int pid)throws PageException; 040 041 /** 042 * return recordcount of the iterator object 043 * @return int 044 */ 045 public int getRecordcount(); 046 047 /** 048 * return the current position of the internal pointer 049 * @return int 050 * 051 */ 052 // @deprecated use instead getCurrentrow(int pageContextId) 053 public int getCurrentrow(); 054 055 /** 056 * set the internal pointer to defined position 057 * @param index 058 * @return int 059 * @throws PageException 060 * @deprecated use instead <code>{@link #go(int,int)}</code> 061 */ 062 public boolean go(int index)throws PageException; 063 064 /** 065 * 066 * set the internal pointer to defined position 067 * @param index 068 * @return int 069 * @throws PageException 070 */ 071 public boolean go(int index, int pid)throws PageException; 072 073 /** 074 * @return returns if iterator is empty or not 075 */ 076 public boolean isEmpty(); 077 078 //public ArrayList column(String strColumn)throws PageException; 079 080 //public String[] row(int number); 081 }