@param $ids int|array

@return StorageDataRequest
425434
public function getDeleteRequest($ids)
    {
        $self = $this;
        $request = new StorageDataRequest(
            [$ids],
            function ($ids) use ($self) {
                $tablePath = $self->_getTablePath();
                $results = [];
                foreach ($ids as $id) {
                    $filePath = $tablePath.$id;
                    $results[$id] = unlink($filePath);
                }
            
                return $results;
            }
        );
        
        return $request;
    }
1071734
protected function giveAbilitiesToEveryone(array $ids)
    {
        $attributes = Models::scope()->getAttachAttributes();

        $records = array_map(function ($id) use ($attributes) {
            return ['ability_id' => $id] + $attributes;
        }, $ids);

        Models::query('permissions')->insert($records);
    }
193838
public function getBatchUpdateRequest($updateBindsByKeys)
    {
        return new StorageDataRequest(
            [$this->sourceDataAdapter, $this->cacheDataAdapter, $updateBindsByKeys],
            function (DataAdapterInterface $sourceData, DataAdapterInterface $cacheData, $updateBindsByKeys) {
                $request = $sourceData->getBatchUpdateRequest($updateBindsByKeys);
                $request->send();
                $result = $request->fetch();
                if ($result) {
                    $cacheData->getDeleteRequest(array_keys($updateBindsByKeys))->send();
                }
            
                return $result;
            }
        );
    }
301640
public function getReadRequest($ids)
    {
        $db = $this->_getConnection();
        $table = $this->table;
        $self = $this;
        $primary = $this->_getPrimaryKetArray();

        $request = new StorageDataRequest(
            [$ids],
            function ($ids) use ($db, $table, $self, $primary) {
                if (!$db) {
                    $self->logError('Missing connection on getReadRequest on table: ' . $table);
                    return false;
                }

                $whereLines = [];
                foreach ($ids as $id) {
                    $whereArray = [];
                    $whereBind = $self->prepareBind($self->prepareKey($primary, $id), $db);
                    foreach ($whereBind as $key => $value) {
                        $whereArray[] = $key . ' = ' . $value;
                    }
                    $whereLines[] = implode(' AND ', $whereArray);
                }


                $query = 'SELECT * FROM ' . $table
                    . ' WHERE (' . implode(' ) OR (', $whereLines) . ')';


                $stmnt = $db->query($query);

                if (!$stmnt) {
                    $this->logError('Cannot execute getReadRequest on table: ' . $table . ':' . implode(',', $db->errorInfo()), [
                        'code' => $db->errorCode(),
                    ]);

                    return false;
                }

                $result = $stmnt->fetchAll(PDO::FETCH_ASSOC);

                if (!$result && (int) $stmnt->errorCode() > 0) {
                    $this->logError('Error on execution on getReadRequest on table: ' . $table . ':' . implode(',',
                            $stmnt->errorInfo()), [
                        'code' => $stmnt->errorCode(),
                    ]);

                    return false;
                }

                return $result;
            });

        return $request;
    }
507280
public function findByIds(array $ids)
    {
        $entities = [];

        for ($i = 0; $i < count($this->registries); $i++) {
            /** @var RegistryInterface $registry */
            $registry = $this->registries[ $i ];
            $found = $registry->findByKeys($ids);
            $entities = array_merge($entities, $found);

            $this->updateRegistries($found, $i - 1);

            if (count($entities) === count($ids)) {
                break;
            }
        }

        return $entities;
    }
854391
public function getByIds(array $ids): array
    {

        $entities = $this->getRepository()->findByIds($ids);

        $this->prepareEntitesForGet($entities);

        return $entities;
    }
645768
public function removeMany(array $ids) {
		$ids = array_map([$this, 'prepareId'], $ids);
		
		return $this->getBackend()->removeMany($ids);
	}
197984
public function collection(array $ids, array $options = array())
    {
        $photos = $this->dataStore->getPhotos($ids);

        if (empty($photos) && !$this->storageManager->hasFallback()) {
            // If no fallback has been defined, and no photo was found
            // lets just skip the computation that follows.
            return $this->createPhotoCollection();
        }

        $found = array();
        array_map(function ($photo) use ($ids, &$found) {
            // This will be used to build found Photos
            return $found[$photo['id']] = $photo;
        }, $photos);

        $sorted = array();
        foreach ($ids as $index => $id) {
            $photo = array();
            if (array_key_exists($id, $found)) {
                $photo = $found[$id];
            }

            $sorted[$index] = $photo;
        }

        $photos = $this->createPhotoCollection($sorted);
        $simplePhoto = $this; // php 5.3 compatibility
        $photos->transform(function ($photo) use ($simplePhoto, $options) {
            return $simplePhoto->build($photo, $options);
        })->ksort();

        return $photos;
    }
815753
public function findActionsForIds(array $ids)
    {
        if (empty($ids)) {
            return array();
        }

        $datas = $this->client->hmget($this->getActionKey(), $ids);

        return array_values(
            array_map(
                function ($v) {
                    return unserialize($v);
                },
                $datas
            )
        );
    }
1269976
public function execute($ids)
    {
        $storeIds = array_keys($this->storeManager->getStores());

        foreach ($storeIds as $storeId) {
            $dimension = $this->dimensionFactory->create(['name' => 'scope', 'value' => $storeId]);
            $this->indexerHandler->deleteIndex([$dimension], new \ArrayObject($ids));
            $this->indexerHandler->saveIndex([$dimension], $this->fullAction->rebuildStoreIndex($storeId, $ids));
        }
    }
418036
protected function _constructSubject(array $ids)
    {
        $repository = $this->_table();

        list($finder, $options) = $this->_extractFinder();
        $options = array_merge($options, $this->_getFindConfig($ids));
        $query = $repository->find($finder, $options);

        $subject = $this->_subject();
        $subject->set([
            'ids' => $ids,
            'query' => $query,
            'repository' => $repository,
        ]);

        return $subject;
    }
1364170
public function costsDelete(array $ids)
    {
        if (!count($ids)) {
            throw new \InvalidArgumentException(
                'Parameter `ids` must contains a data'
            );
        }

        /* @noinspection PhpUndefinedMethodInspection */
        return $this->client->makeRequest(
            '/costs/delete',
            "POST",
            ['ids' => json_encode($ids)]
        );
    }
1015900
public function delete(array $ids)
    {
        if (!count($ids)) {
            return;
        }
        $ids_str = implode(',', $ids);
        $db = Db::obtain();
        $slots = $db->fetchArrayPDO(
            'SELECT id FROM ' . Db::realTablename('slots') . ' WHERE match_id IN (' . $ids_str . ')',
            array()
        );
        $slotsFormatted = array();
        foreach ($slots as $slot) {
            array_push($slotsFormatted, $slot['id']);
        }
        if (count($slotsFormatted)) {
            $slots_str = implode(',', $slotsFormatted);
            $db->exec('DELETE FROM ' . Db::realTablename('ability_upgrades') . ' WHERE slot_id IN (' . $slots_str . ')');
            $db->exec('DELETE FROM ' . Db::realTablename('additional_units') . ' WHERE slot_id IN (' . $slots_str . ')');
            $db->exec('DELETE FROM ' . Db::realTablename('slots') . ' WHERE id IN (' . $slots_str . ')');
        }
        $db->exec('DELETE FROM ' . Db::realTablename('picks_bans') . ' WHERE match_id IN (' . $ids_str . ')');
        $db->exec('DELETE FROM ' . Db::realTablename('matches') . ' WHERE match_id IN (' . $ids_str . ')');
    }
346009
protected function getCacheKey($ids)
    {
        $key = $this->cachePrefix;
        foreach ($ids as $id) {
            $key .= '-'.$id;
        }

        return $key;
    }
338998
public function setList(array $ids)
    {
        $this->ids = $ids;
        $this->count = count($ids);
        return $this;
    }
957063
public function getMany($ids)
    {
        $info = ORM::for_table('files')
            ->select_many(
                'id',
                'name',
                'ext',
                'created_at'
            )
            ->where_id_in($ids)
            ->where_null('deleted_at')
            ->find_array();
        if (is_array($info)) {
            return Response::data($info);
        } else {
            return Response::error500('Произошла ошибка при получении данных');
        }
    }
589236
public static function scopesFor(array $ids)
    {
        return collect($ids)->map(function ($id) {
            if (isset(static::$scopes[$id])) {
                return new Scope($id, static::$scopes[$id]);
            }

            return;
        })->filter()->values()->all();
    }