SwatDB/SwatDBRecordsetWrapper.php
public function key()
    {
        if (
            $this->index_field !== null &&
            isset($this->current()->{$this->index_field})
        ) {
            $key = $this->current()->{$this->index_field};
        } else {
            $key = $this->current_index;
        }

        return $key;
    }
public function key()
    {
        if (
            $this->index_field !== null &&
            isset($this->current()->{$this->index_field})
        ) {
            $key = $this->current()->{$this->index_field};
        } else {
            $key = $this->current_index;
        }

        return $key;
    }
public function key ( ) { if ( $ this -> index_field !== null && isset ( $ this -> current ( ) -> { $ this -> index_field } ) ) { $ key = $ this -> current ( ) -> { $ this -> index_field } ; } else { $ key = $ this -> current_index ; } return $ key ; }
Returns the key of the current record

If this recordset has an index field defined and the current record has
an index value, this gets the index value. Otherwise this gets the
ordinal position of the record in this recordset.

@return integer the key of the current record.
Returns the key of the current record