public function update($ids)
    {
        if (empty($ids)) {
            return false;
        } elseif (empty($this->_ids)) {
            $this->_ids = $ids;
            $change = true;
        } else {
            $change = false;
            foreach ($ids as $k => $v) {
                if (!isset($this->_ids[$k]) || ($this->_ids[$k] != $v)) {
                    $this->_ids[$k] = $v;
                    $change = true;
                }
            }
        }

        if ($change) {
            $this->_sorted = false;
        }

        return $change;
    }
public function update($ids)
    {
        if (empty($ids)) {
            return false;
        } elseif (empty($this->_ids)) {
            $this->_ids = $ids;
            $change = true;
        } else {
            $change = false;
            foreach ($ids as $k => $v) {
                if (!isset($this->_ids[$k]) || ($this->_ids[$k] != $v)) {
                    $this->_ids[$k] = $v;
                    $change = true;
                }
            }
        }

        if ($change) {
            $this->_sorted = false;
        }

        return $change;
    }
public function update ( $ ids ) { if ( empty ( $ ids ) ) { return false ; } elseif ( empty ( $ this -> _ids ) ) { $ this -> _ids = $ ids ; $ change = true ; } else { $ change = false ; foreach ( $ ids as $ k => $ v ) { if ( ! isset ( $ this -> _ids [ $ k ] ) || ( $ this -> _ids [ $ k ] != $ v ) ) { $ this -> _ids [ $ k ] = $ v ; $ change = true ; } } } if ( $ change ) { $ this -> _sorted = false ; } return $ change ; }
Updates the mapping.

@param array $ids  Array of sequence -> UID mapping.

@return boolean  True if the mapping changed.
Updates the mapping .