Bolt\Storage\Field\Type\RelationType::getInverseRelations PHP Метод

getInverseRelations() защищенный Метод

Get inverse relationship records. That is ones where the definition happened on the opposite record
protected getInverseRelations ( mixed $entity ) : array
$entity mixed
Результат array
    protected function getInverseRelations($entity)
    {
        $query = $this->em->createQueryBuilder()->select('*')->from($this->mapping['target'])->where('to_id = :to_id')->andWhere('to_contenttype = :to_contenttype')->andWhere('from_contenttype = :from_contenttype')->setParameters(['to_id' => $entity->id, 'to_contenttype' => $entity->getContenttype(), 'from_contenttype' => $this->mapping['fieldname']]);
        $result = $query->execute()->fetchAll();
        return $result ?: [];
    }