protected function _getMax()
    {
        $field = $this->_config['right'];
        $rightField = $this->_config['rightField'];
        $edge = $this->_scope($this->_table->find())
            ->select([$field])
            ->orderDesc($rightField)
            ->first();

        if (empty($edge->{$field})) {
            return 0;
        }

        return $edge->{$field};
    }
protected function _getMax()
    {
        $field = $this->_config['right'];
        $rightField = $this->_config['rightField'];
        $edge = $this->_scope($this->_table->find())
            ->select([$field])
            ->orderDesc($rightField)
            ->first();

        if (empty($edge->{$field})) {
            return 0;
        }

        return $edge->{$field};
    }
protected function _getMax ( ) { $ field = $ this -> _config [ 'right' ] ; $ rightField = $ this -> _config [ 'rightField' ] ; $ edge = $ this -> _scope ( $ this -> _table -> find ( ) ) -> select ( [ $ field ] ) -> orderDesc ( $ rightField ) -> first ( ) ; if ( empty ( $ edge -> { $ field } ) ) { return 0 ; } return $ edge -> { $ field } ; }
Returns the maximum index value in the table.

@return int
Returns the maximum index value in the table .