package rebelsky.list; /** * Things that indicate positions in a list and can move. Cursors * start at the front of the list. * * @author CSC152 2004F */ public class ArrayBasedCursor extends ArrayBasedSimpleCursor implements Cursor { // +--------------+------------------------------------------------------ // | Constructors | // +--------------+ /** * Construct the cursor. */ public ArrayBasedCursor(ArrayBasedSimpleList _list) { super(_list); } // ArrayBasedCursor // +---------+----------------------------------------------------------- // | Methods | // +---------+ /** * Reset the cursor to the front of the list. */ public void toFront() { // STUB } // toFront() /** * Reset the cursor to the rear of the list. */ public void toRear() { // STUB } // toRear() /** * Determine if the cursor is still valid. */ public boolean isValid() { // STUB return true; } // isValid() /** * Get the value "under" the cursor. */ public Object get() { return null; } // get() /** * Retreat the cursor to the previous object and return that * object. * * @pre * Must not be at the front of the ist. */ public Object prev() { // STUB return null; } // reference() /* * Determine if the cursor is at the front of its list. */ public boolean hasPrev() { // STUB return true; } // atFront() } // interface Cursor