@param string[] $rids
@param string   $fetchPlan

@return mixed
19359
public function load(array $rids, $fetchPlan = null)
    {
        $query   = new Query($rids);
        $results = $this->binding->execute($query, $fetchPlan)->getResult();

        return $results;
    }
1312054
protected function fetch($fields=[], $limit=NULL, $order=NULL, $offset=NULL, &$count=FALSE)
    {
        if ($limit == self::FETCH_COUNT) {
            return $this->getCount($fields);
        }
        $data = $this->getDataList($fields, $limit, $order, $offset, $count !== FALSE);
        if ($count !== FALSE) {
            $count = $this->fetchCount();
        }
        return $this->resultAsModelList($data);
    }
1334027
public static function convertToStripeObject($resp, $opts)
    {
        $types = [
            // data structures
            \Stripe\Collection::OBJECT_NAME => 'Stripe\\Collection',

            // business objects
            \Stripe\Account::OBJECT_NAME => 'Stripe\\Account',
            \Stripe\AccountLink::OBJECT_NAME => 'Stripe\\AccountLink',
            \Stripe\AlipayAccount::OBJECT_NAME => 'Stripe\\AlipayAccount',
            \Stripe\ApplePayDomain::OBJECT_NAME => 'Stripe\\ApplePayDomain',
            \Stripe\ApplicationFee::OBJECT_NAME => 'Stripe\\ApplicationFee',
            \Stripe\Balance::OBJECT_NAME => 'Stripe\\Balance',
            \Stripe\BalanceTransaction::OBJECT_NAME => 'Stripe\\BalanceTransaction',
            \Stripe\BankAccount::OBJECT_NAME => 'Stripe\\BankAccount',
            \Stripe\BitcoinReceiver::OBJECT_NAME => 'Stripe\\BitcoinReceiver',
            \Stripe\BitcoinTransaction::OBJECT_NAME => 'Stripe\\BitcoinTransaction',
            \Stripe\Card::OBJECT_NAME => 'Stripe\\Card',
            \Stripe\Charge::OBJECT_NAME => 'Stripe\\Charge',
            \Stripe\Checkout\Session::OBJECT_NAME => 'Stripe\\Checkout\\Session',
            \Stripe\CountrySpec::OBJECT_NAME => 'Stripe\\CountrySpec',
            \Stripe\Coupon::OBJECT_NAME => 'Stripe\\Coupon',
            \Stripe\CreditNote::OBJECT_NAME => 'Stripe\\CreditNote',
            \Stripe\Customer::OBJECT_NAME => 'Stripe\\Customer',
            \Stripe\Discount::OBJECT_NAME => 'Stripe\\Discount',
            \Stripe\Dispute::OBJECT_NAME => 'Stripe\\Dispute',
            \Stripe\EphemeralKey::OBJECT_NAME => 'Stripe\\EphemeralKey',
            \Stripe\Event::OBJECT_NAME => 'Stripe\\Event',
            \Stripe\ExchangeRate::OBJECT_NAME => 'Stripe\\ExchangeRate',
            \Stripe\ApplicationFeeRefund::OBJECT_NAME => 'Stripe\\ApplicationFeeRefund',
            \Stripe\File::OBJECT_NAME => 'Stripe\\File',
            \Stripe\File::OBJECT_NAME_ALT => 'Stripe\\File',
            \Stripe\FileLink::OBJECT_NAME => 'Stripe\\FileLink',
            \Stripe\Invoice::OBJECT_NAME => 'Stripe\\Invoice',
            \Stripe\InvoiceItem::OBJECT_NAME => 'Stripe\\InvoiceItem',
            \Stripe\InvoiceLineItem::OBJECT_NAME => 'Stripe\\InvoiceLineItem',
            \Stripe\IssuerFraudRecord::OBJECT_NAME => 'Stripe\\IssuerFraudRecord',
            \Stripe\Issuing\Authorization::OBJECT_NAME => 'Stripe\\Issuing\\Authorization',
            \Stripe\Issuing\Card::OBJECT_NAME => 'Stripe\\Issuing\\Card',
            \Stripe\Issuing\CardDetails::OBJECT_NAME => 'Stripe\\Issuing\\CardDetails',
            \Stripe\Issuing\Cardholder::OBJECT_NAME => 'Stripe\\Issuing\\Cardholder',
            \Stripe\Issuing\Dispute::OBJECT_NAME => 'Stripe\\Issuing\\Dispute',
            \Stripe\Issuing\Transaction::OBJECT_NAME => 'Stripe\\Issuing\\Transaction',
            \Stripe\LoginLink::OBJECT_NAME => 'Stripe\\LoginLink',
            \Stripe\Order::OBJECT_NAME => 'Stripe\\Order',
            \Stripe\OrderItem::OBJECT_NAME => 'Stripe\\OrderItem',
            \Stripe\OrderReturn::OBJECT_NAME => 'Stripe\\OrderReturn',
            \Stripe\PaymentIntent::OBJECT_NAME => 'Stripe\\PaymentIntent',
            \Stripe\PaymentMethod::OBJECT_NAME => 'Stripe\\PaymentMethod',
            \Stripe\Payout::OBJECT_NAME => 'Stripe\\Payout',
            \Stripe\Person::OBJECT_NAME => 'Stripe\\Person',
            \Stripe\Plan::OBJECT_NAME => 'Stripe\\Plan',
            \Stripe\Product::OBJECT_NAME => 'Stripe\\Product',
            \Stripe\Radar\ValueList::OBJECT_NAME => 'Stripe\\Radar\\ValueList',
            \Stripe\Radar\ValueListItem::OBJECT_NAME => 'Stripe\\Radar\\ValueListItem',
            \Stripe\Recipient::OBJECT_NAME => 'Stripe\\Recipient',
            \Stripe\RecipientTransfer::OBJECT_NAME => 'Stripe\\RecipientTransfer',
            \Stripe\Refund::OBJECT_NAME => 'Stripe\\Refund',
            \Stripe\Reporting\ReportRun::OBJECT_NAME => 'Stripe\\Reporting\\ReportRun',
            \Stripe\Reporting\ReportType::OBJECT_NAME => 'Stripe\\Reporting\\ReportType',
            \Stripe\Review::OBJECT_NAME => 'Stripe\\Review',
            \Stripe\SKU::OBJECT_NAME => 'Stripe\\SKU',
            \Stripe\Sigma\ScheduledQueryRun::OBJECT_NAME => 'Stripe\\Sigma\\ScheduledQueryRun',
            \Stripe\Source::OBJECT_NAME => 'Stripe\\Source',
            \Stripe\SourceTransaction::OBJECT_NAME => 'Stripe\\SourceTransaction',
            \Stripe\Subscription::OBJECT_NAME => 'Stripe\\Subscription',
            \Stripe\SubscriptionItem::OBJECT_NAME => 'Stripe\\SubscriptionItem',
            \Stripe\SubscriptionSchedule::OBJECT_NAME => 'Stripe\\SubscriptionSchedule',
            \Stripe\SubscriptionScheduleRevision::OBJECT_NAME => 'Stripe\\SubscriptionScheduleRevision',
            \Stripe\TaxId::OBJECT_NAME => 'Stripe\\TaxId',
            \Stripe\TaxRate::OBJECT_NAME => 'Stripe\\TaxRate',
            \Stripe\ThreeDSecure::OBJECT_NAME => 'Stripe\\ThreeDSecure',
            \Stripe\Terminal\ConnectionToken::OBJECT_NAME => 'Stripe\\Terminal\\ConnectionToken',
            \Stripe\Terminal\Location::OBJECT_NAME => 'Stripe\\Terminal\\Location',
            \Stripe\Terminal\Reader::OBJECT_NAME => 'Stripe\\Terminal\\Reader',
            \Stripe\Token::OBJECT_NAME => 'Stripe\\Token',
            \Stripe\Topup::OBJECT_NAME => 'Stripe\\Topup',
            \Stripe\Transfer::OBJECT_NAME => 'Stripe\\Transfer',
            \Stripe\TransferReversal::OBJECT_NAME => 'Stripe\\TransferReversal',
            \Stripe\UsageRecord::OBJECT_NAME => 'Stripe\\UsageRecord',
            \Stripe\UsageRecordSummary::OBJECT_NAME => 'Stripe\\UsageRecordSummary',
            \Stripe\WebhookEndpoint::OBJECT_NAME => 'Stripe\\WebhookEndpoint',
        ];
        if (self::isList($resp)) {
            $mapped = [];
            foreach ($resp as $i) {
                array_push($mapped, self::convertToStripeObject($i, $opts));
            }
            return $mapped;
        } elseif (is_array($resp)) {
            if (isset($resp['object']) && is_string($resp['object']) && isset($types[$resp['object']])) {
                $class = $types[$resp['object']];
            } else {
                $class = 'Stripe\\StripeObject';
            }
            return $class::constructFrom($resp, $opts);
        } else {
            return $resp;
        }
    }
36293
public function delete(string $from, $wheres, array $options = [])
    {
        if (!$wheres) {
            throw new \InvalidArgumentException('Safety considerations, where conditions can not be empty');
        }

        list($where, $bindings) = DBHelper::handleConditions($wheres, $this);

        $options['from'] = $this->qn($from);
        $options['where'] = $where;

        $statement = $this->compileDelete($options);

        if (isset($options['returnSql'])) {
            return [$statement, $bindings];
        }

        return $this->fetchAffected($statement, $bindings);
    }
249377
public function paginate($fetchMode = PDO::FETCH_ASSOC) {
        $distinct = $this->distinct ? 'DISTINCT' : '';
        $groupby = '';
        if (!empty($this->group)) {
            $groupby = 'GROUP BY ' . $this->group;
            if (!empty($this->having)) $groupby .= ' ' . $this->having;
        }

        //先获取数量
        $sql = "SELECT $distinct count('*') FROM `$this->table` $this->alias $this->join $this->where $groupby";
        $sql = str_replace('table.',$this->alias.'.',$sql);
        $num = $this->execute($sql, $this->params)->fetchColumn();

        //再获取数据
        $order = !empty($this->order) ? "ORDER BY $this->order" : '';

        $this->fields = $this->fields?$this->fields:'*';
        $sql = "SELECT $distinct $this->fields FROM `$this->table` $this->alias $this->join $this->where $groupby $order $this->limit";
        $sql = str_replace('table.',$this->alias.'.',$sql);

        $result = $this->execute($sql, $this->params)->fetchAll($fetchMode);
        $result = $this->_data($result,true);

        return [$num,$result];
    }
441482
public function fetch($fetch_style = PDO::FETCH_ASSOC, $cursor_orientation = PDO::FETCH_ORI_NEXT, $cursor_offset = 0)
    {
        return $this->PDO->fetch($fetch_style, $cursor_orientation, $cursor_offset);
    }
1143440
public function getProxyFor(Rid $rid, $lazy = true, $fetchPlan = null)
    {
        if (! $this->hasProxyFor($rid)) {
            if ($lazy) {
                $proxy = $this->getHydrator()->hydrateRid($rid);
            } else {
                $proxy = $this->load($rid, $fetchPlan);
            }

            $this->proxies[$rid->getValue()] = $proxy;
        }

        return $this->proxies[$rid->getValue()];
    }
1118007
public function revParse(array $options = [])
    {
        $c = RevParseCommand::getInstance()->revParse($this, $options);
        $caller = $this->repository->getCaller();
        $caller->execute($c);

        return array_map('trim', $caller->getOutputLines(true));
    }
1267010
protected function setFetchOptions(&$fetch, $limit, $order, $offset)
    {
        if (!is_null($limit)) {
            $fetch->limit($limit);
        }
        if (!is_null($offset)) {
            $fetch->offset($offset);
        }
        if (!is_null($order)) {
            $fetch->clearOrderBy($order);
            if (is_array($order)) {
                $fetch->order($order[0], $order[1]);
            } else {
                $fetch->order($order);
            }
        }
        return $fetch;
    }
153084
private function fetch(& $tokens, array $take)
    {
        $res = null;
        while ($token = current($tokens)) {
            list($token, $s) = is_array($token) ? $token : array($token, $token);
            if (in_array($token, $take, true)) {
                $res .= $s;
            } elseif (!in_array($token, array(T_DOC_COMMENT, T_WHITESPACE, T_COMMENT), true)) {
                break;
            }
            next($tokens);
        }

        return $res;
    }
216765
public function get($name = null, $fetchHandler = null)
    {
        if (!func_num_args()) {
            $data = [];
            foreach ($this->_data as $key => $value) {
                $data[$key] = $this->{$key};
            }
            return $data;
        }
        $keys = is_array($name) ? $name : explode('.', $name);
        $name = array_shift($keys);
        if ($name === null || $name === '') {
            throw new ORMException("Field name can't be empty.");
        }

        if ($keys) {
            $value = $this->get($name);
            if (!$value) {
                return;
            }
            if (!$value instanceof DataStoreInterface) {
                throw new ORMException("The field: `" . $name . "` is not a valid document or entity.");
            }
            return $value->get($keys);
        }

        $fieldName = $this->basePath() ? $this->basePath() . '.' . $name : $name;
        $schema = $this->schema();

        $field = [];

        if ($schema->has($fieldName)) {
            $field = $schema->column($fieldName);
        } else {
            $genericFieldName = $this->basePath() ? $this->basePath() . '.*' : '*';
            if ($schema->has($genericFieldName)) {
                $field = $schema->column($genericFieldName);
                $fieldName = $genericFieldName;
            } elseif ($schema->locked() && !$schema->hasRelation($fieldName, false)) {
                throw new ORMException("Missing schema definition for field: `" . $fieldName . "`.");
            }
        }

        $autoCreate = !empty($field['array']);

        if (!empty($field['getter'])) {
            $data = $field['getter']($this, array_key_exists($name, $this->_data) ? $this->_data[$name] : null, $name);
            if (!empty($field['type'])) {
                $data = $schema->convert('cast', $field['type'], $data, $field);
            }
            return $data;
        } elseif (array_key_exists($name, $this->_data)) {
            return $this->_data[$name];
        } elseif ($schema->hasRelation($fieldName, false)) {
            $relation = $schema->relation($fieldName);
            $hasManyThrough = $relation->type() === 'hasManyThrough';
            if (!$hasManyThrough || ($this->id() !== null && !$this->has($relation->through()))) {
                $belongsTo = $relation->type() === 'belongsTo';
                $foreignKey = $belongsTo ? $this->get($relation->keys('from')) : null;
                if (($this->_exists !== false && !$belongsTo) || $foreignKey !== null) {
                    if ($fetchHandler) {
                        return $fetchHandler($this, $name);
                    }
                    throw new ORMException("The relation `'{$name}'` is an external relation, use `fetch()` to lazy load its data.");
                }
            }
            $autoCreate = $relation->isMany();
            $value = $hasManyThrough ? null : [];
        } elseif (isset($field['default'])) {
            $autoCreate = true;
            $value = $field['default'];
        }

        if ($autoCreate) {
            $this->setAt($name, $value);
            return $this->_data[$name];
        }
    }
740919
public function fetch($where, $order=array(), $skipNum=0, $fetchNum=-1) {
		$obj = $this->getConnection();
        if (empty($where)) {
            return array();
        }
        foreach ($where as $key => $value) {
            $obj->where($key, $value);
        }
		if (empty($order) == false) {
			foreach ($order as $key => $value) {
				$obj->orderBy($key, $value);
			}
		}
		$limits = array();
		if ($fetchNum > 0) {
			if ($skipNum >= 0) {
				array_push($limits, $skipNum);
			}
			array_push($limits, $fetchNum);
		}
		if (empty($limits)) {
		    return $obj->get($this->getDao()->getTableName());
        }

		return $obj->get($this->getDao()->getTableName(), $limits);
	}
287203
public static function getDb($fetchMode = \OxidEsales\Eshop\Core\DatabaseProvider::FETCH_MODE_NUM)
    {
        if (null === static::$db) {
            $databaseFactory = static::getInstance();
            static::$db = $databaseFactory->createDatabase();

            /** Post connect actions will be taken only once per connection */
            $databaseFactory->onPostConnect();
        }

        /** The following actions be taken on each call to getDb */
        static::$db->setFetchMode($fetchMode);

        return static::$db;
    }
1268786
public function fetch($fetchMode = NULL, $cursorOrientation = \PDO::FETCH_ORI_NEXT, $cursorOffset = 0) {
        $fetchMode = empty($fetchMode) ? $this->fetchMode : $fetchMode;
        Assertions::assertSupportedFetchMode($fetchMode);

        return count($this->result) === 0 ? false : array_pop($this->result);
    }
626346
public function ngettext($single, $plural, $number, &$num) {
        if ($this->short_circuit) {
            if ($number != 1)
                return $plural;
            else
                return $single;
        }

        // find out the appropriate form
        $select = $this->select_string($number);

        // this should contains all strings separated by NULLs
        $key = $single . chr(0) . $plural;


        if ($this->enable_cache) {
            if (!array_key_exists($key, $this->cache_translations)) {
                return ($number != 1) ? $plural : $single;
            }
            else {
                $result = $this->cache_translations[$key];
                $list = explode(chr(0), $result);
                return $list[$select];
            }
        }
        else {
            $num = $this->find_string($key);
            if ($num == -1) {
                return ($number != 1) ? $plural : $single;
            }
            else {
                $result = $this->get_translation_string($num);
                $list = explode(chr(0), $result);
                return $list[$select];
            }
        }
    }
631590
public function fetchs($condition = NULL, $params = NULL, $fields=null, $order='',$fetchMode=PDO::FETCH_ASSOC) {
		 $this->driver->field($fields)->where($condition, $params);
         $order and $this->orderby($order);
         return  $this->fetchAll($fetchMode);
	}
732815
private function getFetchConfig($mode, $fetchArgument = null, array $ctorArgs = [])
    {
        if ($this->fetchConfig) {
            return $this->fetchConfig;
        }

        return $this->createFetchConfig($mode, $fetchArgument, $ctorArgs);
    }