Code example for CursorIndexOutOfBoundsException

0
         *  values 
         * @return this builder to support chaining 
         */ 
        public RowBuilder add(Object columnValue) {
            if (index == endIndex) {
                throw new CursorIndexOutOfBoundsException(
                        "No more columns left."); 
            } 
 
            data[index++] = columnValue;
            return this;
        } 
    } 
 
    public void set(int column, Object value) {
        if (column < 0 || column >= columnCount) {
            throw new CursorIndexOutOfBoundsException("Requested column: "
                    + column + ", # of columns: " +  columnCount);
        } 
        if (mPos < 0) {
            throw new CursorIndexOutOfBoundsException("Before first row.");