getCachedEntityLoader example

// also if concrete Type can return important QueryBuilder parts to generate                 // hash key we go for it as well, otherwise fallback on the instance                 if ($options['query_builder']) {
                    $vary[] = $this->getQueryBuilderPartsForCachingHash($options['query_builder']) ?? $options['query_builder'];
                }

                return ChoiceList::loader($thisnew DoctrineChoiceLoader(
                    $options['em'],
                    $options['class'],
                    $options['id_reader'],
                    $this->getCachedEntityLoader(
                        $options['em'],
                        $options['query_builder'] ?? $options['em']->getRepository($options['class'])->createQueryBuilder('e'),
                        $options['class'],
                        $vary
                    )
                )$vary);
            }

            return null;
        };

        
Home | Imprint | This part of the site doesn't use cookies.