Phalcon\Db\Adapter\MongoDB\Operation\Find::createQuery PHP Метод

createQuery() приватный Метод

Create the find query.
private createQuery ( ) : MongoDB\Driver\Query
Результат MongoDB\Driver\Query
    private function createQuery()
    {
        $options = [];
        if (!empty($this->options['allowPartialResults'])) {
            $options['partial'] = true;
        }
        if (isset($this->options['cursorType'])) {
            if ($this->options['cursorType'] === self::TAILABLE) {
                $options['tailable'] = true;
            }
            if ($this->options['cursorType'] === self::TAILABLE_AWAIT) {
                $options['tailable'] = true;
                $options['awaitData'] = true;
            }
        }
        foreach (['batchSize', 'limit', 'skip', 'sort', 'noCursorTimeout', 'oplogReplay', 'projection', 'readConcern'] as $option) {
            if (isset($this->options[$option])) {
                $options[$option] = $this->options[$option];
            }
        }
        $modifiers = empty($this->options['modifiers']) ? [] : (array) $this->options['modifiers'];
        if (isset($this->options['comment'])) {
            $modifiers['$comment'] = $this->options['comment'];
        }
        if (isset($this->options['maxTimeMS'])) {
            $modifiers['$maxTimeMS'] = $this->options['maxTimeMS'];
        }
        if (!empty($modifiers)) {
            $options['modifiers'] = $modifiers;
        }
        return new Query($this->filter, $options);
    }