public function getSortStructure()
    {
        $sort = [$this->getField() => (object)['order' => $this->getOrder()]];

        if ($this->getMode()) {
            $sort[$this->getField()]->mode = $this->getMode();
        }
        if ($this->getMissing()) {
            $sort[$this->getField()]->missing = $this->getMissing();
        }

        return (object)$sort;
    }
public function getSortStructure()
    {
        $sort = [$this->getField() => (object)['order' => $this->getOrder()]];

        if ($this->getMode()) {
            $sort[$this->getField()]->mode = $this->getMode();
        }
        if ($this->getMissing()) {
            $sort[$this->getField()]->missing = $this->getMissing();
        }

        return (object)$sort;
    }
public function getSortStructure ( ) { $ sort = [ $ this -> getField ( ) => ( object ) [ 'order' => $ this -> getOrder ( ) ] ] ; if ( $ this -> getMode ( ) ) { $ sort [ $ this -> getField ( ) ] -> mode = $ this -> getMode ( ) ; } if ( $ this -> getMissing ( ) ) { $ sort [ $ this -> getField ( ) ] -> missing = $ this -> getMissing ( ) ; } return ( object ) $ sort ; }
Get sort structure.

@return array
Get sort structure .